DgsGetPositionAlignment: Difference between revisions
Jump to navigation
Jump to search
m (DGS OOP Syntax changing) |
No edit summary |
||
Line 1: | Line 1: | ||
__NOTOC__{{Client function}} | __NOTOC__{{Client function}} | ||
This function | This function returns the alignment of position from a specific DGS element | ||
==Syntax== | ==Syntax== |
Latest revision as of 13:34, 5 February 2023
This function returns the alignment of position from a specific DGS element
Syntax
string, string dgsGetPositionAlignment( element dgsElement )
DGS OOP Syntax Help! I don't understand this!
- Note: The Variable It's a table and has the following using:
positionAlignment[1]
for horizontal alignmentpositionAlignment[2]
for vertical alignment
- Method: DGSElement:getPositionAlignment(...)
- Variable: .positionAlignment
- Counterpart: dgsSetPositionAlignment
Required Arguments
- dgsElement: The DGS element to change the alignment.
Returns
Return two strings, indicates horizontal and vertical alignment.
- horizontalAlignment:
- left
- center
- right
- verticalAlignment:
- top
- center
- bottom
Example
DGS = exports.dgs local window = DGS:dgsCreateWindow(0.40, 0.33, 0.20, 0.21, "DGS Window", true) local button = DGS:dgsCreateButton(0.0, 0.0, 0.2, 0.1, "Ok", true, window) local hAlign,vAlign = DGS:dgsGetPositionAlignment(button) outputChatBox(hAlign.."-"..vAlibn)
See Also
General Functions
- dgsGetPosition
- dgsSetPosition
- dgsSetParent
- dgsGetParent
- dgsGetChild
- dgsGetChildren
- dgsGetSize
- dgsSetSize
- dgsGetType
- dgsSetLayer
- dgsGetLayer
- dgsSetCurrentLayerIndex
- dgsGetCurrentLayerIndex
- dgsGetLayerElements
- dgsGetProperty
- dgsSetProperty
- dgsSetPropertyInherit
- dgsGetProperties
- dgsSetProperties
- dgsGetVisible
- dgsSetVisible
- dgsGetEnabled
- dgsSetEnabled
- dgsGetPositionAlignment
- dgsSetPositionAlignment
- dgsGetAlpha
- dgsSetAlpha
- dgsGetFont
- dgsSetFont
- dgsGetText
- dgsSetText
- dgsGetPostGUI
- dgsSetPostGUI
- dgsGetInputEnabled
- dgsSetInputEnabled
- dgsGetInputMode
- dgsSetInputMode
- dgsAttachToAutoDestroy
- dgsDetachFromAutoDestroy
- dgsFocus
- dgsBlur
- dgsCreateFont
- dgsBringToFront
- dgsMoveToBack
- dgsGetScreenSize
- dgsGetCursorPosition
- dgsGetMouseEnterGUI
- dgsGetMouseLeaveGUI
- dgsIsMouseWithinGUI
- dgsSetSystemFont
- dgsGetSystemFont
- dgsGetElementsInLayer
- dgsGetElementsFromResource
- dgsGetFocusedGUI
- dgsImportFunction
- dgsImportOOPClass
- dgsG2DLoadHooker
- dgsSetRenderSetting
- dgsGetRenderSetting
- dgsSimulateClick
- dgsGetRootElement
- dgsAddMoveHandler
- dgsRemoveMoveHandler
- dgsIsMoveHandled
- dgsAddSizeHandler
- dgsRemoveSizeHandler
- dgsIsSizeHandled
- dgsAttachElements
- dgsDetachElements
- dgsElementIsAttached
- dgsAddPropertyListener
- dgsRemovePropertyListener
- dgsGetListenedProperties
- dgsSetMultiClickInterval
- dgsGetMultiClickInterval
- dgsSetMouseStayDelay
- dgsGetMouseStayDelay
- dgsCenterElement
- dgsSetElementKeeperEnabled
- dgsGetElementKeeperEnabled
- dgsSetClickingSound
- dgsGetClickingSound
- dgsSetClickingSoundVolume
- dgsGetClickingSoundVolume
General Events
- onDgsBlur
- onDgsCreate
- onDgsCursorTypeChange
- onDgsCursorStateChange
- onDgsDestroy
- onDgsElementRender
- onDgsElementMove
- onDgsElementSize
- onDgsElementEnter
- onDgsElementLeave
- onDgsFocus
- onDgsKey
- onDgsPositionChange
- onDgsPreRender
- onDgsRender
- onDgsElementScroll
- onDgsSizeChange
- onDgsTextChange
- onDgsWindowClose
- onDgsPropertyChange