Groups
Sign in
Groups
comp.lang.tcl
Conversations
About
Send feedback
Help
info
Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss
Learn more
What use is %E in bindings?
31 views
Skip to first unread message
Dave
unread,
Mar 15, 2017, 2:30:30 PM
3/15/17
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
While playing around with bind/event, I noticed the following:
package require Tk
label .test -text "Click me"
pack .test
bind .test <Button-1> "event generate %W <Button-2>"
bind .test <Button-2> "puts %%E=%E"
Clicking on the label with either button 1 or 2 results in "%E=0"
Why?
My reading of the docs suggested that %E would be 0 when I actually
clicked with button 2 but would be 1 when caused by the "event generate".
If the answer is that I did not use "-sendevent 1" on my "event
generate", then what use is %E if one can arbitrarily set it?
--
computerjock AT mail DOT com
0 new messages