Exponent::GUI::Windowing::CMenuWindow::CMenuRoot Class Reference

List of all members.

Detailed Description

Replacement control root that is specific to a menu window.
Does lots of handy stuff associated with menus, such as determining its own size.

Definition at line 209 of file CMenuWindow.hpp.

Public Member Functions

Protected Member Functions

Protected Attributes


Constructor & Destructor Documentation

Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::CMenuRoot ( IWindow parent  ) 

Construction

Parameters:
parent The parent menu window, this may be NULL

virtual Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::~CMenuRoot (  )  [virtual]

Destruction


Member Function Documentation

bool Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::doesMenuHaveExtraItems ( bool &  selectable  )  [protected]

Does it have a sub menu item

Parameters:
selectable On return is true if selectable items found, false otherwise
Return values:
bool True if sub menus found, false ohterwise

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::drawRootControl ( CGraphics &  graphics  )  [virtual]

Draw the root control

Parameters:
graphics The graphics handle to draw with

bool Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::findMaxIconDimension ( CDimension &  maxDimension  )  [protected]

Find the max icon dimensions

Parameters:
maxDimension On return holds the max dimensions of the images contained within the menu
Return values:
bool True if icons were found, false otherwise

void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::findMaxStringDimension ( CDimension &  maxDimension  )  [protected]

Find the biggest dimensions in the string sthat we have

Parameters:
maxDimension On return stores the max dimension string we are using

virtual CFont* Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::getFont (  )  [inline, virtual]

Get the font

Return values:
CFont* The font in use

Definition at line 292 of file CMenuWindow.hpp.

References m_font.

virtual CMenu* Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::getMenu (  )  const [inline, virtual]

Get the mneu

Return values:
CMenu* The menu

Definition at line 271 of file CMenuWindow.hpp.

References m_menu.

virtual const SMenuColours& Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::getMenuColours (  )  const [inline, virtual]

Get the menu colours

Return values:
const SMenuColours& The menu colours

Definition at line 304 of file CMenuWindow.hpp.

References m_colours.

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::handleLeftButtonDown ( CMouseEvent &  event  )  [virtual]

Handle left button being clicked

Parameters:
event The mouse event to handle

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::handleLeftButtonUp ( CMouseEvent &  event  )  [virtual]

Handle left button being released

Parameters:
event The mouse event to handle

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::handleMouseLeavingArea ( CMouseEvent &  event  )  [virtual]

Handle a mouse leaving movement

Parameters:
event The mouse event to handle

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::handleMouseMovement ( CMouseEvent &  event  )  [virtual]

Handle the mouse movement

Parameters:
event The mouse event to handle

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setCurrentSelection ( const long  selection = CMENU_WINDOW_NO_SELECTION  )  [virtual]

Set the selected entry

Parameters:
selection If CMENU_WINDOW_NO_SELECTION Then nothing is selected, else the entry

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setFont ( CFont *  font  )  [virtual]

Set the font

Note:
recalculates size
Parameters:
font The font to use

virtual CDimension* Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setMenu ( CMenu *  menu  )  [virtual]

Set the menu

Parameters:
menu The menu to use
Return values:
CDimension* The total dimension of the mneu

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setMenuColours ( const SMenuColours colours  )  [virtual]

Set the window colours

Parameters:
colours The colours of the menu items

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setMinimumWidth ( const long  width  )  [virtual]

Set the minimum Width

Parameters:
width The minimum menu width in pixels
Note:
The window will always be >= width

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::setRootArea ( const CRect &  area  )  [inline, virtual]

Set the area

Parameters:
area The area of the control root

Definition at line 277 of file CMenuWindow.hpp.

References m_rootArea.

virtual void Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::useIcons ( const bool  icons = true  )  [virtual]

Use icons

Parameters:
icons If true then menu items will have icons shown (if they have them) if false, no icons are shown


Member Data Documentation

SMenuColours Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_colours [protected]

The menu colours

Definition at line 368 of file CMenuWindow.hpp.

Referenced by getMenuColours().

long Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_currentSelection [protected]

The currently selected item

Definition at line 365 of file CMenuWindow.hpp.

CFont* Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_font [protected]

The font to use

Definition at line 360 of file CMenuWindow.hpp.

Referenced by getFont().

long Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_guardSelection [protected]

Item selected on mouse down

Definition at line 366 of file CMenuWindow.hpp.

CMenu* Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_menu [protected]

The menu

Definition at line 359 of file CMenuWindow.hpp.

Referenced by getMenu().

long Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_minimumWidth [protected]

Width should be >= this

Definition at line 364 of file CMenuWindow.hpp.

CRect Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_rootArea [protected]

The are of the root control

Definition at line 370 of file CMenuWindow.hpp.

Referenced by setRootArea().

bool Exponent::GUI::Windowing::CMenuWindow::CMenuRoot::m_useIcons [protected]

Should icons be used?

Definition at line 371 of file CMenuWindow.hpp.


Infinity API - Exponent::GUI::Windowing::CMenuWindow::CMenuRoot Class Reference generated on 7 Mar 2007