Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | Protected Attributes | List of all members
om::gui::objects::WindowObject Class Referenceabstract

A class that represents a rectangular region that is part of a window. More...

#include <omGUIWindowObject.h>

Inheritance diagram for om::gui::objects::WindowObject:
om::gui::objects::GUIObject om::gui::objects::Button om::gui::objects::TextField om::gui::objects::View om::gui::objects::RenderView om::gui::objects::TabView

Public Member Functions

 WindowObject ()
 Create a new default window element. More...
 
Size getWidth () const
 Return the horizontal size in pixels of this window element. More...
 
Size getHeight () const
 Return the vertical size in pixels of this window element. More...
 
virtual Size2D getSize () const =0
 Return a 2D vector indicating the size on the screen of this window element in pixels. More...
 
Bool setSize (Size newWidth, Size newHeight)
 Set the size on the screen of this window element in pixels. More...
 
virtual Bool setSize (const Size2D &size)=0
 Set the size on the screen of this window element in pixels. More...
 
virtual Vector2i getPosition () const =0
 Return the 2D position of this view in pixels, relative to the bottom left corner of the view. More...
 
virtual Bool setPosition (const Vector2i &position)=0
 Set the 2D position of this view in pixels, relative to the bottom left corner of the view. More...
 
WindowgetParentWindow () const
 Return the window that is a parent of this window element. More...
 
virtual void setParentWindow (Window *newParentWindow)
 Set the window that is going to be a parent of this window element. More...
 
Bool hasParentWindow () const
 Return whether or not this window element belongs to a window. More...
 
- Public Member Functions inherited from om::gui::objects::GUIObject
virtual ~GUIObject ()
 Destroy a GUI element and release all resources associated with it. More...
 
virtual void * getInternalPointer () const =0
 Return a pointer to the OS-specific object that represents this element. More...
 

Protected Attributes

WindowparentWindow
 The parent window of this window element, or NULL if this element is not part of a window. More...
 

Detailed Description

A class that represents a rectangular region that is part of a window.

Constructor & Destructor Documentation

om::gui::objects::WindowObject::WindowObject ( )
inline

Create a new default window element.

Member Function Documentation

Size om::gui::objects::WindowObject::getWidth ( ) const
inline

Return the horizontal size in pixels of this window element.

Size om::gui::objects::WindowObject::getHeight ( ) const
inline

Return the vertical size in pixels of this window element.

virtual Size2D om::gui::objects::WindowObject::getSize ( ) const
pure virtual

Return a 2D vector indicating the size on the screen of this window element in pixels.

Implemented in om::gui::objects::RenderView, om::gui::objects::TabView, om::gui::objects::TextField, and om::gui::objects::Button.

Bool om::gui::objects::WindowObject::setSize ( Size  newWidth,
Size  newHeight 
)
inline

Set the size on the screen of this window element in pixels.

The method returns whether or not the size change operation was successful.

virtual Bool om::gui::objects::WindowObject::setSize ( const Size2D &  size)
pure virtual

Set the size on the screen of this window element in pixels.

The method returns whether or not the size change operation was successful.

Implemented in om::gui::objects::RenderView, om::gui::objects::TabView, om::gui::objects::TextField, and om::gui::objects::Button.

virtual Vector2i om::gui::objects::WindowObject::getPosition ( ) const
pure virtual

Return the 2D position of this view in pixels, relative to the bottom left corner of the view.

The coordinate position is defined relative to its enclosing coordinate frame where the origin will be the bottom left corner of the enclosing view or window.

Implemented in om::gui::objects::RenderView, om::gui::objects::TabView, om::gui::objects::TextField, and om::gui::objects::Button.

virtual Bool om::gui::objects::WindowObject::setPosition ( const Vector2i &  position)
pure virtual

Set the 2D position of this view in pixels, relative to the bottom left corner of the view.

The coordinate position is defined relative to its enclosing coordinate frame where the origin will be the bottom left corner of the enclosing view or window.

If the position change operation is successful, TRUE is returned and the view is moved. Otherwise, FALSE is returned and the view is not moved.

Implemented in om::gui::objects::RenderView, om::gui::objects::TabView, om::gui::objects::TextField, and om::gui::objects::Button.

Window* om::gui::objects::WindowObject::getParentWindow ( ) const
inline

Return the window that is a parent of this window element.

If NULL is returned, it indicates that the window element is not part of a window.

virtual void om::gui::objects::WindowObject::setParentWindow ( Window newParentWindow)
inlinevirtual

Set the window that is going to be a parent of this window element.

Setting this value to NULL should indicate that the window element is no longer part of a window.

Bool om::gui::objects::WindowObject::hasParentWindow ( ) const
inline

Return whether or not this window element belongs to a window.

Member Data Documentation

Window* om::gui::objects::WindowObject::parentWindow
protected

The parent window of this window element, or NULL if this element is not part of a window.


The documentation for this class was generated from the following file: