canvas dchars
Deletes characters of a text item, or points of a line or a polygon.
PATHNAME dchars TAGORID FIRST ?LAST?
Description
For a text item, deletes the characters from the index FIRST to the index LAST, both included. For a line or a polygon, deletes the coordinates from FIRST to LAST, where each number is one coordinate. With no LAST, deletes one character or one coordinate.
Returns
An empty string.
Examples
% canvas .dc
> .dc create text 10 10 -text abcdef
> .dc dchars 1 1 2
> .dc itemcget 1 -text
adef
Errors
% canvas .dc2; .dc2 dchars
wrong # args: should be ".dc2 dchars tagOrId first ?last?"
-errorcode NONE
Facts
- Capability
- None.
- Tcl release
- Tcl 9.1 and 8.6.
- Since
- ztk 1.0.0-beta.1