The little script below gives me this error message:
File "./bug.py", line 11, in ?
for ex in ['a', 'b', 'c']:
TypeError: object doesn't support item assignment
If you use tuplets instead of lists in the loop, it works ok.
Also if you don't give 'f' as the callback function for append_item,
(but still uses lists for the loop) it also works ok.
I get the error with code checked out from cvs with
cvs update -D 2001-10-06, but not with -D 2001-10-05
#!/home/tom/PY22/bin/python2.2
import sys
sys.path.insert(0, "/home/tom/gtk2/lib/python2.2/site-packages")
import gtk
tb = gtk.Toolbar()
def f(*v):
print 'hei'
#for ex in ('a', 'b', 'c'):
for ex in ['a', 'b', 'c']:
tb.append_item("Text", None, None, None, f, None)
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk