add textbox:lineAt and textbox:linePos
This commit is contained in:
@@ -78,14 +78,18 @@ Properties:
|
||||
| caret | int | yes | yes | carriage position. `textbox.caret = -1` will set the position to the end of the text |
|
||||
| editable | bool | yes | yes | text mutability |
|
||||
| multiline | bool | yes | yes | multiline support |
|
||||
| lineNumbers | bool | yes | yes | display line numbers |
|
||||
| textWrap | bool | yes | yes | automatic text wrapping (only with multiline: "true") |
|
||||
| valid | bool | yes | no | is the entered text correct |
|
||||
| textColor | vec4 | yes | yes | text color |
|
||||
|
||||
Methods:
|
||||
|
||||
| Method | Description |
|
||||
| ----------- | ------------------------------------------------ |
|
||||
| paste(text) | inserts the specified text at the caret position |
|
||||
| Method | Description |
|
||||
| ------------------------- | ---------------------------------------------------------------- |
|
||||
| paste(text: str) | inserts the specified text at the caret position |
|
||||
| lineAt(pos: int) -> int | determines the line number by position in the text |
|
||||
| linePos(line: int) -> int | determines the position of the beginning of the line in the text |
|
||||
|
||||
## Slider (trackbar)
|
||||
|
||||
|
||||
@@ -78,14 +78,18 @@ document["worlds-panel"]:clear()
|
||||
| caret | int | да | да | позиция каретки. `textbox.caret = -1` установит позицию в конец текста |
|
||||
| editable | bool | да | да | изменяемость текста |
|
||||
| multiline | bool | да | да | поддержка многострочности |
|
||||
| lineNumbers | bool | да | да | отображение номеров строк |
|
||||
| textWrap | bool | да | да | автоматический перенос текста (только при multiline: "true") |
|
||||
| valid | bool | да | нет | является ли введенный текст корректным |
|
||||
| textColor | vec4 | да | да | цвет текста |
|
||||
|
||||
Методы:
|
||||
|
||||
| Метод | Описание |
|
||||
| ----------- | -------------------------------------------- |
|
||||
| paste(text) | вставляет указанный текст на позицию каретки |
|
||||
| Метод | Описание |
|
||||
| ------------------------- | -------------------------------------------- |
|
||||
| paste(text: str) | вставляет указанный текст на позицию каретки |
|
||||
| lineAt(pos: int) -> int | определяет номер строки по позиции в тексте |
|
||||
| linePos(line: int) -> int | определяет позицию начала строки в тексте |
|
||||
|
||||
## Ползунок (trackbar)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user