The attached small program causes this error:

Traceback (innermost last):
  File "/home/epg/src/test.py", line 12, in ?
    list.append_items((item))
  File "/usr/lib/python1.5/site-packages/gtk.py", line 1511, in append_items
    items = map(lambda i: i._o, items)
  File "/usr/lib/python1.5/site-packages/gtk.py", line 75, in __getattr__
    raise AttributeError, attr
AttributeError: __len__

It looks like GtkObject.__getattr__ always raises AttributeError
no matter what. Is there any way around this? I need a list i can
pack widgets into, so the CList won't work.

Thanks.

-- 
Eric Gillespie, Jr. <*> [EMAIL PROTECTED]
Software Developer
Progeny Linux Systems - http://progenylinux.com

#!/usr/bin/python

from gtk import *

window = GtkWindow(WINDOW_TOPLEVEL)
list = GtkList()
list.show()
window.add(list)

item = GtkListItem()
item.show()
list.append_items((item))

label = GtkLabel("test")
label.show()
item.add(label)

mainloop()

PGP signature

Reply via email to