GuiContainer

Engine/source/gui/containers/guiContainer.h

More...

Container Sizing

Returns the Mask of valid docking modes supported by this container.

Docking Accessors.

setDocking(S32 docking)
bool
setAnchorTop(bool val)
setAnchorLeft(bool val)
setAnchorRight(bool val)
bool
setDockingField(void * object, const char * index, const char * data)

Docking Protected Field Setter.

Sizing Constraints

Control Layout Methods

bool
layoutControls(RectI & clientRect)

Called when the Layout for a Container needs to be updated because of a resize call or a call to setUpdateLayout.

setUpdateLayout(S32 updateType)

Set the layout flag to Dirty on a Container, triggering an update to it's layout on the next onPreRender call.

Container Sizing Methods

bool
dockControl(GuiContainer * control, S32 dockingMode, RectI & clientRect)

Dock a Control with the given docking mode inside the given client rect.

bool
anchorControl(GuiControl * control, const Point2I & deltaParentExtent)

Update a Controls Anchor based on a delta sizing of it's parents extent This function should return true if the control was changed in size or position at all.

GuiControl Inherited

Called when this object has a new child.

Called when one of this objects children is removed.

bool
resize(const Point2I & newPosition, const Point2I & newExtent)

Changes the size and/or position of this control.

Called when a child control of the object is resized.

addObject(SimObject * object)

Add the given object to the set.

Remove the given object from the set.

bool
reOrder(SimObject * obj, SimObject * target)

Reorder the position of "obj" to either be the last object in the list or, if "target" is given, to come before "target" in the list of children.

Do special pre-render processing.

parentResized(const RectI & oldParentRect, const RectI & newParentRect)

GuiContainer deals with parentResized calls differently than GuiControl.

Public Types

enum
_Anonymous_ {
  updateSelf = BIT(1)
  updateParent = BIT(2)
  updateNone = 0
}
Parent 

Protected Attributes

Control Sizing Options.

Layout Update Mask.

Public Static Functions

Detailed Description

Container Sizing

getValidDockingMask()

Returns the Mask of valid docking modes supported by this container.

getDocking()

Docking Accessors.

setDocking(S32 docking)

getAnchorTop()

getAnchorBottom()

getAnchorLeft()

getAnchorRight()

setAnchorTop(bool val)

setAnchorBottom(bool val)

setAnchorLeft(bool val)

setAnchorRight(bool val)

getSizingOptions()

setSizingOptions(const ControlSizing & val)

setDockingField(void * object, const char * index, const char * data)

Docking Protected Field Setter.

Sizing Constraints

getClientRect()

Reimplemented by: GuiTabBookCtrl, GuiWindowCtrl

Control Layout Methods

layoutControls(RectI & clientRect)

Called when the Layout for a Container needs to be updated because of a resize call or a call to setUpdateLayout.

Parameters:

clientRect

The Client Rectangle that is available for this Container to layout it's children in

Reimplemented by: GuiSplitContainer

setUpdateLayout(S32 updateType)

Set the layout flag to Dirty on a Container, triggering an update to it's layout on the next onPreRender call.

attention:

This can be called without regard to whether the flag is already set, as setting it does not actually cause an update, but rather tells the container it should update the next chance it gets

Parameters:
updateType

A Mask that indicates how the layout should be updated.

Container Sizing Methods

dockControl(GuiContainer * control, S32 dockingMode, RectI & clientRect)

Dock a Control with the given docking mode inside the given client rect.

attention:

The clientRect passed in will be modified by the docking of the control. It will return the rect that remains after the docking operation.

anchorControl(GuiControl * control, const Point2I & deltaParentExtent)

Update a Controls Anchor based on a delta sizing of it's parents extent This function should return true if the control was changed in size or position at all.

GuiControl Inherited

onChildAdded(GuiControl * child)

Reimplemented from: GuiControl

Reimplemented by: GuiTabBookCtrl

onChildRemoved(GuiControl * child)

Reimplemented from: GuiControl

Reimplemented by: GuiTabBookCtrl

resize(const Point2I & newPosition, const Point2I & newExtent)

Reimplemented from: GuiControl

Reimplemented by: GuiFormCtrl, GuiFrameSetCtrl, GuiScrollCtrl, GuiSplitContainer, GuiTabBookCtrl, GuiWindowCtrl, EditTSCtrl

childResized(GuiControl * child)

Reimplemented from: GuiControl

Reimplemented by: GuiScrollCtrl, GuiTabBookCtrl

addObject(SimObject * object)

Reimplemented from: SimGroup

Reimplemented by: GuiFrameSetCtrl, GuiScrollCtrl, GuiFormCtrl

removeObject(SimObject * object)

Reimplemented from: SimGroup

Reimplemented by: GuiFrameSetCtrl, GuiFormCtrl

reOrder(SimObject * obj, SimObject * target)

Reimplemented from: SimSet

Reimplemented by: GuiTabBookCtrl

onPreRender()

Reimplemented from: GuiControl

Reimplemented by: GuiTSCtrl, GuiScrollCtrl, GuiTextCtrl, GuiTextEditCtrl, GuiTextEditSliderBitmapCtrl, GuiTextEditSliderCtrl, GuiProgressBitmapCtrl, GuiProgressCtrl, TerrainEditor

parentResized(const RectI & oldParentRect, const RectI & newParentRect)

Reimplemented from: GuiControl

Reimplemented by: GuiSplitContainer, GuiWindowCtrl

Public Types

@90

Enumerator

updateSelf = BIT(1)
updateParent = BIT(2)
updateNone = 0
typedef GuiControl Parent 

Protected Attributes

ControlSizing mSizingOptions 

Control Sizing Options.

S32 mUpdateLayout 

Layout Update Mask.

S32 mValidDockingMask 

Public Functions

GuiContainer()

~GuiContainer()

DECLARE_CATEGORY("Gui Containers" )

DECLARE_CONOBJECT(GuiContainer )

Public Static Functions

initPersistFields()