On Feb 15, 2007, at 08:47, Dídac Busquets wrote:
> Hello,
>
> I'm trying to create a set of buttons to which I assign a callback
> that
> is the same for all of them, except for the parameter (to do this I
> use
> a lambda function). I want to get the buttons numbered from 0 to 4, so
> that w
Dídac, aquest és un problem molt interessant.
Your code doesn't work because you didn't pass in a reference to i in your
lambda. The correct code appears below. BTW, if you set up your application
with classes and methods, you will need to pass in a reference to self in
the same way: self=self.
Hello,
I'm trying to create a set of buttons to which I assign a callback that
is the same for all of them, except for the parameter (to do this I use
a lambda function). I want to get the buttons numbered from 0 to 4, so
that when I click on any of them, it prints out its number (that is,
but
Hi,
I am trying to implement lasso selection technique to select a set of
rectangles on a canvas. When the usr leaves a rectangle while B1 is down the
current rectangle is either selected or reselected. So I need to use two events:
bound to the canvas and bound to rectangles. But only
B1-m