IMenuSettings Class Reference

IMenuSettings Class Referenceabstract

#include <imenus.h>

Class Description

See also
Class IMenuGlobalContext

Description:
This abstract class represents an interface for all general menu settings. Methods that are marked as internal should not be used.
+ Inheritance diagram for IMenuSettings:

Public Member Functions

virtual ~IMenuSettings ()
 
virtual bool IsTokenValid (const ValidityToken &token)=0
 
virtual void UpdateValidityToken (ValidityToken &token) const =0
 
virtual void ResetDefaults ()=0
 
virtual void SetBorderSz (int borderSz)=0
 
virtual int GetBorderSz () const =0
 
virtual void SetHorizontalMarginInPoints (int horizontalMarginInPoints)=0
 
virtual int GetHorizontalMarginInPoints () const =0
 
virtual void SetVerticalMarginInPoints (int verticalMarginInPoints)=0
 
virtual int GetVerticalMarginInPoints () const =0
 
virtual int GetHorizontalMargin (HDC hDC) const =0
 
virtual int GetVerticalMargin (HDC hDC) const =0
 
virtual void SetItemFontFace (const MCHAR *szItemFontFace)=0
 
virtual const MCHARGetItemFontFace () const =0
 
virtual void SetTitleFontFace (const MCHAR *szTitleFontFace)=0
 
virtual const MCHARGetTitleFontFace () const =0
 
virtual void SetItemFontSize (int itemFontSize)=0
 
virtual int GetItemFontSize () const =0
 
virtual void SetTitleFontSize (int titleFontSize)=0
 
virtual int GetTitleFontSize () const =0
 
virtual void SetUseUniformItemHeight (bool useUniformItemHeight)=0
 
virtual bool GetUseUniformItemHeight () const =0
 
virtual void SetUseUniformItemHeightBOOL (BOOL useUniformItemHeight)=0
 
virtual BOOL GetUseUniformItemHeightBOOL () const =0
 
virtual void SetOpacity (float opacity)=0
 
virtual float GetOpacity () const =0
 
virtual void SetDisplayMethod (DisplayMethod displayMethod)=0
 
virtual DisplayMethod GetDisplayMethod () const =0
 
virtual void SetAnimatedSteps (unsigned int steps)=0
 
virtual unsigned int GetAnimatedSteps () const =0
 
virtual void SetAnimatedStepTime (unsigned int ms)=0
 
virtual unsigned int GetAnimatedStepTime () const =0
 
virtual void SetSubMenuPauseTime (unsigned int ms)=0
 
virtual unsigned int GetSubMenuPauseTime () const =0
 
virtual void SetUseLastExecutedItem (bool useLastExecutedItem)=0
 
virtual bool GetUseLastExecutedItem () const =0
 
virtual void SetUseLastExecutedItemBOOL (BOOL useLastExecutedItem)=0
 
virtual BOOL GetUseLastExecutedItemBOOL () const =0
 
virtual void SetRepositionWhenClipped (bool repositionWhenClipped)=0
 
virtual bool GetRepositionWhenClipped () const =0
 
virtual void SetRepositionWhenClippedBOOL (BOOL repositionWhenClipped)=0
 
virtual BOOL GetRepositionWhenClippedBOOL () const =0
 
virtual void SetRemoveRedundantSeparators (bool removeRedundantSeparators)=0
 
virtual bool GetRemoveRedundantSeparators () const =0
 
virtual void SetRemoveRedundantSeparatorsBOOL (BOOL removeRedundantSeparators)=0
 
virtual BOOL GetRemoveRedundantSeparatorsBOOL () const =0
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 

Constructor & Destructor Documentation

virtual ~IMenuSettings ( )
inlinevirtual
Remarks
Destructor.
247 {;}

Member Function Documentation

virtual bool IsTokenValid ( const ValidityToken token)
pure virtual
Remarks
This method is used internally.

This method checks if a token is valid.
Parameters:
ValidityToken& token

A reference to a token for which to check its validity.
Returns
TRUE if the token is valid, otherwise FALSE.
virtual void UpdateValidityToken ( ValidityToken token) const
pure virtual
Remarks
This method is used internally.

This method updates the validity token.
Parameters:
ValidityToken& token

A reference to a token to update.
virtual void ResetDefaults ( )
pure virtual
Remarks
This method will reset the menu settings to their defaults.
virtual void SetBorderSz ( int  borderSz)
pure virtual
Remarks
This method allows you to set the menu border size.
Parameters:
int borderSz

The border size in pixels.
virtual int GetBorderSz ( ) const
pure virtual
Remarks
This method returns the menu border size.
virtual void SetHorizontalMarginInPoints ( int  horizontalMarginInPoints)
pure virtual
Remarks
This method allows you to set the menu's horizontal margin size.
Parameters:
int horizontalMarginInPoints

The horizontal margin size in points.
virtual int GetHorizontalMarginInPoints ( ) const
pure virtual
Remarks
This method returns the menu's horizontal margin size (in points).
virtual void SetVerticalMarginInPoints ( int  verticalMarginInPoints)
pure virtual
Remarks
This method allows you to set the menu's vertical margin size.
Parameters:
int verticalMarginInPoints

The vertical margin size in points.
virtual int GetVerticalMarginInPoints ( ) const
pure virtual
Remarks
This method returns the menu's vertical margin size (in points).
virtual int GetHorizontalMargin ( HDC  hDC) const
pure virtual
Remarks
This method returns the menu's horizontal margin, in pixels.
Parameters:
HDC hDC

A handle to a device context.
virtual int GetVerticalMargin ( HDC  hDC) const
pure virtual
Remarks
This method returns the menu's vertical margin, in pixels.

Parameters:
HDC hDC

A handle to a device context.
virtual void SetItemFontFace ( const MCHAR szItemFontFace)
pure virtual
Remarks
This method allows you to set the menu item's font typeface.
Parameters:
MCHAR* szItemFontFace

A string containing the typeface name.
virtual const MCHAR* GetItemFontFace ( ) const
pure virtual
Remarks
This method returns the name of the menu item's font typeface.
virtual void SetTitleFontFace ( const MCHAR szTitleFontFace)
pure virtual
Remarks
This method allows you to set the menu title's font typeface.
Parameters:
MCHAR* szTitleFontFace

A string containing the typeface name.
virtual const MCHAR* GetTitleFontFace ( ) const
pure virtual
Remarks
This method returns the name of the menu title's font typeface.
virtual void SetItemFontSize ( int  itemFontSize)
pure virtual
Remarks
This method allows you to set the menu item's font size.
Parameters:
int itemFontSize

The size of the font, in points.
virtual int GetItemFontSize ( ) const
pure virtual
Remarks
This method returns the menu item's font size, in points.
virtual void SetTitleFontSize ( int  titleFontSize)
pure virtual
Remarks
This method allows you to set the menu title's font size.
Parameters:
int titleFontSize

The size of the font, in points.
virtual int GetTitleFontSize ( ) const
pure virtual
Remarks
This method returns the menu title's font size, in points.
virtual void SetUseUniformItemHeight ( bool  useUniformItemHeight)
pure virtual
Remarks
This method allows you to set the status of a menu item's uniform height flag.
Parameters:
bool useUniformItemHeight

TRUE to set the uniform height flag ON, FALSE to set it to OFF.
virtual bool GetUseUniformItemHeight ( ) const
pure virtual
Remarks
This method returns TRUE or FALSE if the menu item's uniform height flag is set or not set, respectively.
virtual void SetUseUniformItemHeightBOOL ( BOOL  useUniformItemHeight)
pure virtual
Remarks
This method allows you to set the status of a menu item's uniform height flag. This version of SetUniformItemHeight() is provided for the function publishing system.
Parameters:
BOOL useUniformItemHeight

TRUE to set the uniform height flag ON, FALSE to set it to OFF.
virtual BOOL GetUseUniformItemHeightBOOL ( ) const
pure virtual
Remarks
This method returns TRUE or FALSE if the menu item's uniform height flag is set or not set, respectively. This version of GetUniformItemHeight() is provided for the function publishing system.
virtual void SetOpacity ( float  opacity)
pure virtual
Remarks
This method allows you to set the menu's opacity value.
Parameters:
float opacity

The opacity value, ranging from 0.0 - 1.0.
virtual float GetOpacity ( ) const
pure virtual
Remarks
This method returns the menu's opacity value.
virtual void SetDisplayMethod ( DisplayMethod  displayMethod)
pure virtual
Remarks
This method allows you to set a menu's display method.
Parameters:
DisplayMethod displayMethod

The display method (enum), which is either of the following; DM_NORMAL, DM_STRETCH, DM_FADE, DM_NUM_METHODS
virtual DisplayMethod GetDisplayMethod ( ) const
pure virtual
Remarks
This method returns the menu's display method, which is either of the following; DM_NORMAL, DM_STRETCH, DM_FADE, DM_NUM_METHODS
virtual void SetAnimatedSteps ( unsigned int  steps)
pure virtual
Remarks
This method allows you to set the menu's number of animated steps for the 'growing' effect.
Parameters:
unsigned int steps

The number of steps.
virtual unsigned int GetAnimatedSteps ( ) const
pure virtual
Remarks
This method returns the menu's number of animated steps used for the 'growing' effect.
virtual void SetAnimatedStepTime ( unsigned int  ms)
pure virtual
Remarks
This method allows you to set the menu's animated step time.
Parameters:
unsigned int ms

The animated step time, in milliseconds.
virtual unsigned int GetAnimatedStepTime ( ) const
pure virtual
Remarks
This method returns the menu's animated step time, in milliseconds.
virtual void SetSubMenuPauseTime ( unsigned int  ms)
pure virtual
Remarks
This method allows you to set the delay before a submenu is displayed.
Parameters:
unsigned int ms

The delay, in milliseconds.
virtual unsigned int GetSubMenuPauseTime ( ) const
pure virtual
Remarks
This method returns the delay before a submenu is displayed, in milliseconds.
virtual void SetUseLastExecutedItem ( bool  useLastExecutedItem)
pure virtual
Remarks
This method allows you to set the "last executed item" flag which determines whether to use the menu's last executed item when the user clicks on the menu's titlebar.
Parameters:
bool useLastExecutedItem

TRUE to turn ON the flag, FALSE to turn the flag off.
virtual bool GetUseLastExecutedItem ( ) const
pure virtual
Remarks
This method returns whether the "last executed item" flag is set (TRUE) or not set (FALSE). The flag determines whether to use the menu's last executed item when the user clicks on the menu's titlebar.
virtual void SetUseLastExecutedItemBOOL ( BOOL  useLastExecutedItem)
pure virtual
Remarks
This method allows you to set the "last executed item" flag which determines whether to use the menu's last executed item when the user clicks on the menu's titlebar. This version of SetUseLastExecutedItem() is provided for the function publishing system.

Parameters:
BOOL useLastExecutedItem

TRUE to turn ON the flag, FALSE to turn the flag off.
virtual BOOL GetUseLastExecutedItemBOOL ( ) const
pure virtual
Remarks
This method returns whether the "last executed item" flag is set (TRUE) or not set (FALSE). The flag determines whether to use the menu's last executed item when the user clicks on the menu's titlebar. This version of GetUseLastExecutedItem() is provided for the function publishing system.
virtual void SetRepositionWhenClipped ( bool  repositionWhenClipped)
pure virtual
Remarks
This method allows you to set the flag which controls and determines whether the menu is repositioned when near the edge of the screen.
Parameters:
bool repositionWhenClipped

TRUE to turn repositioning ON, FALSE to turn it OFF.
virtual bool GetRepositionWhenClipped ( ) const
pure virtual
Remarks
This method returns the status of the flag which controls and determines whether the menu is repositioned when near the edge of the screen.
Returns
TRUE if the flag is ON, otherwise FALSE.
virtual void SetRepositionWhenClippedBOOL ( BOOL  repositionWhenClipped)
pure virtual
Remarks
This method allows you to set the flag which controls and determines whether the menu is repositioned when near the edge of the screen. This version of SetRepositionWhenClipped() is provided for the function publishing system.
Parameters:
BOOL repositionWhenClipped

TRUE to turn repositioning ON, FALSE to turn it OFF.
virtual BOOL GetRepositionWhenClippedBOOL ( ) const
pure virtual
Remarks
This method returns the status of the flag which controls and determines whether the menu is repositioned when near the edge of the screen. This version of GetRepositionWhenClipped() is provided for the function publishing system.
Returns
TRUE if the flag is ON, otherwise FALSE.
virtual void SetRemoveRedundantSeparators ( bool  removeRedundantSeparators)
pure virtual
Remarks
This method allows you to set the flag which controls and determines whether the menu should remove redundant separators.
Parameters:
bool removeRedundantSeparators

TRUE to turn the flag ON, FALSE to turn it OFF.
virtual bool GetRemoveRedundantSeparators ( ) const
pure virtual
Remarks
This method returns the status of the flag which controls and determines whether the menu should remove redundant separators.
Returns
TRUE if the flag is ON, otherwise FALSE.
virtual void SetRemoveRedundantSeparatorsBOOL ( BOOL  removeRedundantSeparators)
pure virtual
Remarks
This method allows you to set the flag which controls and determines whether the menu should remove redundant separators. This version of SetRemoveRedundantSeparators() is provided for the function publishing system.
Parameters:
BOOL removeRedundantSeparators

TRUE to turn the flag ON, FALSE to turn it OFF.
virtual BOOL GetRemoveRedundantSeparatorsBOOL ( ) const
pure virtual
Remarks
This method returns the status of the flag which controls and determines whether the menu should remove redundant separators. This version of GetRemoveRedundantSeparators() is provided for the function publishing system.
Returns
TRUE if the flag is ON, otherwise FALSE.