---@meta ---@class EditBox : Frame, FontInstance EditBox = { --- Adds text to the edit history. --- @param self EditBox --- @param text string The text to add to the history. --- @example --- myEditBox:AddHistoryLine("Previous input") AddHistoryLine = function(self, text) end, --- Removes text input focus from this edit box. --- @param self EditBox --- @example --- myEditBox:ClearFocus() ClearFocus = function(self) end, --- Returns whether only alt+arrow keys work for navigating the edit box, not arrow keys alone. --- @param self EditBox --- @return boolean ignoreArrows True if only alt+arrow keys are used. --- @example --- local ignoreArrows = myEditBox:GetAltArrowKeyMode() GetAltArrowKeyMode = function(self) end, --- Gets the blink speed of the EditBox in seconds. --- @param self EditBox --- @return number blinkSpeed The blink speed of the cursor. --- @example --- local blinkSpeed = myEditBox:GetBlinkSpeed() GetBlinkSpeed = function(self) end, --- Gets the position of the cursor inside the EditBox. --- @param self EditBox --- @return number position The current cursor position. --- @example --- local cursorPos = myEditBox:GetCursorPosition() GetCursorPosition = function(self) end, --- Gets the number of history lines for this edit box. --- @param self EditBox --- @return number historyLines The number of history lines. --- @example --- local historyLines = myEditBox:GetHistoryLines() GetHistoryLines = function(self) end, --- Returns whether hyperlinks are enabled in the EditBox. --- @param self EditBox --- @return boolean enabled True if hyperlinks are enabled. --- @example --- local enabled = myEditBox:GetHyperlinksEnabled() GetHyperlinksEnabled = function(self) end, --- Gets the input language (locale based, not in-game). --- @param self EditBox --- @return string inputLanguage The current input language. --- @example --- local inputLanguage = myEditBox:GetInputLanguage() GetInputLanguage = function(self) end, --- Gets the maximum number of bytes allowed in the EditBox. --- @param self EditBox --- @return number maxBytes The maximum byte size. --- @example --- local maxBytes = myEditBox:GetMaxBytes() GetMaxBytes = function(self) end, --- Gets the maximum number of letters allowed in the EditBox. --- @param self EditBox --- @return number maxLetters The maximum number of letters. --- @example --- local maxLetters = myEditBox:GetMaxLetters() GetMaxLetters = function(self) end, --- Gets the number of letters in the box. --- @param self EditBox --- @return number numLetters The number of letters. --- @example --- local numLetters = myEditBox:GetNumLetters() GetNumLetters = function(self) end, --- Returns the number entered in the edit box, or 0 if the text is not a number. --- @param self EditBox --- @return number number The number entered. --- @example --- local number = myEditBox:GetNumber() GetNumber = function(self) end, --- Gets the current text contained in the edit box. --- @param self EditBox --- @return string text The current text. --- @example --- local text = myEditBox:GetText() GetText = function(self) end, --- Gets the text display insets for the EditBox. --- @param self EditBox --- @return number left The left inset. --- @return number right The right inset. --- @return number top The top inset. --- @return number bottom The bottom inset. --- @example --- local left, right, top, bottom = myEditBox:GetTextInsets() GetTextInsets = function(self) end, --- Sets the highlight to all or some of the edit box text. --- @param self EditBox --- @param startPos number? Optional. The start position of the highlight. --- @param endPos number? Optional. The end position of the highlight. --- @example --- myEditBox:HighlightText(1, 5) -- Highlight first 5 characters HighlightText = function(self, startPos, endPos) end, --- Inserts text into the edit box. --- @param self EditBox --- @param text string The text to insert. --- @example --- myEditBox:Insert("Hello") Insert = function(self, text) end, --- Determines if the EditBox has autofocus enabled. --- @param self EditBox --- @return boolean autoFocus True if auto focus is enabled. --- @example --- local autoFocus = myEditBox:IsAutoFocus() IsAutoFocus = function(self) end, --- Determines if the EditBox accepts multiple lines. --- @param self EditBox --- @return boolean multiLine True if multi-line is enabled. --- @example --- local multiLine = myEditBox:IsMultiLine() IsMultiLine = function(self) end, --- Determines if the EditBox only accepts numeric input. --- @param self EditBox --- @return boolean numeric True if numeric input is enabled. --- @example --- local numeric = myEditBox:IsNumeric() IsNumeric = function(self) end, --- Determines if the EditBox performs password masking. --- @param self EditBox --- @return boolean password True if password masking is enabled. --- @example --- local password = myEditBox:IsPassword() IsPassword = function(self) end, --- Sets whether only alt+arrow keys work for navigating the edit box. --- @param self EditBox --- @param enable boolean True to enable alt+arrow key navigation. --- @example --- myEditBox:SetAltArrowKeyMode(true) SetAltArrowKeyMode = function(self, enable) end, --- Sets whether or not the edit box will attempt to get input focus when it gets shown. --- @param self EditBox --- @param state boolean True to enable auto focus. --- @example --- myEditBox:SetAutoFocus(true) SetAutoFocus = function(self, state) end, --- Sets the blink speed of the cursor. --- @param self EditBox --- @param blinkSpeed number The blink speed to set. --- @example --- myEditBox:SetBlinkSpeed(0.5) SetBlinkSpeed = function(self, blinkSpeed) end, --- Sets the position of the cursor within the EditBox. --- @param self EditBox --- @param position number The position to set the cursor to. --- @example --- myEditBox:SetCursorPosition(5) -- Move cursor to the 5th character SetCursorPosition = function(self, position) end, --- Moves input focus (the cursor) to this edit box. --- @param self EditBox --- @example --- myEditBox:SetFocus() SetFocus = function(self) end, --- Sets the font to use for display. --- @param self EditBox --- @param font string The font to set. --- @param size number The size of the font. --- @param flags string? Optional. The font flags. --- @example --- myEditBox:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE") SetFont = function(self, font, size, flags) end, --- Sets the number of history lines to remember. --- @param self EditBox --- @param historyLines number The number of history lines. --- @example --- myEditBox:SetHistoryLines(10) SetHistoryLines = function(self, historyLines) end, --- Sets whether hyperlinks are enabled in the EditBox. --- @param self EditBox --- @param enableFlag boolean True to enable hyperlinks. --- @example --- myEditBox:SetHyperlinksEnabled(true) SetHyperlinksEnabled = function(self, enableFlag) end, --- Sets the maximum byte size for entered text. --- @param self EditBox --- @param maxBytes number The maximum byte size to set. --- @example --- myEditBox:SetMaxBytes(255) SetMaxBytes = function(self, maxBytes) end, --- Sets the maximum number of letters for entered text. --- @param self EditBox --- @param maxLetters number The maximum number of letters to set. --- @example --- myEditBox:SetMaxLetters(100) SetMaxLetters = function(self, maxLetters) end, --- Sets the EditBox's multi-line state. --- @param self EditBox --- @param state boolean True to enable multi-line input. --- @example --- myEditBox:SetMultiLine(true) SetMultiLine = function(self, state) end, --- Sets the number in the edit box. --- @param self EditBox --- @param number number The number to set. --- @example --- myEditBox:SetNumber(42) SetNumber = function(self, number) end, --- Sets if the EditBox only accepts numeric input. --- @param self EditBox --- @param state boolean True to enable numeric input only. --- @example --- myEditBox:SetNumeric(true) SetNumeric = function(self, state) end, --- Sets the EditBox's password masking state. --- @param self EditBox --- @param state boolean True to enable password masking. --- @example --- myEditBox:SetPassword(true) SetPassword = function(self, state) end, --- Sets the text contained in the edit box. --- @param self EditBox --- @param text string The text to set. --- @example --- myEditBox:SetText("Hello World") SetText = function(self, text) end, --- Sets the text display insets for the EditBox. --- @param self EditBox --- @param left number The left inset. --- @param right number The right inset. --- @param top number The top inset. --- @param bottom number The bottom inset. --- @example --- myEditBox:SetTextInsets(5, 5, 5, 5) SetTextInsets = function(self, left, right, top, bottom) end, --- Toggles the input language for the edit box. --- @param self EditBox --- @example --- myEditBox:ToggleInputLanguage() ToggleInputLanguage = function(self) end, }