Tkinter items question
Weil
weil at sireconnect.de
Thu Apr 20 11:01:29 EDT 2000
Fredrik Lundh <effbot at telia.com> schrieb in im Newsbeitrag:
Ix%K4.462$wYl.187476480 at newsb.telia.net...
[snip]
> okay, how about storing a serial number as a tag. when
> you create a new object, do something like:
>
> self.serial = self.serial + 1
> tag = "item%d" % self.serial
> self.create_item(..., tags=tag)
>
> and
>
> tag = "item%d" % self.serial
> self.delete(self.serial)
Shouldn't this read: self.delete(tag) ? Or am I getting something wrong?
> serial.serial = serial.serial - 1
>
> you'd probably consume less memory by storing a list of
> int(handle)'s, but that's another story.
That's right, I think.
> </F>
Thanks a lot for your help.
At least now I know it wasn't my fault I didn't find any
'last'-tag, automatically handled by Tk as for example 'current'.
More information about the Python-list
mailing list