I want to display a list of icons in horizontal format in wxpython. I'm using wxglade
and I can't find how to set list's orientation. Each item has an icon and below that it has a caption. Is this kind of design possible?
Asked
Active
Viewed 196 times
0

prongs
- 9,422
- 21
- 67
- 105
-
Ive never seen anyone who wanted to do this.... I dont think you need a list control though... – Joran Beasley Sep 03 '12 at 19:12
2 Answers
0
something like
class MyList(wx.ScrollPanel):
def __init__(self,the_list,parent):
wx.ScrollPanel.__init__(self,parent,-1)
self.SetMinSize((parent.GetSize()[0],-1))
sz = wx.BoxSizer(wx.HORIZONTAL)
for Item in the_list:
sz.Add(Item)
self.SetSizer(sz)
self.Layout()
where each item in the_list is a wx.Panel that includes your icon and text...
something like this at least... its untested... and no idea how you would do it within wxGlade

Joran Beasley
- 110,522
- 12
- 160
- 179
0
The ListCtrl doesn't support that in report mode. I suppose you might be able to do it with one of the other style flags though. However Joran has the right idea. However, I would create a series of wx.Image or wx.StaticBitmap widgets and add them to a horizontal BoxSizer instead of what he did.

Mike Driscoll
- 32,629
- 8
- 45
- 88