
4. The Canvas Widget 9
4. The Canvas Widget
Canvas Options
-closeenough => float
How close the mouse cursor must be to an item before it
is considered to be “inside” the item.
-confine => boolean
Whether it is allowable to set the canvas’s view outside
the scroll region.
-scrollregion => [corners ]
Array reference of four coordinates describing the left,
top, right, and bottom of a rectangular scrolling region.
-xscrollincrement => distance
Specifies the increment for horizontal scrolling in screen
units.
-yscrollincrement => distance
Specifies the increment for vertical scrolling in screen units.
Coordinate examples: 5 (pixel), 2.2i (inch), 4.1c (cm), 3m
(mm), 21p (pts)
Larger y-coordinates refer to points lower on the screen;
larger x-coordinates refer to points farther to the right.
Character positions: charIndex,
end, insert, sel.first,
sel.last, @x,y
-background -insertontime
-borderwidth -insertwidth
-cursor -relief
-height -selectbackground
-highlightbackground -selectborderwidth
-highlightcolor -selectforeground
-highlightthickness -takefocus
-insertbackground -width
-insertborderwidth -xscrollcommand
-insertofftime -yscrollcommand