Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FXMenuCommand Class Reference

#include <FXMenuCommand.h>

Inheritance diagram for FXMenuCommand:

FXMenuCaption FXWindow FXDrawable FXId FXObject List of all members.

Public Methods

 FXMenuCommand (FXComposite *p, const FXString &text, FXIcon *ic=NULL, FXObject *tgt=NULL, FXSelector sel=0, FXuint opts=0)
 Construct a menu command.

virtual FXint getDefaultWidth ()
 Return default width.

virtual FXint getDefaultHeight ()
 Return default height.

virtual FXbool canFocus () const
 Yes it can receive the focus.

virtual void setFocus ()
 Move the focus to this window.

virtual void killFocus ()
 Remove the focus from this window.

void check ()
 Place checkmark next to text.

void uncheck ()
 Uncheck the item.

FXint isChecked () const
 Return TRUE if checked.

void checkRadio ()
 Place radio bullit next to text.

void uncheckRadio ()
 Uncheck radio bullit.

FXint isRadioChecked () const
 Return TRUE if radio-checked.

void setAccelText (const FXString &text)
 Set accelerator text.

virtual void save (FXStream &store) const
 Save menu to a stream.

virtual void load (FXStream &store)
 Load menu from a stream.

virtual ~FXMenuCommand ()
 Destructor.


Public Attributes

FXString getAccelText () const
 Return accelarator text.


Detailed Description

The menu command widget is used to invoke a command in the application from a menu. Menu commands may reflect the state of the application by graying out, becoming hidden, or by a check mark or bullit.