1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88
|
.. _hoc_tedit:
TextEditor
----------
.. hoc:class:: TextEditor
Syntax:
``e = new TextEditor()``
``e = new TextEditor(string)``
``e = new TextEditor(string, rows, columns)``
Description:
For editing or displaying multiline text. Default is 5 rows, 30 columns.
.. warning::
At this time no scroll bars or even much functionality. Mouse editing
and emacs style works.
----
.. hoc:method:: TextEditor.text
Syntax:
``string = e.text()``
``string = e.text(string)``
Description:
Returns the text of the TextEditor in a strdef. If arg exists, replaces
the text by the string and returns the new text (string).
----
.. hoc:method:: TextEditor.readonly
Syntax:
``boolean = e.readonly()``
``boolean = e.readonly(boolean)``
Description:
Returns 1 if the TextEditor in read only mode.
Returns 0 if text entry by the user is allowed.
Change the mode with the argument form using 0 or 1.
----
.. hoc:method:: TextEditor.map
Syntax:
``e.map()``
``e.map(title)``
``e.map(title, left, bottom, width, height)``
Description:
Map the text editor onto the screen at indicated coordinates with
indicated title bar
|