how to bind to event _without_ modifier



Hi all,

is there a way to specifically bind to an event without modifiers, e.g.

bind bindtag <None-ButtonPress-1> code

which would only fire if button 1 was pressed without any modifiers?

Or more general, is it possible to limit bindings to exactly the specified modifiers?


BTW. why is a more recent binding used with higher priority in ambigous cases? For example if You do


bind . <Shift-ButtonPress-1> {echo "Shift"}
bind . <Control-ButtonPress-1> {echo "Control}

now hold produce Control-Shift-ButtonPress-1, and notice the output. It is Control.

When You reverse the above commands, the output is Shift.


Regards, Robert S. .


Quantcast