guimltextctrl: members
42 implemented, 0 reserved. Entries are sorted by name.
Implemented
Section titled “Implemented”addtext
Section titled “addtext”guimltextctrl.addtext(text: string, replace: boolean) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Appends markup to a markup text control, or replaces its content when the second argument is true.
Log.addText("<b>hi</b><br>", false);Specification: gui.md§3.
allowcolorchars
Section titled “allowcolorchars”guimltextctrl.allowcolorchars: boolean
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { allowcolorchars = 1; }Specification: gui.md§3.
allowedtags
Section titled “allowedtags”guimltextctrl.allowedtags: string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { allowedtags = 1; }Specification: gui.md§3.
cleartext
Section titled “cleartext”guimltextctrl.cleartext() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Empties a markup text control.
Log.clearText();Specification: gui.md§3.
cursorposition
Section titled “cursorposition”guimltextctrl.cursorposition: number
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
The caret as a byte offset into the text; writing moves it.
Text.cursorposition = 0;Specification: gui.md§3.12.
deniedsound
Section titled “deniedsound”guimltextctrl.deniedsound: string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { deniedsound = 1; }Specification: gui.md§3.
deselecttext
Section titled “deselecttext”guimltextctrl.deselecttext() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Removes the text selection.
Control.deselecttext();Specification: gui.md§3.
disallowedtags
Section titled “disallowedtags”guimltextctrl.disallowedtags: string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { disallowedtags = 1; }Specification: gui.md§3.
findtext
Section titled “findtext”guimltextctrl.findtext(text: string, flags?: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the index of the first row with this text, or the position of the first match in multi-line text. The flags are 1 (wrap at the end of the text) plus 2 (case sensitive).
Control.findtext("");Specification: gui.md§3.
findtextat
Section titled “findtextat”guimltextctrl.findtextat(arg1: string, arg2: number, arg3: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the position of the first match of a text at or after a position, or -1.
Control.findtextat("", 0, 0);Specification: gui.md§3.
getcolumnandlineofposition
Section titled “getcolumnandlineofposition”guimltextctrl.getcolumnandlineofposition(arg1: number) -> string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the column and the line of a character position as an array.
Control.getcolumnandlineofposition(0);Specification: gui.md§3.
getcursorline
Section titled “getcursorline”guimltextctrl.getcursorline() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the line the text cursor is on.
Control.getcursorline();Specification: gui.md§3.
getline
Section titled “getline”guimltextctrl.getline(arg1: number) -> string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns one line of multi-line text.
Control.getline(0);Specification: gui.md§3.
getlinecount
Section titled “getlinecount”guimltextctrl.getlinecount() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the number of lines of multi-line text.
Control.getlinecount();Specification: gui.md§3.
getlines
Section titled “getlines”guimltextctrl.getlines() -> array
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the lines of multi-line text as an array.
Control.getlines();Specification: gui.md§3.
getselectedlength
Section titled “getselectedlength”guimltextctrl.getselectedlength() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns the length of the text selection, or -1 without one.
Control.getselectedlength();Specification: gui.md§3.
getselectedposition
Section titled “getselectedposition”guimltextctrl.getselectedposition() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Returns where the text selection starts, or -1 without one.
Control.getselectedposition();Specification: gui.md§3.
gettext
Section titled “gettext”guimltextctrl.gettext() -> string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
The text of a text edit or markup text control, as stored.
echo(Edit.getText());Specification: gui.md§3.
htmlcompatibility
Section titled “htmlcompatibility”guimltextctrl.htmlcompatibility: boolean
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Kept for scripts: asks for the markup rules of a web page.
new GuiMLTextCtrl("MyControl") { htmlcompatibility = true; }Specification: gui.md§3.12.
htmllinks
Section titled “htmllinks”guimltextctrl.htmllinks: boolean
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
When true a link to a name inside the text scrolls there on its own; other links only raise onURL.
new GuiMLTextCtrl("MyControl") { htmllinks = true; }Specification: gui.md§3.12.
maxchars
Section titled “maxchars”guimltextctrl.maxchars: number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { maxchars = 1; }Specification: gui.md§3.
onCursorLineChanged
Section titled “onCursorLineChanged”guimltextctrl.onCursorLineChanged(line: number)
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Raised when the caret moves to another line, with the line number counted from 0.
function MyControl.onCursorLineChanged(line) { echo(line);}Specification: gui.md§3.13.
onReflow
Section titled “onReflow”guimltextctrl.onReflow(width: number, height: number)
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Raised after the text was laid out again, with the width and height of the content.
function MyControl.onReflow(w, h) { echo(h);}Specification: gui.md§3.13.
onRightSelectTag
Section titled “onRightSelectTag”guimltextctrl.onRightSelectTag(tag: string)
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Raised when the right button is pressed on a block marked with a tag, with the tag value.
function MyControl.onRightSelectTag(tag) { echo(tag);}Specification: gui.md§3.12.
onSelectTag
Section titled “onSelectTag”guimltextctrl.onSelectTag(tag: string)
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Raised when the left button is pressed on a block marked with a tag, with the tag value.
function MyControl.onSelectTag(tag) { echo(tag);}Specification: gui.md§3.12.
guimltextctrl.onURL(href: string)
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Raised when a link of the markup text is clicked, with its address.
function MyControl.onURL(href) { echo("onURL");}Specification: gui.md§3.2.
parsetags
Section titled “parsetags”guimltextctrl.parsetags: boolean
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { parsetags = 1; }Specification: gui.md§3.
plaintext
Section titled “plaintext”guimltextctrl.plaintext: string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { plaintext = 1; }Specification: gui.md§3.
replacetext
Section titled “replacetext”guimltextctrl.replacetext(arg1: string, arg2: string, arg3: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Replaces every match of a text and returns how many were replaced.
Control.replacetext("", "", 0);Specification: gui.md§3.
scrolltoline
Section titled “scrolltoline”guimltextctrl.scrolltoline(arg1: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Scrolls multi-line text to a line.
Control.scrolltoline(0);Specification: gui.md§3.
scrolltoposition
Section titled “scrolltoposition”guimltextctrl.scrolltoposition(arg1: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Scrolls multi-line text to a character position.
Control.scrolltoposition(0);Specification: gui.md§3.
scrolltotag
Section titled “scrolltotag”guimltextctrl.scrolltotag(tag: string) -> boolean
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Scrolls to the place an anchor with that name marks. False when the text has none.
Text.scrollToTag("chapter2");Specification: gui.md§3.12.
selecttext
Section titled “selecttext”guimltextctrl.selecttext(arg1: number, arg2: number) -> boolean
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Selects a part of the text and returns whether it worked.
Control.selecttext(0, 0);Specification: gui.md§3.
setcursorcolumnandline
Section titled “setcursorcolumnandline”guimltextctrl.setcursorcolumnandline(column: number, line: number) -> number
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Moves the caret to the column of the line, both counted from 0.
Text.setCursorColumnAndLine(0, 3);Specification: gui.md§3.12.
setlines
Section titled “setlines”guimltextctrl.setlines(arg1: object) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Replaces the text with the lines of an array.
Control.setlines("");Specification: gui.md§3.
setscrolltop
Section titled “setscrolltop”guimltextctrl.setscrolltop(position: number) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Scrolls a markup text control to a vertical position in pixels; inside a scroll control the scroll control moves.
Log.setScrollTop(0);Specification: gui.md§3.
settext
Section titled “settext”guimltextctrl.settext(text: string) -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Replaces the text of a text edit; the caret goes to the end.
Edit.setText("hello");Specification: gui.md§3.
syntaxhighlighting
Section titled “syntaxhighlighting”guimltextctrl.syntaxhighlighting: boolean
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { syntaxhighlighting = 1; }Specification: gui.md§3.
guimltextctrl.text: string
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
The text the control shows.
new GuiMLTextCtrl("MyControl") { text = "Hello"; }Specification: gui.md§3.
trimhorizontally
Section titled “trimhorizontally”guimltextctrl.trimhorizontally() -> number
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Removes empty space at the sides of centered text; accepted and ignored.
Control.trimhorizontally();Specification: gui.md§3.
urlbase
Section titled “urlbase”guimltextctrl.urlbase: string
Runs on: client only. Origin: compatibility. Since: M14. Playground: no.
Kept for scripts: the address relative links are based on.
new GuiMLTextCtrl("MyControl") { urlbase = "http://example.org/"; }Specification: gui.md§3.12.
wordwrap
Section titled “wordwrap”guimltextctrl.wordwrap: boolean
Runs on: client only. Origin: compatibility. Since: M8. Playground: no.
Property of GuiMLTextCtrl in the legacy GUI toolkit (gui.md§2, §3).
new GuiMLTextCtrl("MyControl") { wordwrap = 1; }Specification: gui.md§3.
Engine version 0.1.0. Built 2026-11-18.