class
GUIIntField
A composite GUI object representing an editor field.
Editor fields are a combination of a label and an input field. Label is optional. This specific implementation displays a integer input field.
Public
Constructors
GUIIntField
Methods
staticGetGuiTypeName
Returns type name of the GUI element used for finding GUI element styles.
SetValue
Current value in the input field.
Value will be clamped according to range and step.
GetValue
SetRange
Sets a minimum and maximum allowed values in the input field.
Set to large negative/positive values if you don't require clamping.
SetStep
Determines the minimum change allowed for the input field.
GetStep
HasInputFocus
Checks is the input field currently active.
staticCreate
Creates a new GUI editor field with a label.
- labelContent
- Content to display in the editor field label.
- labelWidth
- Width of the label in pixels.
- styleClass
- Style class that will be used for determining GUI element visuals from the current style sheet. If no class is provided, default style is determined based on GUI element type.
Fields
Internal
Methods
SetValueInternal
Sets a new value in the input field, and also allows you to choose should the field trigger an onValueChanged event.
Protected
Methods
~GUIIntField
HasCustomCursor
Checks if the GUI element has a custom cursor and outputs the cursor type if it does.
DoOnMouseEvent
Called when a mouse event is received on any GUI element the mouse is interacting with.
Return true if you have processed the event and don't want other elements to process it.
ValueChanged
Triggered when the input box value changes.
DoOnFocusGained
Triggers when the input box receives keyboard focus.
DoOnFocusLost
Triggers when the input box loses keyboard focus.
InputConfirmed
Triggered when the users confirms input in the input box.
SetText
Updates the underlying input box with the text representing the provided integer value.
ApplyRangeAndStep
Clamps the provided value to current valid range, and step interval.
staticIntFilter
Callback that checks can the provided string be converted to an integer value.