Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Friends

sp::gui::GUIController Class Reference

#include <spGUIController.hpp>

Inheritance diagram for sp::gui::GUIController:
sp::gui::GUIBaseObject sp::gui::GUIGadget sp::gui::GUIWindow sp::gui::GUIButtonGadget sp::gui::GUICheckboxGadget sp::gui::GUIContainerGadget sp::gui::GUIListGadget sp::gui::GUIProgressbarGadget sp::gui::GUIScrollbarGadget sp::gui::GUIStringGadget sp::gui::GUITextGadget sp::gui::GUITrackbarGadget sp::gui::GUITreeGadget sp::gui::GUIWebGadget

List of all members.

Public Member Functions

virtual ~GUIController ()
virtual bool update ()=0
virtual void draw ()=0
virtual void updateAlways ()
virtual void setRect (const dim::rect2di &Rect)
 Sets the rectangular area of the GUI object object.
virtual void setPosition (const dim::point2di &Position)
 Sets the position of the GUI object. Setting the position is always local!
virtual void setSize (const dim::size2di &Size)
 Sets the size of the GUI object.
virtual dim::point2di getPosition (bool isGlobal) const
virtual dim::rect2di getRect (bool isGlobal) const
 Returns the rectangular area of the GUI object (local or global).
virtual dim::rect2di getLocalViewArea (const GUIController *Obj=0) const
 Returns the local view area. This is the visible area where you can see the child objects.
virtual dim::rect2di getViewArea (const GUIController *Obj=0) const
 Returns the global view area.
virtual dim::point2di getViewOrigin () const
 Returns the local view area origin.
virtual dim::point2di getScrollPosition (bool isGlobal) const
 Returns the scroll position (local or global).
virtual void setParent (GUIController *Parent)
virtual void focus ()
 Sets the focus to this GUI object.
virtual bool hasFocus () const
 Returns true if this GUI object has the global focus.
virtual void foreground ()
 Sets the GUI object in the foreground. This is particular used for windows.
virtual void setFlags (s32 Flags)
EGUIControllerTypes getType () const
 Returns the GUI object's type.
GUIControllergetParent () const
 Returns the GUI object's parent or 0 if not set.
dim::rect2di getRect () const
 Returns the global GUI object rectangular area.
dim::point2di getPosition () const
 Returns the local GUI object position.
dim::size2di getSize () const
 Returns the GUI object size.
void setScrollPosition (const dim::point2di &Position)
 Sets the scroll position. This is particular used for windows with scroll bars.
dim::point2di getScrollPosition () const
 Returns the scroll position.
void translate (const dim::point2di &Direction)
 Translates the GUI object.
void transform (const dim::size2di &Size)
 Transforms the GUI object.
void scroll (const dim::point2di &Direction)
 Scrolls the GUI object (for more information see setScrollPosition).
void setMinSize (const dim::size2di &Size)
 Sets the minimal GUI object's size.
dim::size2di getMinSize () const
void setMaxSize (const dim::size2di &Size)
 Sets the maximal GUI object's size.
dim::size2di getMaxSize () const
void setOrder (s32 Order)
 Sets the GUI object's order for the depth sort process.
s32 getOrder () const
void setVisible (bool isVisible)
 Sets the visibility of the GUI object.
bool getVisible () const
bool hasForeground () const
 Returns true if this GUI object is in the foreground.
s32 getFlags () const
 Returns the GUI object's flags.

Protected Member Functions

 GUIController (const EGUIControllerTypes Type)
void updateChildren ()
void drawChildren ()
void updateClipping ()
bool setupClipping ()
bool checkClipping () const
void updateRect ()
bool checkDefaultUpdate ()
virtual void addChild (GUIController *Child)
virtual void removeChild (GUIController *Child)
void useFocus (s32 Usage=0)
bool usage (s32 Usage) const
bool usage () const
bool foreignUsage () const
dim::rect2di getParentViewArea () const
void updateScrollBars (GUIScrollbarGadget *HorzScroll, GUIScrollbarGadget *VertScroll)
virtual void checkFlags ()

Protected Attributes

EGUIControllerTypes Type_
GUIControllerParent_
std::list< GUIController * > Children_
s32 Order_
dim::rect2di RootRect_
dim::rect2di Rect_
dim::rect2di VisRect_
dim::size2di MinSize_
dim::size2di MaxSize_
dim::point2di ScrollPos_
bool isVisible_
bool isValidated_
bool isForeground_
s32 Flags_
s32 FocusUsage_
bool Usable_

Static Protected Attributes

static const s32 SCROLLBAR_SIZE = 15

Friends

class GUIManager

Constructor & Destructor Documentation

virtual sp::gui::GUIController::~GUIController (  )  [virtual]
sp::gui::GUIController::GUIController ( const EGUIControllerTypes  Type  )  [protected]

Member Function Documentation

virtual void sp::gui::GUIController::addChild ( GUIController Child  )  [protected, virtual]
bool sp::gui::GUIController::checkClipping (  )  const [protected]
bool sp::gui::GUIController::checkDefaultUpdate (  )  [protected]
virtual void sp::gui::GUIController::checkFlags (  )  [protected, virtual]
void sp::gui::GUIController::drawChildren (  )  [protected]
virtual void sp::gui::GUIController::focus (  )  [virtual]

Sets the focus to this GUI object.

virtual void sp::gui::GUIController::foreground (  )  [virtual]

Sets the GUI object in the foreground. This is particular used for windows.

bool sp::gui::GUIController::foreignUsage (  )  const [protected]
s32 sp::gui::GUIController::getFlags (  )  const [inline]

Returns the GUI object's flags.

virtual dim::rect2di sp::gui::GUIController::getLocalViewArea ( const GUIController Obj = 0  )  const [virtual]

Returns the local view area. This is the visible area where you can see the child objects.

dim::size2di sp::gui::GUIController::getMaxSize (  )  const [inline]
dim::size2di sp::gui::GUIController::getMinSize (  )  const [inline]
s32 sp::gui::GUIController::getOrder (  )  const [inline]
GUIController* sp::gui::GUIController::getParent (  )  const [inline]

Returns the GUI object's parent or 0 if not set.

dim::rect2di sp::gui::GUIController::getParentViewArea (  )  const [protected]
dim::point2di sp::gui::GUIController::getPosition (  )  const [inline]

Returns the local GUI object position.

virtual dim::point2di sp::gui::GUIController::getPosition ( bool  isGlobal  )  const [virtual]

Returns the position of the GUI object.

Parameters:
isGlobal,: If true the returned position is global i.e. dependent of the GUI object's parents. Otherwise local.
virtual dim::rect2di sp::gui::GUIController::getRect ( bool  isGlobal  )  const [virtual]

Returns the rectangular area of the GUI object (local or global).

dim::rect2di sp::gui::GUIController::getRect (  )  const [inline]

Returns the global GUI object rectangular area.

virtual dim::point2di sp::gui::GUIController::getScrollPosition ( bool  isGlobal  )  const [virtual]

Returns the scroll position (local or global).

dim::point2di sp::gui::GUIController::getScrollPosition (  )  const [inline]

Returns the scroll position.

dim::size2di sp::gui::GUIController::getSize (  )  const [inline]

Returns the GUI object size.

EGUIControllerTypes sp::gui::GUIController::getType (  )  const [inline]

Returns the GUI object's type.

virtual dim::rect2di sp::gui::GUIController::getViewArea ( const GUIController Obj = 0  )  const [virtual]

Returns the global view area.

virtual dim::point2di sp::gui::GUIController::getViewOrigin (  )  const [virtual]

Returns the local view area origin.

bool sp::gui::GUIController::getVisible (  )  const [inline]
virtual bool sp::gui::GUIController::hasFocus (  )  const [virtual]

Returns true if this GUI object has the global focus.

bool sp::gui::GUIController::hasForeground (  )  const [inline]

Returns true if this GUI object is in the foreground.

virtual void sp::gui::GUIController::removeChild ( GUIController Child  )  [protected, virtual]
void sp::gui::GUIController::scroll ( const dim::point2di Direction  )  [inline]

Scrolls the GUI object (for more information see setScrollPosition).

virtual void sp::gui::GUIController::setFlags ( s32  Flags  )  [virtual]

Sets the flags (or rather options).

Parameters:
Flags,: Flags which are to be set. There are several flags for several GUI object types. The basic flags are defined in the EControllerFlags enumeration. For windows there are additional falgs in EWindowFlags etc.
void sp::gui::GUIController::setMaxSize ( const dim::size2di Size  )  [inline]

Sets the maximal GUI object's size.

void sp::gui::GUIController::setMinSize ( const dim::size2di Size  )  [inline]

Sets the minimal GUI object's size.

void sp::gui::GUIController::setOrder ( s32  Order  )  [inline]

Sets the GUI object's order for the depth sort process.

virtual void sp::gui::GUIController::setParent ( GUIController Parent  )  [virtual]

Sets the parent object of the GUI object. Several objects support a children hierarchy e.h. windows (GUIWindow objects).

Parameters:
Parent,: Parent GUI object.
virtual void sp::gui::GUIController::setPosition ( const dim::point2di Position  )  [virtual]

Sets the position of the GUI object. Setting the position is always local!

virtual void sp::gui::GUIController::setRect ( const dim::rect2di Rect  )  [virtual]

Sets the rectangular area of the GUI object object.

void sp::gui::GUIController::setScrollPosition ( const dim::point2di Position  )  [inline]

Sets the scroll position. This is particular used for windows with scroll bars.

virtual void sp::gui::GUIController::setSize ( const dim::size2di Size  )  [virtual]

Sets the size of the GUI object.

Reimplemented in sp::gui::GUIScrollbarGadget.

bool sp::gui::GUIController::setupClipping (  )  [protected]
void sp::gui::GUIController::setVisible ( bool  isVisible  )  [inline]

Sets the visibility of the GUI object.

void sp::gui::GUIController::transform ( const dim::size2di Size  )  [inline]

Transforms the GUI object.

void sp::gui::GUIController::translate ( const dim::point2di Direction  )  [inline]

Translates the GUI object.

virtual void sp::gui::GUIController::updateAlways (  )  [virtual]
void sp::gui::GUIController::updateChildren (  )  [protected]
void sp::gui::GUIController::updateClipping (  )  [protected]
void sp::gui::GUIController::updateRect (  )  [protected]
void sp::gui::GUIController::updateScrollBars ( GUIScrollbarGadget HorzScroll,
GUIScrollbarGadget VertScroll 
) [protected]
bool sp::gui::GUIController::usage (  )  const [protected]
bool sp::gui::GUIController::usage ( s32  Usage  )  const [protected]
void sp::gui::GUIController::useFocus ( s32  Usage = 0  )  [protected]

Friends And Related Function Documentation

friend class GUIManager [friend]

Reimplemented from sp::gui::GUIBaseObject.


Member Data Documentation

const s32 sp::gui::GUIController::SCROLLBAR_SIZE = 15 [static, protected]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines