****
| A text widget that corresponds to a TK text widget The widget must first be created, either using the default create routine, or the full creation routine that supplies a parent widget, text configuration options and packing information
_ Eg: t ::= #TK_TEXT(#TK_ROOT_WINDOW,"mytext",#TK_TEXT_CFG,#TK_PACK);
_ Once created, text may be inserted into the widget at locations that are specified using TINDEX es. A TINDEX indicates a location in the text widget in a number of ways - see the interface to TINDEX.
_ Eg. t.insert_at(TINDEX::at(1,0,"text");
_ Ranges of text may also be tagged using a TEXT_TAG, either at insertion or later on by specifying positions
_ Callbacks, basically bound routines, may then be associated with a particular text tag
_ mytag ::= #TK_TEXT_TAG("mytag"); t.bind(mytag,EVENT_INCLUDE::enter,bind(myput(_)));
_ The callback routine myput is of the form myput(arg: TEXT_CB) is
____--_do_something_with_arg
end; It is best to use TK_TEXT widgets by first including GUI_UTIL which makes many commonly used functions conveniently accessible.
|