5

In PyGtk I always used this to create a ListStore with an Image (using it with an IconView for displaying files):

store = gtk.ListStore(str, gtk.gdk.Pixbuf, bool)

But I can't figure out how to do this with Python 3 and PyGObject.

vitaut
  • 49,672
  • 25
  • 199
  • 336
jgillich
  • 71,459
  • 6
  • 57
  • 85

1 Answers1

8

Here's how:

from gi.repository import Gtk, GdkPixbuf
store = Gtk.ListStore(str, GdkPixbuf.Pixbuf, bool)
ptomato
  • 56,175
  • 13
  • 112
  • 165