21
edits
Changes
→CCheckMark
</syntaxhighlight></big>
*These methods set and get _flag.
==CMenuItem==
Under construction!
<big><syntaxhighlight lang="cpp">
#include "clabel.h"
#include "cfield.h"
namespace cio{
class CMenuItem:public CField{
bool _selected;
char _format[3];
CLabel Label;
public:
CMenuItem(bool Selected,const char* Format, const char* Text, int Row, int Col, int Width);
CMenuItem(const CMenuItem &CM);
virtual ~CMenuItem(void);
void draw(int fn = C_NO_FRAME) ;
int edit();
bool editable()const;
void set(const void* Selected);
bool selected()const;
void selected(bool val);
const char* Text()const;
};
}
</syntaxhighlight></big>
===Attributes===
<big><syntaxhighlight lang="cpp">
bool _selected;
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
char _format[3];
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
CLabel Label;
</syntaxhighlight></big>
===Constructors / Destructor===
<big><syntaxhighlight lang="cpp">
CMenuItem(bool Selected,const char* Format, const char* Text, int Row, int Col, int Width);
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
CMenuItem(const CMenuItem &CM);
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
virtual ~CMenuItem(void);
</syntaxhighlight></big>
===Methods===
<big><syntaxhighlight lang="cpp">
void draw(int fn = C_NO_FRAME) ;
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
int edit();
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
bool editable()const;
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
void set(const void* Selected);
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
bool selected()const;
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
void selected(bool val);
</syntaxhighlight></big>
<big><syntaxhighlight lang="cpp">
const char* Text()const;
</syntaxhighlight></big>