canvas itemconfigure
Gives or sets the options of the items.
PATHNAME itemconfigure TAGORID ?OPTION? ?VALUE? ?OPTION VALUE ...?
Description
With no OPTION, gives a list with an entry for each option of the first item of TAGORID. With one OPTION, gives its entry: the option, two empty strings, the default, and the value. With pairs of options and values, sets the options of each item of TAGORID. The create command lists the options of each type.
Returns
An entry, a list of entries, or an empty string.
Examples
% canvas .ifc
> .ifc create rectangle 0 0 10 10 -tags box
> .ifc create oval 0 0 10 10 -tags box
> .ifc itemconfigure box -fill blue
> .ifc itemcget 2 -fill
blue
% canvas .ifc2
> .ifc2 create rectangle 0 0 10 10
> llength [.ifc2 itemconfigure 1]
23
Errors
% canvas .ifc3; .ifc3 create rectangle 0 0 1 1; .ifc3 itemconfigure 1 -foo 1
unknown option "-foo"
-errorcode NONE
Facts
- Capability
- None.
- Tcl release
- Tcl 9.1 and 8.6.
- Since
- ztk 1.0.0-beta.1