-
Couldn't load subscription status.
- Fork 19
(API) Checkbox
A standard checkbox
local checkbox = loveframes.Create("checkbox")Called every time the object becomes checked or unchecked
Arguments passed: self [object], checked [boolean]
local checkbox = loveframes.Create("checkbox")
checkbox:SetText("Checkbox")
checkbox:SetPos(5, 30)
checkbox.OnChanged = function(object, value)
print(value)
endSets the object's text
object:SetText(text[string])Gets the object's text
Returns 1 value: text [string]
local text = object:GetText()Sets whether the object is checked or not
object:SetChecked(checked[boolean])Gets whether the object is checked or not
Returns 1 value: checked [boolean]
local checked = object:GetChecked()Sets the object's font
object:SetFont(font[font])Gets the object's font
Returns 1 value: font [font]
local font = object:GetFont()Gets the object's box size
Returns 2 values: boxwidth [number], boxheight [number]
local boxwidth, boxheight = checkbox:GetBoxSize()Gets the object's box width
Returns 1 value: boxwidth [number]
local boxwidth = checkbox:GetBoxWidth()Gets the object's box height
Returns 1 value: boxheight [number]
local boxheight = checkbox:GetBoxHeight()Enables or disables the object
object:SetEnabled(enabled[bool])Gets whether or not the object is enabled
Returns 1 value: enabled [bool]
local enabled = object:GetEnabled()