X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=c%2B%2B%2Fcursslk.h;h=66564fe3a479d0d09626f5a8dd03e1fea0889ccf;hp=091695eef27a9489e37afc3798b9b1ec9b82a403;hb=HEAD;hpb=55ccd2b959766810cf7db8d1c4462f338ce0afc8 diff --git a/c++/cursslk.h b/c++/cursslk.h index 091695ee..66564fe3 100644 --- a/c++/cursslk.h +++ b/c++/cursslk.h @@ -1,6 +1,8 @@ // * this is for making emacs happy: -*-Mode: C++;-*- +// vile:cppmode /**************************************************************************** - * Copyright (c) 1998-2003,2005 Free Software Foundation, Inc. * + * Copyright 2019-2020,2021 Thomas E. Dickey * + * Copyright 1998-2003,2005 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -31,17 +33,17 @@ * Author: Juergen Pfeifer, 1997 * ****************************************************************************/ -// $Id: cursslk.h,v 1.13 2005/05/28 21:58:18 tom Exp $ +// $Id: cursslk.h,v 1.19 2021/04/17 18:11:08 tom Exp $ #ifndef NCURSES_CURSSLK_H_incl #define NCURSES_CURSSLK_H_incl #include -class NCURSES_IMPEXP Soft_Label_Key_Set { +class NCURSES_CXX_IMPEXP Soft_Label_Key_Set { public: // This inner class represents the attributes of a Soft Label Key (SLK) - class NCURSES_IMPEXP Soft_Label_Key { + class NCURSES_CXX_IMPEXP Soft_Label_Key { friend class Soft_Label_Key_Set; public: typedef enum { Left=0, Center=1, Right=2 } Justification; @@ -100,10 +102,10 @@ public: } Label_Layout; private: - static long NCURSES_IMPEXP count; // Number of Key Sets - static Label_Layout NCURSES_IMPEXP format; // Layout of the Key Sets - static int NCURSES_IMPEXP num_labels; // Number Of Labels in Key Sets - bool NCURSES_IMPEXP b_attrInit; // Are attributes initialized + static long count; // Number of Key Sets + static Label_Layout format; // Layout of the Key Sets + static int num_labels; // Number Of Labels in Key Sets + bool b_attrInit; // Are attributes initialized Soft_Label_Key *slk_array; // The array of SLK's @@ -139,11 +141,11 @@ public: // You must create a Soft_Label_Key_Set before you create any object of // the NCursesWindow, NCursesPanel or derived classes. (Actually before // ::initscr() is called). - Soft_Label_Key_Set(Label_Layout fmt); + explicit Soft_Label_Key_Set(Label_Layout fmt); // This constructor assumes, that you already constructed a Key Set // with a layout by the constructor above. This layout will be reused. - NCURSES_IMPEXP Soft_Label_Key_Set(); + Soft_Label_Key_Set(); Soft_Label_Key_Set& operator=(const Soft_Label_Key_Set& rhs) { @@ -161,13 +163,13 @@ public: init(); // allocate a new slk_array[] } - virtual ~Soft_Label_Key_Set(); + virtual ~Soft_Label_Key_Set() THROWS(NCursesException); // Get Label# i. Label counting starts with 1! - NCURSES_IMPEXP Soft_Label_Key& operator[](int i); + Soft_Label_Key& operator[](int i); // Retrieve number of Labels - inline int labels() const { return num_labels; } + int labels() const; // Refresh the SLK portion of the screen inline void refresh() {