Creation/Dev/Script/Client/GuiControl
Inherits from TGraalVar.
Variables
Name | Type | Description |
active | boolean | |
awake | boolean (read only) | |
canmove | boolean | |
canresize | boolean | |
editing | boolean | |
extent | string | |
height | integer | |
hint | string | |
horizsizing | string | |
layer | integer (read only) | |
minextent | string | |
minsize | string | the same like "minExtent" |
parent | object (read only) | |
position | string | |
profile | object | |
resizeheight | boolean | |
resizewidth | boolean | |
scrolllinex | integer | |
scrollliney | integer | |
showhint | boolean | |
useownprofile | boolean | |
vertsizing | string | |
visible | boolean | |
width | integer | |
x | integer | |
y | integer |
Functions
Name | Return Type | Description |
addcontrol(obj) | ||
bringtofront() | ||
destroy() | ||
getparent() | object | |
globaltolocalcoord(str) | string | converts global screen coordinates to a position relative to the controls origin (0,0), can be used to know where exactly the user has clicked inside a control |
hide() | Hide the control | |
isfirstresponder() | boolean | Returns whether or not this control is the first responder |
localtoglobalcoord(str) | string | converts a position relative to the controls origin (0,0) to global screen coordinates, can be used to know where on the screen a control is displayed in case it is a child of another control (e.g. GuiWindowCtrl or GuiScrollCtrl) |
makefirstresponder(bool) | ||
pushtoback() | ||
resize(int x, int y, int width, int height) | Resize the control | |
show() | Show the control | |
showtop() | calls show(), tabfirst() and bringtofront() | |
tabfirst() | object |
Events
onAdd() - is invoked when the control is added to another control (addcontrol)
onRemove() - is invoked when the control is removed from its parent
onShow() - is invoked when the control is shown or gets awakened while being 'visible'
onHide() - is invoked when the control is made hidden
onWake() - is invoked when the control is awakened and becomes visible on the screen
onSleep() - is invoked for windows when a dialog window is removed from the screen
onMove(newx,newy) - is invoked when the control is moved
onResize(newwidth,newheight) - is invoked when the control is resized
onAction() - is invoked when a button control is pressed, you press the enter-key in a text edit control, or move a slider control,
onDialogPush() - is invoked when a dialog control is placed on the screen (using pushDialog(control))
onDialogPop() - is invoked when a dialog control is removed from the screen again (using popDialog())