|
Torque2D Reference
|
#include <guiControl.h>
Inheritance diagram for GuiControl:Public Types | |
| enum | horizSizingOptions { horizResizeRight = 0 , horizResizeWidth , horizResizeLeft , horizResizeCenter , horizResizeRelative , horizResizeFill } |
| enum | vertSizingOptions { vertResizeBottom = 0 , vertResizeHeight , vertResizeTop , vertResizeCenter , vertResizeRelative , vertResizeFill } |
| enum | TextRotationOptions { tRotateNone = 0 , tRotateLeft , tRotateRight } |
Public Types inherited from SimSet | |
| typedef SimObjectList::iterator | iterator |
| typedef SimObjectList::value_type | value |
Public Types inherited from SimObject | |
| enum | WriteFlags { SelectedOnly = BIT(0) } |
Public Member Functions | |
| virtual bool | isEditMode () |
| virtual bool | isEditSelected () |
| virtual void | getScrollLineSizes (U32 *rowHeight, U32 *columnWidth) |
| virtual void | getCursor (GuiCursor *&cursor, bool &showCursor, const GuiEvent &lastGuiEvent) |
| void | awaken () |
| Called when this control and its children have been wired up. | |
| void | sleep () |
| Called when this control is no more. | |
| void | preRender () |
| Prerender this control and all its children. | |
| bool | sendScriptMouseEvent (const char *name, const GuiEvent &event) |
| bool | sendScriptKeyEvent (const char *name, const InputEvent &event) |
| virtual bool | onInputEvent (const InputEvent &event) |
| General input handler. | |
| virtual void | onFocus (bool foundFirstResponder) |
| virtual bool | ControlIsChild (GuiControl *child) |
| virtual void | setControlProfile (GuiControlProfile *prof) |
| virtual void | onAction () |
| Occurs when this control performs its "action". | |
| void | renderText (const Point2I &offset, const Point2I &extent, const char *text, GuiControlProfile *profile, TextRotationOptions rot=tRotateNone) |
| virtual void | renderLineList (const Point2I &offset, const Point2I &extent, const S32 startOffsetY, const vector< string > lineList, GuiControlProfile *profile, const TextRotationOptions rot=tRotateNone) |
| virtual vector< string > | getLineList (const char *text, GuiControlProfile *profile, S32 totalWidth) |
| virtual void | renderTextLine (const Point2I &startPoint, const string line, GuiControlProfile *profile, F32 rotationInDegrees, U32 ibeamPosAtLineStart, U32 lineNumber) |
| RectI | applyMargins (Point2I &offset, Point2I &extent, GuiControlState currentState, GuiControlProfile *profile) |
| Returns a new rect based on the margins. | |
| RectI | applyBorders (Point2I &offset, Point2I &extent, GuiControlState currentState, GuiControlProfile *profile) |
| Returns the bounds of the rect after considering the borders. | |
| RectI | applyPadding (Point2I &offset, Point2I &extent, GuiControlState currentState, GuiControlProfile *profile) |
| Returns the bounds of the rect this time with padding. | |
| RectI | getInnerRect (GuiControlState currentState=GuiControlState::NormalState) |
| Returns the bounds of the rect with margin, borders, and padding applied. | |
| RectI | getInnerRect (Point2I &offset, GuiControlState currentState=GuiControlState::NormalState) |
| virtual RectI | getInnerRect (Point2I &offset, Point2I &extent, GuiControlState currentState, GuiControlProfile *profile) |
| Point2I | getOuterExtent (Point2I &innerExtent, GuiControlState currentState, GuiControlProfile *profile) |
| Returns the extent of the outer rect given the extent of the inner rect. | |
| S32 | getOuterWidth (S32 innerExtent, GuiControlState currentState, GuiControlProfile *profile) |
| S32 | getOuterHeight (S32 innerExtent, GuiControlState currentState, GuiControlProfile *profile) |
| virtual void | inspectPostApply () |
| virtual void | inspectPreApply () |
| Point2I | extentBattery (Point2I &newExtent) |
| void | resetStoredExtent () |
| Point2F | relPosBatteryH (S32 pos, S32 ext, S32 parentExt) |
| Point2F | relPosBatteryV (S32 pos, S32 ext, S32 parentExt) |
| void | relPosBattery (Point2F &battery, S32 pos, S32 ext, S32 parentExt) |
| void | resetStoredRelPos () |
| virtual void | setDataField (StringTableEntry slotName, const char *array, const char *value) |
Editor | |
These functions are used by the GUI Editor | |
| void | setSizing (S32 horz, S32 vert) |
| void | write (Stream &stream, U32 tabStop, U32 flags) |
| Overrides Parent Serialization to allow specific controls to not be saved (Dynamic Controls, etc) | |
| bool | getCanSave () |
| Returns boolean specifying if a control can be serialized. | |
| void | setCanSave (bool bCanSave) |
| Set serialization flag. | |
| bool | getCanSaveParent () |
| Returns boolean as to whether any parent of this control has the 'no serialization' flag set. | |
Flags | |
| virtual void | setVisible (bool value) |
| bool | isVisible () |
| Returns true if the object is visible. | |
| virtual void | setActive (bool value) |
| bool | isActive () |
| Returns true if this control is active. | |
| bool | isAwake () |
| Returns true if this control is awake. | |
Children | |
| virtual void | addObject (SimObject *obj) |
| void | removeObject (SimObject *obj) |
| GuiControl * | getParent () |
| Returns the control which owns this one. | |
| GuiCanvas * | getRoot () |
| Returns the root canvas of this control. | |
Coordinates | |
| virtual Point2I | localToGlobalCoord (const Point2I &src) |
| virtual Point2I | globalToLocalCoord (const Point2I &src) |
Resizing | |
| virtual void | resize (const Point2I &newPosition, const Point2I &newExtent) |
| virtual void | setPosition (const Point2I &newPosition) |
| virtual void | setExtent (const Point2I &newExtent) |
| virtual void | setBounds (const RectI &newBounds) |
| virtual void | setLeft (S32 newLeft) |
| virtual void | setTop (S32 newTop) |
| virtual void | setWidth (S32 newWidth) |
| virtual void | setHeight (S32 newHeight) |
| virtual void | childResized (GuiControl *child) |
| virtual void | childMoved (GuiControl *child) |
| virtual void | childrenReordered () |
| Called when the children of this control may have been reordered. | |
| virtual void | parentResized (const Point2I &oldParentExtent, const Point2I &newParentExtent) |
| void | preventResizeModeFill () |
| Removes the resize mode of fill and changes it to right or bottom. | |
| void | preventResizeModeCenter () |
| Removes the resize mode of center and changes it to right or bottom. | |
Rendering | |
| virtual void | onRender (Point2I offset, const RectI &updateRect) |
| virtual bool | renderTooltip (Point2I &cursorPos, const char *tipText=NULL) |
| virtual void | renderChildControls (const Point2I &offset, const RectI &content, const RectI &updateRect) |
| virtual void | renderChild (GuiControl *ctrl, const Point2I &offset, const RectI &content, const RectI &clipRect) |
| Renders a single child control. | |
| void | setUpdateRegion (Point2I pos, Point2I ext) |
| virtual void | setUpdate () |
| Sets the update area of the control to encompass the whole control. | |
Events | |
If you subclass these, make sure to call the Parent::'s versions. | |
| virtual bool | onWake () |
| Called when this object is asked to wake up returns true if it's actually awake at the end. | |
| virtual void | onSleep () |
| Called when this object is asked to sleep. | |
| virtual void | onPreRender () |
| Do special pre-render proecessing. | |
| virtual void | onRemove () |
| Called when this object is removed using delete. | |
| virtual void | onGroupRemove () |
| Called when this object is removed using delete or parent.remove(). | |
| virtual bool | onAdd () |
| Called when this object is added to the scene. | |
| virtual void | onChildAdded (GuiControl *child) |
| Called when this object has a new child. Congratulations! | |
| virtual void | onChildRemoved (GuiControl *child) |
| Called when a child is removed. | |
Input (Keyboard/Mouse) | |
| virtual bool | pointInControl (const Point2I &parentCoordPoint) |
| bool | cursorInControl () |
| Returns true if the global cursor is inside this control. | |
| virtual GuiControl * | findHitControl (const Point2I &pt, S32 initialLayer=-1) |
| virtual void | mouseLock (GuiControl *lockingControl) |
| virtual void | mouseLock () |
| Turn on mouse locking with last used lock control. | |
| virtual void | mouseUnlock () |
| Unlock the mouse. | |
| virtual bool | isMouseLocked () |
| Returns true if the mouse is locked. | |
Touch/Mouse Events | |
These functions are called when the input event which is in the name of the function occurs. | |
| virtual void | onTouchUp (const GuiEvent &event) |
| virtual void | onTouchDown (const GuiEvent &event) |
| virtual void | onTouchMove (const GuiEvent &event) |
| virtual void | onTouchDragged (const GuiEvent &event) |
| virtual void | onTouchEnter (const GuiEvent &event) |
| virtual void | onTouchLeave (const GuiEvent &event) |
| virtual void | onMouseWheelUp (const GuiEvent &event) |
| virtual void | onMouseWheelDown (const GuiEvent &event) |
| virtual void | onRightMouseDown (const GuiEvent &event) |
| virtual void | onRightMouseUp (const GuiEvent &event) |
| virtual void | onRightMouseDragged (const GuiEvent &event) |
| virtual void | onMiddleMouseDown (const GuiEvent &event) |
| virtual void | onMiddleMouseUp (const GuiEvent &event) |
| virtual void | onMiddleMouseDragged (const GuiEvent &event) |
Editor Mouse Events | |
These functions are called when the input event which is in the name of the function occurs. Conversly from normal mouse events, these have a boolean return value that, if they return true, the editor will NOT act on them or be able to respond to this particular event. This is particularly useful for when writing controls so that they may become aware of the editor and allow customization of their data or appearance as if they were actually in use. For example, the GuiTabBookCtrl catches on mouse down to select a tab and NOT let the editor do any instant group manipulation. | |
| virtual bool | onMouseDownEditor (const GuiEvent &event, const Point2I &offset) |
| virtual bool | onMouseUpEditor (const GuiEvent &event, const Point2I &offset) |
| virtual bool | onRightMouseDownEditor (const GuiEvent &event, const Point2I &offset) |
| virtual bool | onMouseDraggedEditor (const GuiEvent &event, const Point2I &offset) |
Tabs | |
| virtual GuiControl * | findFirstTabable () |
| Find the first tab-accessable child of this control. | |
| virtual GuiControl * | findLastTabable (bool firstCall=true) |
| virtual GuiControl * | findPrevTabable (GuiControl *curResponder, bool firstCall=true) |
| virtual GuiControl * | findNextTabable (GuiControl *curResponder, bool firstCall=true) |
First Responder | |
A first responder is the control which reacts first, in it's responder chain, to keyboard events The responder chain is set for each parent and so there is only one first responder amongst it's children. | |
| virtual void | setFirstResponder (GuiControl *firstResponder) |
| virtual void | makeFirstResponder (bool value) |
| bool | isFirstResponder () |
| Returns true if this control is a first responder. | |
| virtual void | setFirstResponder () |
| Sets this object to be a first responder. | |
| void | clearFirstResponder () |
| Clears the first responder for this chain. | |
| void | clearFirstResponder (GuiControl *target) |
| GuiControl * | getFirstResponder () |
| Returns the first responder for this chain. | |
| virtual void | onLoseFirstResponder () |
| Occurs when the first responder for this chain is lost. | |
Keyboard Events | |
| void | addAcceleratorKey () |
| Adds the accelerator key for this object to the canvas. | |
| virtual void | buildAcceleratorMap () |
| virtual void | acceleratorKeyPress (U32 index) |
| virtual void | acceleratorKeyRelease (U32 index) |
| virtual bool | onKeyDown (const GuiEvent &event) |
| virtual bool | onKeyUp (const GuiEvent &event) |
| virtual bool | onKeyRepeat (const GuiEvent &event) |
Peer Messaging | |
Used to send a message to other GUIControls which are children of the same parent. This is mostly used by radio controls. | |
| void | messageSiblings (S32 message) |
| Send a message to all siblings. | |
| virtual void | onMessage (GuiControl *sender, S32 msg) |
| Receive a message from another control. | |
Canvas Events | |
Functions called by the canvas | |
| virtual void | onDialogPush () |
| Called if this object is a dialog, when it is added to the visible layers. | |
| virtual void | onDialogPop () |
| Called if this object is a dialog, when it is removed from the visible layers. | |
Public Member Functions inherited from SimGroup | |
| ~SimGroup () | |
| void | addObject (SimObject *, SimObjectId) |
| void | addObject (SimObject *, const char *name) |
| virtual void | onChildRemoved (SimObject *) |
| virtual SimObject * | findObject (const char *name) |
| Find an object in the group. | |
| bool | processArguments (S32 argc, const char **argv) |
| Process constructor options. (ie, new SimObject(1,2,3)) | |
| DECLARE_CONOBJECT (SimGroup) | |
Public Member Functions inherited from SimSet | |
| SimSet () | |
| ~SimSet () | |
| virtual void | onDeleteNotify (SimObject *object) |
| virtual U32 | getTamlChildCount (void) const |
| Called when Taml attempts to compile a list of children. | |
| virtual SimObject * | getTamlChild (const U32 childIndex) const |
| Called when Taml attempts to compile a list of children. | |
| virtual void | addTamlChild (SimObject *pSimObject) |
| Called when Taml attempts to populate an objects children during a read. | |
| void | callOnChildren (const char *method, S32 argc, const char *argv[], bool executeOnChildGroups=true) |
| SimObject * | findObjectByInternalName (const char *internalName, bool searchChildren=false) |
| virtual bool | writeObject (Stream *stream) |
| virtual bool | readObject (Stream *stream) |
| void | lock () |
| void | unlock () |
| DECLARE_CONOBJECT (SimSet) | |
| void | _setVectorAssoc (const char *file, const U32 line) |
| virtual void | pushObject (SimObject *) |
| virtual void | popObject () |
| Remove an object from the end of the list. | |
| void | bringObjectToFront (SimObject *obj) |
| void | pushObjectToBack (SimObject *obj) |
| SimObject * | front () |
| SimObject * | first () |
| SimObject * | last () |
| bool | empty () |
| S32 | size () const |
| iterator | begin () |
| iterator | end () |
| value | operator[] (S32 index) |
| iterator | find (iterator first, iterator last, SimObject *obj) |
| iterator | find (SimObject *obj) |
| template<typename T > | |
| bool | containsType (void) |
| bool | isMember (SimObject *obj) |
| virtual bool | reOrder (SimObject *obj, SimObject *target=0) |
| SimObject * | at (S32 index) const |
| void | deleteObjects (void) |
| void | clear () |
Public Member Functions inherited from SimObject | |
| StringTableEntry | getClassNamespace () const |
| StringTableEntry | getSuperClassNamespace () const |
| void | setClassNamespace (const char *classNamespace) |
| void | setSuperClassNamespace (const char *superClassNamespace) |
| void | pushScriptCallbackGuard (void) |
| void | popScriptCallbackGuard (void) |
| S32 | getScriptCallbackGuard (void) |
| Namespace * | getNamespace () |
| Return the object's namespace. | |
| const char * | tabComplete (const char *prevText, S32 baseLen, bool) |
| virtual void | dump () |
| virtual void | dumpClassHierarchy () |
| SimObject * | clone (const bool copyDynamicFields) |
| virtual void | copyTo (SimObject *object) |
| template<typename T > | |
| bool | isType (void) |
| virtual bool | handlesConsoleMethod (const char *fname, S32 *routingId) |
| DECLARE_CONOBJECT (SimObject) | |
| Notify * | removeNotify (void *ptr, Notify::Type) |
| Remove a notification from the list. | |
| void | deleteNotify (SimObject *obj) |
| Notify an object when we are deleted. | |
| void | clearNotify (SimObject *obj) |
| Notify an object when we are cleared. | |
| void | clearAllNotifications () |
| Remove all notifications for this object. | |
| void | processDeleteNotifies () |
| Send out deletion notifications. | |
| void | registerReference (SimObject **obj) |
| void | unregisterReference (SimObject **obj) |
| void | addListener (std::string objID) |
| void | removeListener (std::string objID) |
| void | removeAllListeners () |
| void | postEvent (std::string eventName, std::string data) |
| const char * | getDataField (StringTableEntry slotName, const char *array) |
| const char * | getPrefixedDataField (StringTableEntry fieldName, const char *array) |
| void | setPrefixedDataField (StringTableEntry fieldName, const char *array, const char *value) |
| const char * | getPrefixedDynamicDataField (StringTableEntry fieldName, const char *array, const S32 fieldType=-1) |
| void | setPrefixedDynamicDataField (StringTableEntry fieldName, const char *array, const char *value, const S32 fieldType=-1) |
| StringTableEntry | getDataFieldPrefix (StringTableEntry fieldName) |
| U32 | getDataFieldType (StringTableEntry slotName, const char *array) |
| SimFieldDictionary * | getFieldDictionary () |
| void | clearDynamicFields (void) |
| Clear all dynamic fields. | |
| void | setCanSaveDynamicFields (bool bCanSave) |
| Set whether fields created at runtime should be saved. Default is true. | |
| bool | getCanSaveDynamicFields (void) const |
| Get whether fields created at runtime should be saved. Default is true. | |
| void | setInternalName (const char *newname) |
| StringTableEntry | getInternalName () |
| Get the internal of of this control. | |
| virtual bool | save (const char *pcFilePath, bool bOnlySelected=false) |
| Save object as a TorqueScript File. | |
| virtual bool | isMethod (const char *methodName) |
| Check if a method exists in the objects current namespace. | |
| SimObjectId | getId (void) const |
| StringTableEntry | getIdString (void) const |
| U32 | getType () const |
| const StringTableEntry | getName (void) const |
| void | setId (SimObjectId id) |
| void | assignName (const char *name) |
| SimGroup * | getGroup () const |
| bool | isChildOfGroup (SimGroup *pGroup) |
| bool | isProperlyAdded () const |
| bool | isDeleted () const |
| bool | isRemoved () const |
| bool | isLocked () const |
| void | setLocked (bool b) |
| bool | isHidden () const |
| void | setHidden (bool b) |
| void | setProgenitorFile (const char *pFile) |
| StringTableEntry | getProgenitorFile (void) const |
| void | setPeriodicTimerID (const S32 timerID) |
| S32 | getPeriodicTimerID (void) const |
| bool | isPeriodicTimerActive (void) const |
| bool | isSelected () const |
| bool | isExpanded () const |
| void | setSelected (bool sel) |
| void | setExpanded (bool exp) |
| void | setModDynamicFields (bool dyn) |
| void | setModStaticFields (bool sta) |
| SimObject () | |
| virtual | ~SimObject () |
| virtual void | onGroupAdd () |
| Called when the object is added to a SimGroup. | |
| virtual void | onNameChange (const char *name) |
| Called when the object's name is changed. | |
| virtual void | onStaticModified (const char *slotName, const char *newValue=NULL) |
| virtual void | onEditorEnable () |
| Called when the editor is activated. | |
| virtual void | onEditorDisable () |
| Called when the editor is deactivated. | |
| bool | registerObject () |
| bool | registerObject (U32 id) |
| bool | registerObject (const char *name) |
| bool | registerObject (const char *name, U32 id) |
| void | unregisterObject () |
| void | deleteObject () |
| bool | addToSet (SimObjectId) |
| bool | addToSet (const char *) |
| bool | removeFromSet (SimObjectId) |
| bool | removeFromSet (const char *) |
| virtual bool | writeField (StringTableEntry fieldname, const char *value) |
| virtual void | writeFields (Stream &stream, U32 tabStop) |
| virtual void | buildFilterList () |
| void | addFieldFilter (const char *fieldName) |
| void | removeFieldFilter (const char *fieldName) |
| void | clearFieldFilters () |
| bool | isFiltered (const char *fieldName) |
| void | assignFieldsFrom (SimObject *obj) |
| void | assignDynamicFieldsFrom (SimObject *obj) |
Public Member Functions inherited from ConsoleObject | |
| const AbstractClassRep::Field * | findField (StringTableEntry fieldName) const |
| Get a reference to a field by name. | |
| virtual AbstractClassRep * | getClassRep () const |
| Gets the ClassRep. | |
| bool | setField (const char *fieldName, const char *value) |
| Set the value of a field. | |
| virtual | ~ConsoleObject () |
| const AbstractClassRep::FieldList & | getFieldList () const |
| Get a list of all the fields. This information cannot be modified. | |
| AbstractClassRep::FieldList & | getModifiableFieldList () |
| bool & | getDynamicGroupExpand () |
| S32 | getClassId (U32 netClassGroup) const |
| const char * | getClassName () const |
Public Member Functions inherited from Tickable | |
| Tickable () | |
| virtual | ~Tickable () |
| virtual bool | isProcessingTicks () const |
| virtual void | setProcessTicks (bool tick=true) |
Static Public Attributes | |
Design Time Editor Access | |
| static GuiEditCtrl * | smEditorHandle = NULL |
| static GuiEditCtrl pointer that gives controls access to editor-NULL if editor is closed | |
Static Public Attributes inherited from SimObject | |
| static bool | disableNameChanging = false |
Static Public Attributes inherited from Tickable | |
| static const U32 | smTickShift = 4 |
| Shift value to control how often Ticks occur. | |
| static const U32 | smTickMs = ( 1 << smTickShift ) |
| Number of milliseconds per tick, 32 in this case. | |
| static const F32 | smTickSec = ( F32( Tickable::smTickMs ) / 1000.f ) |
| Fraction of a second per tick. | |
| static const U32 | smTickMask = ( smTickMs - 1 ) |
Protected Member Functions | |
| virtual void | interpolateTick (F32 delta) |
| virtual void | processTick () |
| virtual void | advanceTime (F32 timeDelta) |
| S32 | getTextHorizontalOffset (S32 textWidth, S32 totalWidth, AlignmentType align) |
| S32 | getTextVerticalOffset (S32 textHeight, S32 totalHeight, VertAlignmentType align) |
| AlignmentType | getAlignmentType () |
| VertAlignmentType | getVertAlignmentType () |
| AlignmentType | getAlignmentType (GuiControlProfile *profile) |
| VertAlignmentType | getVertAlignmentType (GuiControlProfile *profile) |
| const ColorI & | getFontColor (GuiControlProfile *profile, const GuiControlState state=GuiControlState::NormalState) |
Callbacks | |
Executes a console command, and returns the result. The global console variable $ThisControl is set to the id of the calling control. WARNING: because multiple controls may set $ThisControl, at any time, the value of $ThisControl should be stored in a local variable by the callback code. The use of the $ThisControl variable is not thread safe. | |
| const char * | execConsoleCallback () |
| Executes mConsoleCommand, and returns the result. | |
| const char * | execAltConsoleCallback () |
| Executes mAltConsoleCommand, and returns the result. | |
Protected Member Functions inherited from SimObject | |
| virtual void | onTamlPreWrite (void) |
| Taml callbacks. | |
| virtual void | onTamlPostWrite (void) |
| Called after Taml has finished writing the object. | |
| virtual void | onTamlPreRead (void) |
| Called prior to Taml reading the object. | |
| virtual void | onTamlPostRead (const TamlCustomNodes &customNodes) |
| virtual void | onTamlAddParent (SimObject *pParentObject) |
| Called after Taml has finished reading the object and has added the object to any parent. | |
| virtual void | onTamlCustomWrite (TamlCustomNodes &customNodes) |
| Called during the writing of the object to allow custom properties to be written. | |
| virtual void | onTamlCustomRead (const TamlCustomNodes &customNodes) |
| Called during the reading of the object to allow custom properties to be read. | |
| void | linkNamespaces () |
| void | unlinkNamespaces () |
Protected Member Functions inherited from ConsoleObject | |
| ConsoleObject () | |
| ConsoleObject (const ConsoleObject &) | |
Protected Attributes | |
| bool | mPreviouslyAwake |
Protected Attributes inherited from SimSet | |
| SimObjectList | objectList |
| void * | mMutex |
Protected Attributes inherited from SimObject | |
| SimObjectId | mId |
| Id number for this object. | |
| StringTableEntry | mIdString |
| Namespace * | mNameSpace |
| U32 | mTypeMask |
| S32 | mScriptCallbackGuard |
| Whether the object is executing a script callback. | |
| bool | mCanSaveFieldDictionary |
| true if dynamic fields (added at runtime) should be saved, defaults to true | |
| StringTableEntry | mInternalName |
| Stores object Internal Name. | |
| StringTableEntry | mClassName |
| Stores the class name to link script class namespaces. | |
| StringTableEntry | mSuperClassName |
| Stores super class name to link script class namespaces. | |
Control State | |
| GuiControlProfile * | mProfile |
| GuiControlProfile * | mTooltipProfile |
| S32 | mTipHoverTime |
| S32 | mTooltipWidth |
| bool | mVisible |
| bool | mActive |
| bool | mAwake |
| bool | mSetFirstResponder |
| bool | mCanSave |
| bool | mIsContainer |
| if true, then the GuiEditor can drag other controls into this one. | |
| bool | mUseInput |
| True if input events like a click can be passed to this gui. False will pass events to the parent and this object and its children will not process input (touch and keyboard). | |
| S32 | mLayer |
| RectI | mBounds |
| Point2I | mMinExtent |
| Point2I | mRenderInsetLT |
| Point2I | mRenderInsetRB |
| Add this to the mBounds and parent offset to get the true render location of the control. | |
| StringTableEntry | mLangTableName |
| The actual rendered inset for the right and bottom sides. | |
| LangTable * | mLangTable |
| static S32 | smCursorChanged = -1 |
| Has this control modified the cursor? -1 or type. | |
| static bool | smDesignTime = false |
| static GuiControl boolean that specifies if the GUI Editor is active | |
| S32 | mHorizSizing |
| Set from horizSizingOptions. | |
| S32 | mVertSizing |
| Set from vertSizingOptions. | |
| Point2I | mStoredExtent |
| Point2F | mStoredRelativePosH |
| Point2F | mStoredRelativePosV |
| bool | mUseRelPosH |
| bool | mUseRelPosV |
| StringTableEntry | mConsoleVariable |
| StringTableEntry | mConsoleCommand |
| StringTableEntry | mAltConsoleCommand |
| StringTableEntry | mAcceleratorKey |
| StringTableEntry | mTooltip |
| StringTableEntry | mText |
| StringTableEntry | mTextID |
| bool | mTextWrap |
| bool | mTextExtend |
| AlignmentType | mAlignment |
| VertAlignmentType | mVAlignment |
| F32 | mFontSizeAdjust |
| ColorI | mFontColor |
| bool | mOverrideFontColor |
Keyboard Input | |
| GuiControl * | mFirstResponder |
| static GuiControl * | smPrevResponder = NULL |
| static GuiControl * | smCurResponder = NULL |
Console | |
| void | setConsoleVariable (const char *variable) |
| void | setConsoleCommand (const char *newCmd) |
| const char * | getConsoleCommand () |
| Returns the name of the function bound to this GuiControl. | |
| LangTable * | getGUILangTable (void) |
| const UTF8 * | getGUIString (S32 id) |
| virtual const char * | getScriptValue () |
| Returns the value of the variable bound to this object. | |
| virtual void | setScriptValue (const char *value) |
| Sets the value of the variable bound to this object. | |
| void | setVariable (const char *value) |
| void | setIntVariable (S32 value) |
| void | setFloatVariable (F32 value) |
| const char * | getVariable () |
| Returns value of control's bound variable as a string. | |
| S32 | getIntVariable () |
| Returns value of control's bound variable as a integer. | |
| F32 | getFloatVariable () |
| Returns value of control's bound variable as a float. | |
Initialization | |
| DECLARE_CONOBJECT (GuiControl) | |
| GuiControl () | |
| virtual | ~GuiControl () |
| static void | initPersistFields () |
Accessors | |
| const Point2I & | getPosition () |
| Returns position of the control. | |
| const Point2I & | getExtent () |
| Returns extents of the control. | |
| const RectI & | getBounds () |
| Returns the bounds of the control. | |
| const Point2I & | getMinExtent () |
| Returns minimum size the control can be. | |
| const S32 | getLeft () |
| Returns the X position of the control. | |
| const S32 | getTop () |
| Returns the Y position of the control. | |
| const S32 | getWidth () |
| Returns the width of the control. | |
| const S32 | getHeight () |
| Returns the height of the control. | |
| virtual void | setText (const char *text) |
| virtual void | setTextID (S32 id) |
| virtual void | setTextID (const char *id) |
| virtual const char * | getText () |
| void | setTextWrap (const bool wrap) |
| bool | getTextWrap () |
| void | setTextExtend (const bool extend) |
| bool | getTextExtend () |
| const horizSizingOptions | getHorizSizing () |
| const vertSizingOptions | getVertSizing () |
| void | setHorizSizing (const horizSizingOptions sizing) |
| void | setVertSizing (const vertSizingOptions sizing) |
| static bool | setTextProperty (void *obj, const char *data) |
| static const char * | getTextProperty (void *obj, const char *data) |
| static bool | writeTextWrapFn (void *obj, const char *data) |
| static bool | writeTextExtendFn (void *obj, const char *data) |
| static bool | setExtentFn (void *obj, const char *data) |
| static bool | setMinExtentFn (void *obj, const char *data) |
| static bool | writeMinExtentFn (void *obj, const char *data) |
| static bool | setPositionFn (void *obj, const char *data) |
Additional Inherited Members | |
Static Public Member Functions inherited from SimObject | |
| static void | initPersistFields () |
Static Public Member Functions inherited from ConsoleObject | |
| static const char * | lookupClassName (const U32 in_classTag) |
| Get the classname from a class tag. | |
| static void | initPersistFields () |
| static void | consoleInit () |
| static AbstractClassRep * | getStaticClassRep () |
| Get the abstract class information for this class. | |
| static AbstractClassRep * | getParentStaticClassRep () |
| Get the abstract class information for this class's superclass. | |
| static ConsoleObject * | create (const char *in_pClassName) |
| static ConsoleObject * | create (const U32 groupId, const U32 typeId, const U32 in_classId) |
Static Public Member Functions inherited from Tickable | |
| static bool | advanceTime (U32 timeDelta) |
Static Protected Member Functions inherited from SimObject | |
| static bool | setClass (void *obj, const char *data) |
| static bool | setSuperClass (void *obj, const char *data) |
| static bool | writeObjectName (void *obj, StringTableEntry pFieldName) |
| static bool | writeCanSaveDynamicFields (void *obj, StringTableEntry pFieldName) |
| static bool | writeInternalName (void *obj, StringTableEntry pFieldName) |
| static bool | setParentGroup (void *obj, const char *data) |
| static bool | writeParentGroup (void *obj, StringTableEntry pFieldName) |
| static bool | writeSuperclass (void *obj, StringTableEntry pFieldName) |
| static bool | writeClass (void *obj, StringTableEntry pFieldName) |
| static bool | setProtectedName (void *obj, const char *data) |
| static SimObject::Notify * | allocNotify () |
| Get a free Notify structure. | |
| static void | freeNotify (SimObject::Notify *) |
| Mark a Notify structure as free. | |
Static Protected Member Functions inherited from ConsoleObject | |
| static void | addGroup (const char *in_pGroupname, const char *in_pGroupDocs=NULL) |
| static void | endGroup (const char *in_pGroupname) |
| static void | addField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, const U32 in_elementCount=1, EnumTable *in_table=NULL, const char *in_pFieldDocs=NULL) |
| static void | addField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::WriteDataNotify in_writeDataFn, const U32 in_elementCount=1, EnumTable *in_table=NULL, const char *in_pFieldDocs=NULL) |
| static void | addField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, const char *in_pFieldDocs) |
| static void | addField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::WriteDataNotify in_writeDataFn, const char *in_pFieldDocs) |
| static void | addFieldV (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, ConsoleTypeValidator *v, const char *in_pFieldDocs=NULL) |
| static void | addProtectedField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::SetDataNotify in_setDataFn, AbstractClassRep::GetDataNotify in_getDataFn=&defaultProtectedGetFn, const U32 in_elementCount=1, EnumTable *in_table=NULL, const char *in_pFieldDocs=NULL) |
| static void | addProtectedField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::SetDataNotify in_setDataFn, AbstractClassRep::GetDataNotify in_getDataFn=&defaultProtectedGetFn, AbstractClassRep::WriteDataNotify in_writeDataFn=&defaultProtectedWriteFn, const U32 in_elementCount=1, EnumTable *in_table=NULL, const char *in_pFieldDocs=NULL) |
| static void | addProtectedField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::SetDataNotify in_setDataFn, AbstractClassRep::GetDataNotify in_getDataFn=&defaultProtectedGetFn, const char *in_pFieldDocs=NULL) |
| static void | addProtectedField (const char *in_pFieldname, const U32 in_fieldType, const dsize_t in_fieldOffset, AbstractClassRep::SetDataNotify in_setDataFn, AbstractClassRep::GetDataNotify in_getDataFn=&defaultProtectedGetFn, AbstractClassRep::WriteDataNotify in_writeDataFn=&defaultProtectedWriteFn, const char *in_pFieldDocs=NULL) |
| static void | addDepricatedField (const char *fieldName) |
| static bool | removeField (const char *in_pFieldname) |
Static Protected Attributes inherited from SimObject | |
| static SimObject::Notify * | mNotifyFreeList = NULL |
| enum horizSizingOptions |
| enum TextRotationOptions |
| enum vertSizingOptions |
| GuiControl | ( | ) |
|
virtual |
|
virtual |
Occurs when the accelerator key for this control is pressed
| index | Index in the acclerator map of the key |
Reimplemented in GuiButtonCtrl, and GuiMenuBarCtrl.
|
virtual |
Occurs when the accelerator key for this control is released
| index | Index in the acclerator map of the key |
Reimplemented in GuiButtonCtrl.
| void addAcceleratorKey | ( | ) |
Adds the accelerator key for this object to the canvas.
|
virtual |
Adds an object as a child of this object.
| obj | New child object of this control |
Reimplemented from SimGroup.
Reimplemented in GuiExpandCtrl, GuiFrameSetCtrl, GuiScrollCtrl, and GuiListBoxCtrl.
|
inlineprotectedvirtual |
This method is called once every frame regardless of the return value of isProcessingTicks and informs the object of the passage of time
Implements Tickable.
Reimplemented in GuiSpriteCtrl, and SceneWindow.
| RectI applyBorders | ( | Point2I & | offset, |
| Point2I & | extent, | ||
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
Returns the bounds of the rect after considering the borders.
| RectI applyMargins | ( | Point2I & | offset, |
| Point2I & | extent, | ||
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
Returns a new rect based on the margins.
| RectI applyPadding | ( | Point2I & | offset, |
| Point2I & | extent, | ||
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
Returns the bounds of the rect this time with padding.
| void awaken | ( | ) |
Called when this control and its children have been wired up.
|
virtual |
Adds this control's accelerator key to the accelerator map, and recursively tells all children to do the same.
|
virtual |
Called when a child control of the object is moved
| child | Child object |
Reimplemented in GuiChainCtrl, GuiFrameSetCtrl, and GuiGridCtrl.
|
virtual |
Called when the children of this control may have been reordered.
Reimplemented in GuiChainCtrl, GuiFrameSetCtrl, and GuiGridCtrl.
|
virtual |
Called when a child control of the object is resized
| child | Child object |
Reimplemented in GuiChainCtrl, GuiExpandCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiScrollCtrl, GuiTabBookCtrl, and GuiMenuBarCtrl.
| void clearFirstResponder | ( | ) |
Clears the first responder for this chain.
| void clearFirstResponder | ( | GuiControl * | target | ) |
|
virtual |
Returns true if the provided control is a child (grandchild, or greatgrandchild) of this one.
| child | Control to test |
| bool cursorInControl | ( | ) |
Returns true if the global cursor is inside this control.
| DECLARE_CONOBJECT | ( | GuiControl | ) |
|
protected |
Executes mAltConsoleCommand, and returns the result.
|
protected |
Executes mConsoleCommand, and returns the result.
|
virtual |
Find the first tab-accessable child of this control.
|
virtual |
Returns the control which the provided point is under, with layering
| pt | Point to test |
| initialLayer | Layer of gui objects to begin the search |
Reimplemented in GuiMenuBarCtrl, GuiFrameSetCtrl, GuiScrollCtrl, and GuiWindowCtrl.
|
virtual |
Find the last tab-accessable child of this control
| firstCall | Set to true to clear the global previous responder |
|
virtual |
Find next tab-accessable control with regards to the provided control.
| curResponder | Current control |
| firstCall | Set to true to clear the global current responder |
Reimplemented in GuiTabPageCtrl, and GuiWindowCtrl.
|
virtual |
Find previous tab-accessable control with respect to the provided one
| curResponder | Current control |
| firstCall | Set to true to clear the global previous responder |
Reimplemented in GuiTabPageCtrl, and GuiWindowCtrl.
|
protected |
|
protected |
|
inline |
Returns the bounds of the control.
| bool getCanSave | ( | ) |
Returns boolean specifying if a control can be serialized.
| bool getCanSaveParent | ( | ) |
Returns boolean as to whether any parent of this control has the 'no serialization' flag set.
| const char * getConsoleCommand | ( | ) |
Returns the name of the function bound to this GuiControl.
Get information about the cursor.
| cursor | Cursor information will be stored here |
| showCursor | Will be set to true if the cursor is visible |
| lastGuiEvent | GuiEvent containing cursor position and modifyer keys (ie ctrl, shift, alt etc) |
Reimplemented in EditorToySceneWindow, GuiFrameSetCtrl, GuiFrameSetCtrl, GuiWindowCtrl, GuiEditCtrl, and GuiTextEditCtrl.
|
inline |
Returns extents of the control.
|
inline |
Returns the first responder for this chain.
|
protected |
Returns value of control's bound variable as a float.
|
protected |
| LangTable * getGUILangTable | ( | void | ) |
| const UTF8 * getGUIString | ( | S32 | id | ) |
|
inline |
Returns the height of the control.
|
inline |
| RectI getInnerRect | ( | GuiControlState | currentState = GuiControlState::NormalState | ) |
Returns the bounds of the rect with margin, borders, and padding applied.
| RectI getInnerRect | ( | Point2I & | offset, |
| GuiControlState | currentState = GuiControlState::NormalState |
||
| ) |
|
virtual |
Reimplemented in GuiWindowCtrl.
|
protected |
Returns value of control's bound variable as a integer.
|
inline |
Returns the X position of the control.
|
virtual |
|
inline |
Returns minimum size the control can be.
| Point2I getOuterExtent | ( | Point2I & | innerExtent, |
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
Returns the extent of the outer rect given the extent of the inner rect.
| S32 getOuterHeight | ( | S32 | innerExtent, |
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
| S32 getOuterWidth | ( | S32 | innerExtent, |
| GuiControlState | currentState, | ||
| GuiControlProfile * | profile | ||
| ) |
| GuiControl * getParent | ( | ) |
Returns the control which owns this one.
|
inline |
Returns position of the control.
| GuiCanvas * getRoot | ( | ) |
Returns the root canvas of this control.
|
virtual |
Returns the value of the variable bound to this object.
Reimplemented in GuiButtonCtrl, GuiCheckBoxCtrl, GuiColorPickerCtrl, GuiColorPopupCtrl, GuiProgressCtrl, and GuiTextEditCtrl.
|
virtual |
Get information about the size of a scroll line.
| rowHeight | The height, in pixels, of a row |
| columnWidth | The width, in pixels, of a column |
|
virtual |
Reimplemented in GuiTextEditCtrl.
|
inline |
|
protected |
|
inlinestatic |
|
protected |
|
inline |
|
inline |
Returns the Y position of the control.
|
protected |
Returns value of control's bound variable as a string.
|
protected |
|
protected |
|
inline |
|
inline |
Returns the width of the control.
Returns global coordinates translated into local space
| src | Global coordinates to translate |
Reimplemented in GuiSceneScrollCtrl.
|
static |
|
virtual |
Called after any property of the object is changed in the world editor.
Reimplemented from SimObject.
Reimplemented in GuiSceneObjectCtrl, GuiChainCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiScrollCtrl, GuiInspector, GuiMenuBarCtrl, GuiMenuItemCtrl, GuiMessageVectorCtrl, and GuiTextEditCtrl.
|
virtual |
Specifically, this is called by setDataField when a static field is modified, see the console details. Called before any property of the object is changed in the world editor.
The calling order here is:
Reimplemented from SimObject.
Reimplemented in GuiChainCtrl.
|
inlineprotectedvirtual |
This method is called every frame and lets the control interpolate between ticks so you can smooth things as long as isProcessingTicks returns true when it is called on the object
Implements Tickable.
Reimplemented in GuiSpriteCtrl, and SceneWindow.
|
inline |
Returns true if this control is active.
|
inline |
Returns true if this control is awake.
|
virtual |
Reimplemented in GuiCanvas.
|
virtual |
| bool isFirstResponder | ( | ) |
Returns true if this control is a first responder.
|
virtual |
Returns true if the mouse is locked.
Reimplemented in GuiSceneScrollCtrl.
|
inline |
Returns true if the object is visible.
Translates local coordinates (wrt this object) into global coordinates
| src | Local coordinates to translate |
Reimplemented in GuiSceneScrollCtrl.
|
virtual |
Sets up this control to be the first in it's group to respond to an input event
| value | True if this should be a first responder |
| void messageSiblings | ( | S32 | message | ) |
Send a message to all siblings.
|
virtual |
Turn on mouse locking with last used lock control.
Reimplemented in GuiSceneScrollCtrl.
|
virtual |
Lock the mouse within the provided control
| lockingControl | Control to lock the mouse within |
Reimplemented in GuiSceneScrollCtrl, and GuiCanvas.
|
virtual |
Unlock the mouse.
Reimplemented in GuiSceneScrollCtrl.
|
virtual |
Occurs when this control performs its "action".
Reimplemented in GuiButtonCtrl, GuiCheckBoxCtrl, GuiDropDownCtrl, GuiRadioCtrl, GuiMenuItemCtrl, and GuiColorPopupCtrl.
|
virtual |
Called when this object is added to the scene.
Reimplemented from SimObject.
Reimplemented in EditorToySceneWindow, SceneWindow, GuiFrameSetCtrl, GuiFrameSetCtrl, GuiPanelCtrl, GuiTabBookCtrl, GuiEditCtrl, GuiInspectorField, GuiInspectorGroup, GuiInspectorDynamicField, GuiMessageVectorCtrl, and GuiTextEditCtrl.
|
virtual |
Called when this object has a new child. Congratulations!
Reimplemented in GuiChainCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiTabBookCtrl, GuiMenuBarCtrl, and GuiMenuItemCtrl.
|
virtual |
Called when a child is removed.
Reimplemented in GuiFrameSetCtrl, GuiGridCtrl, and GuiTabBookCtrl.
|
virtual |
Called if this object is a dialog, when it is removed from the visible layers.
|
virtual |
Called if this object is a dialog, when it is added to the visible layers.
|
virtual |
Reimplemented in GuiWindowCtrl, and GuiCanvas.
|
virtual |
Called when this object is removed using delete or parent.remove().
Reimplemented from SimObject.
|
virtual |
General input handler.
Reimplemented in GuiInputCtrl.
|
virtual |
Happens when a key is depressed
| event | Event descriptor (which contains the key) |
Reimplemented in GuiButtonCtrl, GuiDropDownCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, GuiEditCtrl, GuiMenuBarCtrl, GuiMenuItemCtrl, GuiArrayCtrl, GuiColorPopupCtrl, GuiConsoleEditCtrl, GuiListBoxCtrl, GuiTextEditCtrl, and GuiTextEditSliderCtrl.
|
virtual |
Happens when a key is held down, resulting in repeated keystrokes.
| event | Event descriptor (which contains the key) |
|
virtual |
Happens when a key is released
| event | Event descriptor (which contains the key) |
Reimplemented in GuiButtonCtrl.
|
virtual |
Occurs when the first responder for this chain is lost.
Reimplemented in GuiConsoleEditCtrl, and GuiTextEditCtrl.
|
virtual |
Receive a message from another control.
Reimplemented in GuiButtonCtrl, GuiCheckBoxCtrl, and GuiRadioCtrl.
|
virtual |
Reimplemented in SceneWindow.
|
virtual |
Reimplemented in SceneWindow.
|
virtual |
Reimplemented in SceneWindow.
Called when a mouseDown event occurs on a control and the GUI editor is active
| event | the GuiEvent which caused the call to this function |
| offset | the offset which is representative of the units x and y that the editor takes up on screen |
Reimplemented in GuiFrameSetCtrl, GuiScrollCtrl, GuiTabBookCtrl, and GuiTabPageCtrl.
Called when a mouseDragged event occurs on a control and the GUI editor is active
| event | the GuiEvent which caused the call to this function |
| offset | the offset which is representative of the units x and y that the editor takes up on screen |
Reimplemented in GuiFrameSetCtrl, and GuiScrollCtrl.
Called when a mouseUp event occurs on a control and the GUI editor is active
| event | the GuiEvent which caused the call to this function |
| offset | the offset which is representative of the units x and y that the editor takes up on screen |
Reimplemented in GuiFrameSetCtrl, and GuiScrollCtrl.
|
virtual |
Reimplemented in SceneWindow, GuiScrollCtrl, GuiTextEditCtrl, and EditorToySceneWindow.
|
virtual |
Reimplemented in SceneWindow, GuiScrollCtrl, GuiTextEditCtrl, and EditorToySceneWindow.
|
virtual |
Do special pre-render proecessing.
Reimplemented in GuiFrameSetCtrl, GuiScrollCtrl, GuiTabBookCtrl, DbgFileView, GuiEditorRuler, GuiEditCtrl, GuiMenuListCtrl, GuiConsole, GuiTextEditCtrl, and GuiTreeViewCtrl.
|
virtual |
Called when this object is removed using delete.
Reimplemented from SimGroup.
Reimplemented in EditorToySceneWindow, SceneWindow, GuiTabBookCtrl, GuiEditCtrl, and GuiMessageVectorCtrl.
Called when this control is to render itself
| offset | The location this control is to begin rendering |
| updateRect | The screen area this control has drawing access to |
Reimplemented in EditorToySceneWindow, GuiImageButtonCtrl, GuiSceneObjectCtrl, GuiSpriteCtrl, SceneWindow, GuiButtonCtrl, GuiCheckBoxCtrl, GuiDropDownCtrl, GuiChainCtrl, GuiFrameSetCtrl, GuiFrameSetCtrl, GuiPanelCtrl, GuiSceneScrollCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiTabPageCtrl, GuiWindowCtrl, GuiEditorRuler, GuiEditCtrl, GuiGraphCtrl, GuiMenuBarCtrl, GuiMenuItemCtrl, GuiMenuListCtrl, GuiParticleGraphInspector, GuiArrayCtrl, GuiColorPickerCtrl, GuiColorPopupCtrl, GuiListBoxCtrl, GuiMessageVectorCtrl, GuiProgressCtrl, GuiSliderCtrl, GuiTextEditCtrl, GuiTextEditSliderCtrl, and GuiTreeViewCtrl.
|
virtual |
Reimplemented in SceneWindow, GuiEditCtrl, GuiArrayCtrl, and EditorToySceneWindow.
|
inlinevirtual |
Called when a rightMouseDown event occurs on a control and the GUI editor is active
| event | the GuiEvent which caused the call to this function |
| offset | the offset which is representative of the units x and y that the editor takes up on screen |
|
virtual |
Reimplemented in SceneWindow, and EditorToySceneWindow.
|
virtual |
Reimplemented in GuiButtonCtrl, SceneWindow, and EditorToySceneWindow.
|
virtual |
Called when this object is asked to sleep.
Reimplemented in GuiImageButtonCtrl, GuiSceneObjectCtrl, GuiSpriteCtrl, SceneWindow, GuiDropDownCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiSceneScrollCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, GuiEditCtrl, GuiInspector, GuiMenuBarCtrl, GuiArrayCtrl, GuiColorPickerCtrl, GuiColorPopupCtrl, GuiInputCtrl, GuiMessageVectorCtrl, and GuiTextEditCtrl.
|
virtual |
Reimplemented in GuiButtonCtrl, GuiColorPickerCtrl, SceneWindow, GuiDragAndDropCtrl, GuiFrameSetCtrl, GuiSceneScrollCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, DbgFileView, GuiEditCtrl, GuiMenuBarCtrl, GuiMenuBGCtrl, GuiMenuListCtrl, GuiParticleGraphInspector, GuiArrayCtrl, GuiListBoxCtrl, GuiSliderCtrl, GuiTextEditCtrl, GuiTextEditSliderCtrl, GuiTreeViewCtrl, and EditorToySceneWindow.
|
virtual |
Reimplemented in SceneWindow, GuiDragAndDropCtrl, GuiFrameSetCtrl, GuiSceneScrollCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, DbgFileView, GuiEditCtrl, GuiMenuBGCtrl, GuiParticleGraphInspector, GuiArrayCtrl, GuiColorPickerCtrl, GuiListBoxCtrl, GuiSliderCtrl, GuiTextEditCtrl, GuiTextEditSliderCtrl, GuiTreeViewCtrl, and EditorToySceneWindow.
|
virtual |
Reimplemented in GuiButtonCtrl, GuiColorPickerCtrl, GuiSliderCtrl, SceneWindow, GuiMenuBarCtrl, GuiArrayCtrl, and GuiTextEditCtrl.
|
virtual |
Reimplemented in GuiButtonCtrl, GuiColorPickerCtrl, GuiSliderCtrl, SceneWindow, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, GuiMenuBarCtrl, GuiArrayCtrl, and GuiTextEditCtrl.
|
virtual |
Reimplemented in SceneWindow, GuiFrameSetCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, GuiMenuBarCtrl, GuiMenuBGCtrl, GuiMenuListCtrl, GuiArrayCtrl, GuiColorPickerCtrl, and EditorToySceneWindow.
|
virtual |
Reimplemented in GuiButtonCtrl, GuiColorPickerCtrl, GuiSliderCtrl, SceneWindow, GuiDropDownBGCtrl, GuiDropDownListBoxCtrl, GuiDropDownCtrl, GuiDragAndDropCtrl, GuiFrameSetCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, DbgFileView, GuiEditCtrl, GuiMenuListCtrl, GuiParticleGraphInspector, GuiColorPopupBGCtrl, GuiColorPopupContentCtrl, GuiColorPopupCtrl, GuiTextEditCtrl, GuiTextEditSliderCtrl, GuiTreeViewCtrl, and EditorToySceneWindow.
|
virtual |
Called when this object is asked to wake up returns true if it's actually awake at the end.
Reimplemented in GuiImageButtonCtrl, GuiSceneObjectCtrl, GuiSpriteCtrl, SceneWindow, GuiCheckBoxCtrl, GuiDropDownCtrl, GuiFrameSetCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiSceneScrollCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, DbgFileView, GuiEditCtrl, GuiGraphCtrl, GuiInspector, GuiMenuBarCtrl, GuiArrayCtrl, GuiColorPickerCtrl, GuiColorPopupCtrl, GuiConsole, GuiInputCtrl, GuiListBoxCtrl, GuiMessageVectorCtrl, GuiSliderCtrl, and GuiTextEditCtrl.
Called when this objects parent is resized
| oldParentExtent | The old size of the parent object |
| newParentExtent | The new size of the parent object |
Reimplemented in GuiExpandCtrl, GuiFrameSetCtrl, GuiTabPageCtrl, GuiInspector, GuiListBoxCtrl, GuiMessageVectorCtrl, and GuiTextEditCtrl.
|
virtual |
This function will return true if the provided coordinates (wrt parent object) are within the bounds of this control
| parentCoordPoint | Coordinates to test |
| void preRender | ( | ) |
Prerender this control and all its children.
| void preventResizeModeCenter | ( | ) |
Removes the resize mode of center and changes it to right or bottom.
| void preventResizeModeFill | ( | ) |
Removes the resize mode of fill and changes it to right or bottom.
|
inlineprotectedvirtual |
This method is called once every 32ms if isProcessingTicks returns true when called on the object
Implements Tickable.
Reimplemented in GuiSpriteCtrl, SceneWindow, GuiExpandCtrl, GuiEasingSupport, and GuiProgressCtrl.
| void relPosBattery | ( | Point2F & | battery, |
| S32 | pos, | ||
| S32 | ext, | ||
| S32 | parentExt | ||
| ) |
| Point2F relPosBatteryH | ( | S32 | pos, |
| S32 | ext, | ||
| S32 | parentExt | ||
| ) |
| Point2F relPosBatteryV | ( | S32 | pos, |
| S32 | ext, | ||
| S32 | parentExt | ||
| ) |
|
virtual |
Removes a child object from this control.
| obj | Object to remove from this control |
Reimplemented from SimGroup.
Reimplemented in GuiFrameSetCtrl.
|
virtual |
Renders a single child control.
Reimplemented in GuiFrameSetCtrl.
|
virtual |
Called when this control should render its children
| offset | The top left of the parent control |
| contentOffset | The top left of the parent's content |
| updateRect | The screen area this control has drawing access to |
Reimplemented in GuiScrollCtrl.
|
virtual |
Reimplemented in GuiTextEditCtrl.
| void renderText | ( | const Point2I & | offset, |
| const Point2I & | extent, | ||
| const char * | text, | ||
| GuiControlProfile * | profile, | ||
| TextRotationOptions | rot = tRotateNone |
||
| ) |
Renders justified text using the profile.
|
virtual |
|
virtual |
Render a tooltip at the specified cursor position for this control
| cursorPos | position of cursor to display the tip near |
| tipText | optional alternate tip to be rendered |
|
inline |
|
inline |
Changes the size and/or position of this control
| newPosition | New position of this control |
| newExtent | New size of this control |
Reimplemented in EditorToySceneWindow, SceneWindow, GuiChainCtrl, GuiFrameSetCtrl, GuiFrameSetCtrl, GuiGridCtrl, GuiScrollCtrl, GuiTabBookCtrl, GuiWindowCtrl, GuiInspector, GuiInspectorDynamicField, GuiInspectorTypeFileName, GuiMenuBarCtrl, GuiParticleGraphInspector, and GuiColorPickerCtrl.
| bool sendScriptKeyEvent | ( | const char * | name, |
| const InputEvent & | event | ||
| ) |
| bool sendScriptMouseEvent | ( | const char * | name, |
| const GuiEvent & | event | ||
| ) |
|
virtual |
Sets the status of this control as active and responding or inactive
| value | True if this is active |
Reimplemented in GuiButtonCtrl.
|
virtual |
Changes the bounds of this control
| newBounds | New bounds of this control |
| void setCanSave | ( | bool | bCanSave | ) |
Set serialization flag.
| void setConsoleCommand | ( | const char * | newCmd | ) |
Set the name of the console function bound to, such as a script function a button calls when clicked.
| newCmd | Console function to attach to this GuiControl |
| void setConsoleVariable | ( | const char * | variable | ) |
Set the name of the console variable which this GuiObject is bound to
| variable | Variable name |
|
virtual |
Sets the control profile for this control.
| prof | Control profile to apply |
Reimplemented in GuiPanelCtrl, GuiParticleGraphInspector, and GuiEasingSupport.
|
virtual |
|
virtual |
Changes the size of this control
| newExtent | New size of this control |
|
inlinestatic |
|
virtual |
Sets this object to be a first responder.
Reimplemented in GuiTextEditCtrl.
|
virtual |
Sets the first responder for child controls
| firstResponder | First responder for this chain |
Reimplemented in GuiCanvas.
|
protected |
Sets the value of the console variable bound to this control
| value | Float value to assign to control's console variable |
|
virtual |
Changes the height of this control
| newHeight | New Height of this control |
|
inline |
|
protected |
Sets the value of the console variable bound to this control
| value | Integer value to assign to control's console variable |
|
virtual |
Changes the X position of this control
| newXPosition | New X Position of this control |
|
inlinestatic |
|
virtual |
Changes the position of this control
| newPosition | New position of this control |
|
inlinestatic |
|
virtual |
Sets the value of the variable bound to this object.
Reimplemented in GuiSliderCtrl, GuiButtonCtrl, GuiCheckBoxCtrl, GuiColorPickerCtrl, GuiColorPopupCtrl, GuiProgressCtrl, and GuiTextEditCtrl.
| void setSizing | ( | S32 | horz, |
| S32 | vert | ||
| ) |
Sets the size of the GuiControl
| horz | Width of the control |
| vert | Height of the control |
|
virtual |
Reimplemented in GuiTextEditSliderCtrl, GuiTabPageCtrl, and GuiTextEditCtrl.
|
inline |
|
virtual |
Reimplemented in GuiTextEditCtrl.
|
virtual |
Reimplemented in GuiTextEditCtrl.
|
inlinestatic |
|
inline |
|
virtual |
Changes the Y position of this control
| newYPosition | New Y Position of this control |
|
virtual |
Sets the update area of the control to encompass the whole control.
Reimplemented in GuiTabBookCtrl.
Sets the area (local coordinates) this control wants refreshed each frame
| pos | UpperLeft point on rectangle of refresh area |
| ext | Extent of update rect |
|
protected |
Sets the value of the console variable bound to this control
| value | String value to assign to control's console variable |
|
inline |
|
virtual |
Sets the visibility of the control
| value | True if object should be visible |
|
virtual |
Changes the width of this control
| newWidth | New width of this control |
| void sleep | ( | ) |
Called when this control is no more.
|
virtual |
Overrides Parent Serialization to allow specific controls to not be saved (Dynamic Controls, etc)
Reimplemented from SimSet.
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
protected |
| bool mActive |
|
protected |
|
protected |
| bool mAwake |
| RectI mBounds |
| bool mCanSave |
|
protected |
|
protected |
| GuiControl* mFirstResponder |
|
protected |
|
protected |
|
protected |
Set from horizSizingOptions.
| bool mIsContainer |
if true, then the GuiEditor can drag other controls into this one.
| LangTable* mLangTable |
| StringTableEntry mLangTableName |
The actual rendered inset for the right and bottom sides.
| S32 mLayer |
| Point2I mMinExtent |
|
protected |
|
protected |
| GuiControlProfile* mProfile |
| Point2I mRenderInsetLT |
| Point2I mRenderInsetRB |
Add this to the mBounds and parent offset to get the true render location of the control.
| bool mSetFirstResponder |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
| S32 mTipHoverTime |
|
protected |
| GuiControlProfile* mTooltipProfile |
| S32 mTooltipWidth |
| bool mUseInput |
True if input events like a click can be passed to this gui. False will pass events to the parent and this object and its children will not process input (touch and keyboard).
|
protected |
|
protected |
|
protected |
|
protected |
Set from vertSizingOptions.
| bool mVisible |
|
static |
|
static |
Has this control modified the cursor? -1 or type.
|
static |
static GuiControl boolean that specifies if the GUI Editor is active
|
static |
static GuiEditCtrl pointer that gives controls access to editor-NULL if editor is closed
|
static |