button .b
winfo class .b
==> Button
Regards,
Arjen
% label .w
% winfo class .w
=> Label
R'
Depending on what it is he's trying to do, he might be
better off using virtual events and class bindings, e.g.,:
bind Button <<DoSomething>> { ... code for button widgets ... }
bind Label <<DoSomething>> { ... code for label widgets ... }
...
event generate .t.p1.s2 <<DoSomething>>
Without knowing the details of the problem in question it's
hard to say whether this approach is appropriate or not;
but personally I've always found this technique to be far
superior to switching on [winfo class $w].
--Joe English
Nice one.
R'