diff --git a/docs/api.html b/docs/api.html index da229e3..ecbb3c3 100644 --- a/docs/api.html +++ b/docs/api.html @@ -1,5920 +1,3748 @@ - + -
(method) Animation:apply(element: Element) + + + +Animation +apply +(method) Animation:apply(element: Element) - - duration - - number +duration +number - - elapsed - - number +elapsed +number - - fade - - function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) +fade +function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) -> Animation - Create a simple fade animation - - final - - { width: number, height: number, opacity: number } +Create a simple fade animation +final +{ width: number, height: number, opacity: number } - - interpolate - - (method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Animation:apply(element: Element)
number +duration +number - - elapsed - - number +elapsed +number - - fade - - function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) +fade +function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) -> Animation - Create a simple fade animation - - final - - { width: number, height: number, opacity: number } +Create a simple fade animation +final +{ width: number, height: number, opacity: number } - - interpolate - - (method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
number
number +elapsed +number - - fade - - function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) +fade +function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) -> Animation - Create a simple fade animation - - final - - { width: number, height: number, opacity: number } +Create a simple fade animation +final +{ width: number, height: number, opacity: number } - - interpolate - - (method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) +fade +function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) -> Animation - Create a simple fade animation - - final - - { width: number, height: number, opacity: number } +Create a simple fade animation +final +{ width: number, height: number, opacity: number } - - interpolate - - (method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Animation.fade(duration: number, fromOpacity: number, toOpacity: number) -> Animation
Create a simple fade animation
{ width: number, height: number, opacity: number } +Create a simple fade animation +final +{ width: number, height: number, opacity: number } - - interpolate - - (method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ width: number, height: number, opacity: number }
(method) Animation:interpolate() +interpolate +(method) Animation:interpolate() -> table - - new - - function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Animation:interpolate() -> table
function Animation.new(props: AnimationProps) +new +function Animation.new(props: AnimationProps) -> Animation - - scale - - function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Animation.new(props: AnimationProps) -> Animation
function Animation.scale(duration: number, fromScale: table, toScale: table) +scale +function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation - Create a simple scale animation - - @param fromScale — {width:number,height:number} - - - @param toScale — {width:number,height:number} - - - start - - { width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Animation.scale(duration: number, fromScale: table, toScale: table) -> Animation
Create a simple scale animation
- @param fromScale — {width:number,height:number} -
fromScale
- @param toScale — {width:number,height:number} -
toScale
{ width: number, height: number, opacity: number } +Create a simple scale animation +@param fromScale — {width:number,height:number} +@param toScale — {width:number,height:number} +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param fromScale — {width:number,height:number}
@param toScale — {width:number,height:number}
table? +transform +table? - - transition - - table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
table?
table? +transition +table? - - update - - (method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Animation:update(dt: number) +update +(method) Animation:update(dt: number) -> boolean - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Animation:update(dt: number) -> boolean
- - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - -
- Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. -
_
Animation + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Animation - - _resultDirty - - boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
+Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. +
Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice.
Animation
boolean +_resultDirty +boolean - - AnimationProps - - - duration - - number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
boolean
number +AnimationProps +duration +number - - final - - { width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ width: number, height: number, opacity: number } +final +{ width: number, height: number, opacity: number } - - start - - { width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ width: number, height: number, opacity: number } +start +{ width: number, height: number, opacity: number } - - transform - - table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
table? +transform +table? - - transition - - table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
table? +transition +table? - - - Color - - a - number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
number + +Color +a +number - Alpha component (0-1) - b - number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Alpha component (0-1)
number +Alpha component (0-1) +b +number - Blue component (0-1) - - fromHex - - function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Blue component (0-1)
function Color.fromHex(hexWithTag: string) +Blue component (0-1) +fromHex +function Color.fromHex(hexWithTag: string) -> Color - - Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats - - - @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” - - g - number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.fromHex(hexWithTag: string) -> Color
- Convert hex string to color Supports both 6-digit (#RRGGBB) and - 8-digit (#RRGGBBAA) hex formats -
- @param hexWithTag — e.g. “#RRGGBB” or - “#RRGGBBAA” -
hexWithTag
number +Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats +@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA” +g +number - Green component (0-1) - - isValidColorFormat - - function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Convert hex string to color +Supports both 6-digit (#RRGGBB) and 8-digit (#RRGGBBAA) hex formats
@param hexWithTag — e.g. “#RRGGBB” or “#RRGGBBAA”
Green component (0-1)
function Color.isValidColorFormat(value: any) +Green component (0-1) +isValidColorFormat +function Color.isValidColorFormat(value: any) -> format: string? - Check if a value is a valid color format - @param value — Value to check - - @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) - - - new - - function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.isValidColorFormat(value: any) -> format: string?
Check if a value is a valid color format
@param value — Value to check
value
- @return format — Format type (hex, rgb, rgba, - named, table, nil if invalid) -
format
function Color.new(r?: number, g?: number, b?: number, a?: number) +Check if a value is a valid color format +@param value — Value to check +@return format — Format type (hex, rgb, rgba, named, table, nil if invalid) +new +function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color - Create a new color instance - - parse - - function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@return format — Format type (hex, rgb, rgba, named, table, nil if invalid)
function Color.new(r?: number, g?: number, b?: number, a?: number) -> Color
Create a new color instance
function Color.parse(value: any) +Create a new color instance +parse +function Color.parse(value: any) -> Color - Parse a color from various formats - - @param value — Color value (hex, named, table) - - @return — Parsed color - r - number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.parse(value: any) -> Color
Parse a color from various formats
- @param value — Color value (hex, named, table) -
@return — Parsed color
number +Parse a color from various formats +@param value — Color value (hex, named, table) +@return — Parsed color +r +number - Red component (0-1) - - sanitizeColor - - function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param value — Color value (hex, named, table)
Red component (0-1)
function Color.sanitizeColor(value: any, default?: Color) +Red component (0-1) +sanitizeColor +function Color.sanitizeColor(value: any, default?: Color) -> Color - Sanitize a color value - @param value — Color value to sanitize - @param default — Default color if invalid - @return — Sanitized color - - toRGBA - - (method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.sanitizeColor(value: any, default?: Color) -> Color
Sanitize a color value
@param value — Color value to sanitize
@param default — Default color if invalid
default
@return — Sanitized color
(method) Color:toRGBA() +Sanitize a color value +@param value — Color value to sanitize +@param default — Default color if invalid +@return — Sanitized color +toRGBA +(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number - - validateColor - - function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Color:toRGBA() -> r: number 2. g: number 3. b: number 4. a: number
function Color.validateColor(value: any, options?: table) +validateColor +function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string? - Validate a color value - @param value — Color value to validate - @param options — Validation options - @return valid — True if valid - @return error — Error message if invalid - - validateColorChannel - - function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.validateColor(value: any, options?: table) -> valid: boolean 2. error: string?
Validate a color value
@param value — Color value to validate
@param options — Validation options
options
@return valid — True if valid
valid
@return error — Error message if invalid
error
function Color.validateColorChannel(value: any, max?: number) +Validate a color value +@param value — Color value to validate +@param options — Validation options +@return valid — True if valid +@return error — Error message if invalid +validateColorChannel +function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number? - Validate a single color channel value - @param value — Value to validate - - @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) - - @return valid — True if valid - - @return clamped — Clamped value in 0-1 range - - - validateHexColor - - function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.validateColorChannel(value: any, max?: number) -> valid: boolean 2. clamped: number?
Validate a single color channel value
@param value — Value to validate
- @param max — Maximum value (255 for 0-255 range, - 1 for 0-1 range) -
max
- @return clamped — Clamped value in 0-1 range -
clamped
function Color.validateHexColor(hex: string) +Validate a single color channel value +@param value — Value to validate +@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range) +@return valid — True if valid +@return clamped — Clamped value in 0-1 range +validateHexColor +function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string? - Validate hex color format - - @param hex — Hex color string (with or without - #) - - @return valid — True if valid format - @return error — Error message if invalid - - validateNamedColor - - function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param max — Maximum value (255 for 0-255 range, 1 for 0-1 range)
@return clamped — Clamped value in 0-1 range
function Color.validateHexColor(hex: string) -> valid: boolean 2. error: string?
Validate hex color format
- @param hex — Hex color string (with or without - #) -
hex
@return valid — True if valid format
function Color.validateNamedColor(name: string) +Validate hex color format +@param hex — Hex color string (with or without #) +@return valid — True if valid format +@return error — Error message if invalid +validateNamedColor +function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string? - Validate named color - @param name — Color name - @return valid — True if valid - @return error — Error message if invalid - - validateRGBColor - - function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param hex — Hex color string (with or without #)
function Color.validateNamedColor(name: string) -> valid: boolean 2. error: string?
Validate named color
@param name — Color name
name
function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) +Validate named color +@param name — Color name +@return valid — True if valid +@return error — Error message if invalid +validateRGBColor +function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string? - Validate RGB/RGBA color values - @param r — Red component - @param g — Green component - @param b — Blue component - @param a — Alpha component (optional) - @param max — Maximum value (255 or 1) - @return valid — True if valid - @return error — Error message if invalid - - - - ⚠️ Internal Properties - - - - Warning: The following properties are internal - implementation details and should not be accessed directly. They are - prefixed with _ to indicate they are private. Accessing - these properties may break in future versions without notice. - - - - - __index - - Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
function Color.validateRGBColor(r: number, g: number, b: number, a?: number, max?: number) -> valid: boolean 2. error: string?
Validate RGB/RGBA color values
@param r — Red component
r
@param g — Green component
g
@param b — Blue component
b
@param a — Alpha component (optional)
a
@param max — Maximum value (255 or 1)
Color +Validate RGB/RGBA color values +@param r — Red component +@param g — Green component +@param b — Blue component +@param a — Alpha component (optional) +@param max — Maximum value (255 or 1) +@return valid — True if valid +@return error — Error message if invalid + + +⚠️ Internal Properties + +Warning: The following properties are internal implementation details and should not be accessed directly. They are prefixed with _ to indicate they are private. Accessing these properties may break in future versions without notice. + + +__index +Color - Utility class for color handling - - Element - - - active - - boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Color
Utility class for color handling
boolean? +Utility class for color handling +Element +active +boolean? - - Whether the element is active/focused (for inputs, default: false) - - - addChild - - (method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
boolean?
- Whether the element is active/focused (for inputs, default: false) -
(method) Element:addChild(child: Element) +Whether the element is active/focused (for inputs, default: false) +addChild +(method) Element:addChild(child: Element) - Add child to element - - alignContent - - AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Whether the element is active/focused (for inputs, default: false)
(method) Element:addChild(child: Element)
Add child to element
AlignContent +Add child to element +alignContent +AlignContent - - Alignment of lines in multi-line flex containers (default: STRETCH) - - - alignItems - - AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
AlignContent
- Alignment of lines in multi-line flex containers (default: STRETCH) -
AlignItems +Alignment of lines in multi-line flex containers (default: STRETCH) +alignItems +AlignItems - Alignment of items along cross axis (default: STRETCH) - - alignSelf - - AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Alignment of lines in multi-line flex containers (default: STRETCH)
AlignItems
Alignment of items along cross axis (default: STRETCH)
AlignSelf +Alignment of items along cross axis (default: STRETCH) +alignSelf +AlignSelf - Alignment of the item itself along cross axis (default: AUTO) - - animation - - table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
AlignSelf
Alignment of the item itself along cross axis (default: AUTO)
table? +Alignment of the item itself along cross axis (default: AUTO) +animation +table? - Animation instance for this element - - applyPositioningOffsets - - (method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Animation instance for this element
(method) Element:applyPositioningOffsets(element: any) +Animation instance for this element +applyPositioningOffsets +(method) Element:applyPositioningOffsets(element: any) - - Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to - - - autoGrow - - boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:applyPositioningOffsets(element: any)
- Apply positioning offsets (top, right, bottom, left) to an element - @param element The element to apply offsets to -
boolean +Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to +autoGrow +boolean - Whether element auto-grows with text (default: false) - - autoScaleText - - boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Apply positioning offsets (top, right, bottom, left) to an element +@param element The element to apply offsets to
Whether element auto-grows with text (default: false)
boolean +Whether element auto-grows with text (default: false) +autoScaleText +boolean - Whether text should auto-scale with window size (default: true) - - autosizing - - { width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Whether text should auto-scale with window size (default: true)
{ width: boolean, height: boolean } +Whether text should auto-scale with window size (default: true) +autosizing +{ width: boolean, height: boolean } - Whether the element should automatically size to fit its children - - backdropBlur - - { intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ width: boolean, height: boolean }
Whether the element should automatically size to fit its children
{ intensity: number, quality: number }? +Whether the element should automatically size to fit its children +backdropBlur +{ intensity: number, quality: number }? - Blur content behind the element (intensity: 0-100, quality: 1-10) - - backgroundColor - - Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ intensity: number, quality: number }?
Blur content behind the element (intensity: 0-100, quality: 1-10)
Color +Blur content behind the element (intensity: 0-100, quality: 1-10) +backgroundColor +Color - Background color of the element - - blur - - (method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Background color of the element
(method) Element:blur() +Background color of the element +blur +(method) Element:blur() - Remove focus from this element - - border - - Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:blur()
Remove focus from this element
Border +Remove focus from this element +border +Border - Border configuration for the element - - borderColor - - Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Border
Border configuration for the element
Color +Border configuration for the element +borderColor +Color - Color of the border - - bottom - - number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Color of the border
number? +Color of the border +bottom +number? - Offset from bottom edge (CSS-style positioning) - - calculateAutoHeight - - (method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
number?
Offset from bottom edge (CSS-style positioning)
(method) Element:calculateAutoHeight() +Offset from bottom edge (CSS-style positioning) +calculateAutoHeight +(method) Element:calculateAutoHeight() -> number - Calculate auto height based on children - - calculateAutoWidth - - (method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:calculateAutoHeight() -> number
Calculate auto height based on children
(method) Element:calculateAutoWidth() +Calculate auto height based on children +calculateAutoWidth +(method) Element:calculateAutoWidth() -> number - - calculateTextHeight - - (method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:calculateAutoWidth() -> number
(method) Element:calculateTextHeight() +calculateTextHeight +(method) Element:calculateTextHeight() -> number - - calculateTextWidth - - (method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:calculateTextHeight() -> number
(method) Element:calculateTextWidth() +calculateTextWidth +(method) Element:calculateTextWidth() -> number - Calculate text width for button - - children - - table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:calculateTextWidth() -> number
Calculate text width for button
table<integer, Element> +Calculate text width for button +children +table<integer, Element> - Children of this element - - clearChildren - - (method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
table<integer, Element>
Children of this element
(method) Element:clearChildren() +Children of this element +clearChildren +(method) Element:clearChildren() - Remove all children from this element - - clearSelection - - (method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:clearChildren()
Remove all children from this element
(method) Element:clearSelection() +Remove all children from this element +clearSelection +(method) Element:clearSelection() - Clear selection - - columnGap - - (string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:clearSelection()
Clear selection
(string|number)? +Clear selection +columnGap +(string|number)? - Gap between grid columns - - contains - - (method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(string|number)?
Gap between grid columns
(method) Element:contains(x: number, y: number) +Gap between grid columns +contains +(method) Element:contains(x: number, y: number) -> boolean - Check if point is inside element bounds - - contentAutoSizingMultiplier - - { width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:contains(x: number, y: number) -> boolean
Check if point is inside element bounds
{ width: number?, height: number? }? +Check if point is inside element bounds +contentAutoSizingMultiplier +{ width: number?, height: number? }? - Multiplier for auto-sized content dimensions - - contentBlur - - { intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ width: number?, height: number? }?
Multiplier for auto-sized content dimensions
{ intensity: number, quality: number }? +Multiplier for auto-sized content dimensions +contentBlur +{ intensity: number, quality: number }? - - Blur the element’s content including children (intensity: 0-100, - quality: 1-10) - - - cornerRadius - - (number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
- Blur the element’s content including children (intensity: 0-100, - quality: 1-10) -
(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? +Blur the element’s content including children (intensity: 0-100, quality: 1-10) +cornerRadius +(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })? - Corner radius for rounded corners (default: 0) - - cursorBlinkRate - - number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Blur the element’s content including children (intensity: 0-100, quality: 1-10)
(number|{ topLeft: number?, topRight: number?, bottomLeft: number?, bottomRight: number? })?
Corner radius for rounded corners (default: 0)
number +Corner radius for rounded corners (default: 0) +cursorBlinkRate +number - Cursor blink rate in seconds (default: 0.5) - - cursorColor - - Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Cursor blink rate in seconds (default: 0.5)
Color? +Cursor blink rate in seconds (default: 0.5) +cursorColor +Color? - Cursor color (default: nil, uses textColor) - - deleteSelection - - (method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Color?
Cursor color (default: nil, uses textColor)
(method) Element:deleteSelection() +Cursor color (default: nil, uses textColor) +deleteSelection +(method) Element:deleteSelection() -> boolean - Delete selected text - @return — True if text was deleted - - deleteText - - (method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:deleteSelection() -> boolean
Delete selected text
@return — True if text was deleted
(method) Element:deleteText(startPos: number, endPos: number) +Delete selected text +@return — True if text was deleted +deleteText +(method) Element:deleteText(startPos: number, endPos: number) - - @param startPos — Start position (inclusive) - - @param endPos — End position (inclusive) - - destroy - - (method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:deleteText(startPos: number, endPos: number)
- @param startPos — Start position (inclusive) -
startPos
@param endPos — End position (inclusive)
endPos
(method) Element:destroy() +@param startPos — Start position (inclusive) +@param endPos — End position (inclusive) +destroy +(method) Element:destroy() - Destroy element and its children - - disableHighlight - - boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param startPos — Start position (inclusive)
(method) Element:destroy()
Destroy element and its children
boolean? +Destroy element and its children +disableHighlight +boolean? - - Whether to disable the pressed state highlight overlay (default: - false) - - - disabled - - boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
- Whether to disable the pressed state highlight overlay (default: - false) -
boolean? +Whether to disable the pressed state highlight overlay (default: false) +disabled +boolean? - Whether the element is disabled (default: false) - - draw - - (method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Whether to disable the pressed state highlight overlay (default: false)
Whether the element is disabled (default: false)
(method) Element:draw(backdropCanvas: any) +Whether the element is disabled (default: false) +draw +(method) Element:draw(backdropCanvas: any) - Draw element and its children - - editable - - boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:draw(backdropCanvas: any)
Draw element and its children
boolean +Draw element and its children +editable +boolean - Whether the element is editable (default: false) - - flexDirection - - FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Whether the element is editable (default: false)
FlexDirection +Whether the element is editable (default: false) +flexDirection +FlexDirection - Direction of flex layout (default: HORIZONTAL) - - flexWrap - - FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
FlexDirection
Direction of flex layout (default: HORIZONTAL)
FlexWrap +Direction of flex layout (default: HORIZONTAL) +flexWrap +FlexWrap - Whether children wrap to multiple lines (default: NOWRAP) - - focus - - (method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
FlexWrap
Whether children wrap to multiple lines (default: NOWRAP)
(method) Element:focus() +Whether children wrap to multiple lines (default: NOWRAP) +focus +(method) Element:focus() - Focus this element for keyboard input - - fontFamily - - string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:focus()
Focus this element for keyboard input
string? +Focus this element for keyboard input +fontFamily +string? - Font family name from theme or path to font file - - gap - - string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
string?
Font family name from theme or path to font file
string|number +Font family name from theme or path to font file +gap +string|number - Space between children elements (default: 10) - - getAvailableContentHeight - - (method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
string|number
Space between children elements (default: 10)
(method) Element:getAvailableContentHeight() +Space between children elements (default: 10) +getAvailableContentHeight +(method) Element:getAvailableContentHeight() -> number - - Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights - - - getAvailableContentWidth - - (method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getAvailableContentHeight() -> number
- Get available content height for children (accounting for 9-patch - content padding) This is the height that children should use when - calculating percentage heights -
(method) Element:getAvailableContentWidth() +Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights +getAvailableContentWidth +(method) Element:getAvailableContentWidth() -> number - - Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths - - - getBlurInstance - - (method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Get available content height for children (accounting for 9-patch content padding) +This is the height that children should use when calculating percentage heights
(method) Element:getAvailableContentWidth() -> number
- Get available content width for children (accounting for 9-patch - content padding) This is the width that children should use when - calculating percentage widths -
(method) Element:getBlurInstance() +Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths +getBlurInstance +(method) Element:getBlurInstance() -> table? - Get or create blur instance for this element - @return — Blur instance or nil if no blur configured - - getBorderBoxHeight - - (method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Get available content width for children (accounting for 9-patch content padding) +This is the width that children should use when calculating percentage widths
(method) Element:getBlurInstance() -> table?
Get or create blur instance for this element
@return — Blur instance or nil if no blur configured
(method) Element:getBorderBoxHeight() +Get or create blur instance for this element +@return — Blur instance or nil if no blur configured +getBorderBoxHeight +(method) Element:getBorderBoxHeight() -> number - Get border-box height (including padding) - - getBorderBoxWidth - - (method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getBorderBoxHeight() -> number
Get border-box height (including padding)
(method) Element:getBorderBoxWidth() +Get border-box height (including padding) +getBorderBoxWidth +(method) Element:getBorderBoxWidth() -> number - Get border-box width (including padding) - - getBounds - - (method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getBorderBoxWidth() -> number
Get border-box width (including padding)
(method) Element:getBounds() +Get border-box width (including padding) +getBounds +(method) Element:getBounds() -> { x: number, y: number, width: number, height: number } - Get element bounds (content box) - - getChildCount - - (method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getBounds() -> { x: number, y: number, width: number, height: number }
Get element bounds (content box)
(method) Element:getChildCount() +Get element bounds (content box) +getChildCount +(method) Element:getChildCount() -> number - Get the number of children this element has - - getContentSize - - (method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getChildCount() -> number
Get the number of children this element has
(method) Element:getContentSize() +Get the number of children this element has +getContentSize +(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number - - Get content dimensions (including overflow) (delegates to - ScrollManager) - - - getCursorPosition - - (method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getContentSize() -> contentWidth: number 2. contentHeight: number
- Get content dimensions (including overflow) (delegates to - ScrollManager) -
(method) Element:getCursorPosition() +Get content dimensions (including overflow) (delegates to ScrollManager) +getCursorPosition +(method) Element:getCursorPosition() -> number - Get cursor position - @return — Character index (0-based) - - getMaxScroll - - (method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Get content dimensions (including overflow) (delegates to ScrollManager)
(method) Element:getCursorPosition() -> number
Get cursor position
@return — Character index (0-based)
(method) Element:getMaxScroll() +Get cursor position +@return — Character index (0-based) +getMaxScroll +(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number - Get maximum scroll bounds (delegates to ScrollManager) - - getScaledContentPadding - - (method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getMaxScroll() -> maxScrollX: number 2. maxScrollY: number
Get maximum scroll bounds (delegates to ScrollManager)
(method) Element:getScaledContentPadding() +Get maximum scroll bounds (delegates to ScrollManager) +getScaledContentPadding +(method) Element:getScaledContentPadding() -> table|nil - - Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size - - - @return — {left, top, right, bottom} or nil if no - contentPadding - - - getScrollPercentage - - (method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getScaledContentPadding() -> table|nil
- Get the current state’s scaled content padding Returns the - contentPadding for the current theme state, scaled to the element’s - size -
- @return — {left, top, right, bottom} or nil if no - contentPadding -
(method) Element:getScrollPercentage() +Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size +@return — {left, top, right, bottom} or nil if no contentPadding +getScrollPercentage +(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number - Get scroll percentage (0-1) (delegates to ScrollManager) - - getScrollPosition - - (method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Get the current state’s scaled content padding +Returns the contentPadding for the current theme state, scaled to the element’s size
@return — {left, top, right, bottom} or nil if no contentPadding
(method) Element:getScrollPercentage() -> percentX: number 2. percentY: number
Get scroll percentage (0-1) (delegates to ScrollManager)
(method) Element:getScrollPosition() +Get scroll percentage (0-1) (delegates to ScrollManager) +getScrollPosition +(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number - Get current scroll position (delegates to ScrollManager) - - getSelectedText - - (method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getScrollPosition() -> scrollX: number 2. scrollY: number
Get current scroll position (delegates to ScrollManager)
(method) Element:getSelectedText() +Get current scroll position (delegates to ScrollManager) +getSelectedText +(method) Element:getSelectedText() -> string? - Get selected text - @return — Selected text or nil if no selection - - getSelection - - (method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getSelectedText() -> string?
Get selected text
@return — Selected text or nil if no selection
(method) Element:getSelection() +Get selected text +@return — Selected text or nil if no selection +getSelection +(method) Element:getSelection() -> number? 2. number? - Get selection range - - @return — Start and end positions, or nil if no selection - - - getText - - (method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:getSelection() -> number? 2. number?
Get selection range
- @return — Start and end positions, or nil if no selection -
(method) Element:getText() +Get selection range +@return — Start and end positions, or nil if no selection +getText +(method) Element:getText() -> string - Get current text buffer - - gridColumns - - number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@return — Start and end positions, or nil if no selection
(method) Element:getText() -> string
Get current text buffer
number? +Get current text buffer +gridColumns +number? - Number of columns in the grid - - gridRows - - number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Number of columns in the grid
number? +Number of columns in the grid +gridRows +number? - Number of rows in the grid - - hasOverflow - - (method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Number of rows in the grid
(method) Element:hasOverflow() +Number of rows in the grid +hasOverflow +(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean - Check if element has overflow (delegates to ScrollManager) - - hasSelection - - (method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:hasOverflow() -> hasOverflowX: boolean 2. hasOverflowY: boolean
Check if element has overflow (delegates to ScrollManager)
(method) Element:hasSelection() +Check if element has overflow (delegates to ScrollManager) +hasSelection +(method) Element:hasSelection() -> boolean - Check if there is an active selection - - height - - string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:hasSelection() -> boolean
Check if there is an active selection
string|number +Check if there is an active selection +height +string|number - Height of the element - - hide - - (method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Height of the element
(method) Element:hide() +Height of the element +hide +(method) Element:hide() - same as calling updateOpacity(0) - - hideScrollbars - - (boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:hide()
same as calling updateOpacity(0)
(boolean|{ vertical: boolean, horizontal: boolean })? +same as calling updateOpacity(0) +hideScrollbars +(boolean|{ vertical: boolean, horizontal: boolean })? - - Hide scrollbars (boolean for both, or table for individual control) - - - id - - string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(boolean|{ vertical: boolean, horizontal: boolean })?
- Hide scrollbars (boolean for both, or table for individual control) -
string +Hide scrollbars (boolean for both, or table for individual control) +id +string - - image - - (love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Hide scrollbars (boolean for both, or table for individual control)
string
(love.Image)? +image +(love.Image)? - Image object to display - - imageOpacity - - number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(love.Image)?
Image object to display
number? +Image object to display +imageOpacity +number? - Image opacity 0-1 (default: 1, combines with element opacity) - - imagePath - - string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Image opacity 0-1 (default: 1, combines with element opacity)
string? +Image opacity 0-1 (default: 1, combines with element opacity) +imagePath +string? - Path to image file (auto-loads via ImageCache) - - inputType - - "email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Path to image file (auto-loads via ImageCache)
"email"|"number"|"text"|"url" +Path to image file (auto-loads via ImageCache) +inputType +"email"|"number"|"text"|"url" - Input type for validation (default: “text”) - - insertText - - (method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
"email"|"number"|"text"|"url"
Input type for validation (default: “text”)
(method) Element:insertText(text: string, position?: number) +Input type for validation (default: “text”) +insertText +(method) Element:insertText(text: string, position?: number) - Insert text at position - @param text — Text to insert - - @param position — Position to insert at - (default: cursor position) - - - isFocused - - (method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:insertText(text: string, position?: number)
Insert text at position
@param text — Text to insert
text
- @param position — Position to insert at - (default: cursor position) -
position
(method) Element:isFocused() +Insert text at position +@param text — Text to insert +@param position — Position to insert at (default: cursor position) +isFocused +(method) Element:isFocused() -> boolean - Check if this element is focused - - justifyContent - - JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param position — Position to insert at (default: cursor position)
(method) Element:isFocused() -> boolean
Check if this element is focused
JustifyContent +Check if this element is focused +justifyContent +JustifyContent - Alignment of items along main axis (default: FLEX_START) - - justifySelf - - JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
JustifyContent
Alignment of items along main axis (default: FLEX_START)
JustifySelf +Alignment of items along main axis (default: FLEX_START) +justifySelf +JustifySelf - Alignment of the item itself along main axis (default: AUTO) - - keypressed - - (method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
JustifySelf
Alignment of the item itself along main axis (default: AUTO)
(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) +Alignment of the item itself along main axis (default: AUTO) +keypressed +(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean) - Handle key press (special keys) - @param key — Key name - @param scancode — Scancode - - @param isrepeat — Whether this is a key repeat - - - layoutChildren - - (method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:keypressed(key: string, scancode: string, isrepeat: boolean)
Handle key press (special keys)
@param key — Key name
key
@param scancode — Scancode
scancode
- @param isrepeat — Whether this is a key repeat -
isrepeat
(method) Element:layoutChildren() +Handle key press (special keys) +@param key — Key name +@param scancode — Scancode +@param isrepeat — Whether this is a key repeat +layoutChildren +(method) Element:layoutChildren() - - left - - number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param isrepeat — Whether this is a key repeat
(method) Element:layoutChildren()
number? +left +number? - Offset from left edge (CSS-style positioning) - - margin - - { top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Offset from left edge (CSS-style positioning)
{ top: number, right: number, bottom: number, left: number } +Offset from left edge (CSS-style positioning) +margin +{ top: number, right: number, bottom: number, left: number } - - Margin around children (default: {top=0, right=0, bottom=0, left=0}) - - - maxLength - - number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
{ top: number, right: number, bottom: number, left: number }
- Margin around children (default: {top=0, right=0, bottom=0, left=0}) -
number? +Margin around children (default: {top=0, right=0, bottom=0, left=0}) +maxLength +number? - Maximum text length in characters (default: nil) - - maxLines - - number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Margin around children (default: {top=0, right=0, bottom=0, left=0})
Maximum text length in characters (default: nil)
number? +Maximum text length in characters (default: nil) +maxLines +number? - Maximum number of lines (default: nil) - - maxTextSize - - number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
Maximum number of lines (default: nil)
number? +Maximum number of lines (default: nil) +maxTextSize +number? - - minTextSize - - number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
number? +minTextSize +number? - - moveCursorBy - - (method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorBy(delta: number) +moveCursorBy +(method) Element:moveCursorBy(delta: number) - Move cursor by delta characters - - @param delta — Number of characters to move - (positive or negative) - - - moveCursorToEnd - - (method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorBy(delta: number)
Move cursor by delta characters
- @param delta — Number of characters to move - (positive or negative) -
delta
(method) Element:moveCursorToEnd() +Move cursor by delta characters +@param delta — Number of characters to move (positive or negative) +moveCursorToEnd +(method) Element:moveCursorToEnd() - Move cursor to end of text - - moveCursorToLineEnd - - (method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
@param delta — Number of characters to move (positive or negative)
(method) Element:moveCursorToEnd()
Move cursor to end of text
(method) Element:moveCursorToLineEnd() +Move cursor to end of text +moveCursorToLineEnd +(method) Element:moveCursorToLineEnd() - Move cursor to end of current line - - moveCursorToLineStart - - (method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorToLineEnd()
Move cursor to end of current line
(method) Element:moveCursorToLineStart() +Move cursor to end of current line +moveCursorToLineStart +(method) Element:moveCursorToLineStart() - Move cursor to start of current line - - moveCursorToNextWord - - (method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorToLineStart()
Move cursor to start of current line
(method) Element:moveCursorToNextWord() +Move cursor to start of current line +moveCursorToNextWord +(method) Element:moveCursorToNextWord() - Move cursor to start of next word - - moveCursorToPreviousWord - - (method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorToNextWord()
Move cursor to start of next word
(method) Element:moveCursorToPreviousWord() +Move cursor to start of next word +moveCursorToPreviousWord +(method) Element:moveCursorToPreviousWord() - Move cursor to start of previous word - - moveCursorToStart - - (method) Element:moveCursorToStart() +Move cursor to start of previous word +
(method) Element:moveCursorToPreviousWord()
Move cursor to start of previous word
(method) Element:moveCursorToStart() +Move cursor to start of previous word +