diff options
Diffstat (limited to 'sandbox/testpoly.tcl')
-rw-r--r-- | sandbox/testpoly.tcl | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/sandbox/testpoly.tcl b/sandbox/testpoly.tcl index b5637c3..2363a82 100644 --- a/sandbox/testpoly.tcl +++ b/sandbox/testpoly.tcl @@ -130,11 +130,7 @@ proc toggle_closed { } { global closed set closed [expr ! $closed] foreach curve [.r find withtag "poly"] { - if {$closed} { - .r coords $curve add [.r coords $curve 0] - } { - .r coords $curve remove -1 - } + .r itemconfigure $curve -closed $closed } } @@ -144,7 +140,8 @@ focus .r bind .r "<a>" toggle_arrows bind .r "<c>" toggle_closed bind .r "<m>" toggle_marks -#bind .r "<s>" toggle_smooth +bind .r "<Shift-1>" {set it [.r find closest %x %y]; puts "$it [.r verticeat $it %x %y]"} +bind .r "<Shift-ButtonRelease-1>" {break} source "controls.tcl" |