
18 Perl/Tk Pocket Reference
Entry Widget Commands
$entry->bbox(index);
Returns a list (x, y, width, height) giving an approximate
bounding box of character given by index.
$entry->delete(first ?, last ?);
Deletes characters from first through character just before
last.
$entry->get;
Returns the
$entry’s string.
$entry->icursor(index);
Displays insertion cursor just before character at index.
$entry->index(index);
Returns the numerical index corresponding to index.
$entry->insert(index, string);
Inserts string just before character at index.
$entry->scan(-option, args);
See Widget Scroll Commands above.
$entry->selectionAdjust(index);
Adjusts nearest end of current selection to be at index and
sets the other end to the anchor point.
$entry->selectionClear;
Clears the selection if currently in the widget.
$entry->selectionFrom(index);
Sets the anchor point to be at index.
$entry->selectionPresent;
Returns 1 if any characters are selected, 0 otherwise.
$entry->selectionRange(start, end);
Selects the characters from start through character just
before end.
$entry->selectionTo(index);
Sets the selection to extend between index and anchor
point.