[GRASS-SVN] r30771 - grass/trunk/gui/wxpython

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Mar 27 17:47:00 EDT 2008


Author: martinl
Date: 2008-03-27 17:47:00 -0400 (Thu, 27 Mar 2008)
New Revision: 30771

Modified:
   grass/trunk/gui/wxpython/gis_set.py
Log:
wxGUI (welcome screen): cosmetics in style - back to listmix.ListCtrlAutoWidthMixin (GListBox)

Modified: grass/trunk/gui/wxpython/gis_set.py
===================================================================
--- grass/trunk/gui/wxpython/gis_set.py	2008-03-27 21:31:14 UTC (rev 30770)
+++ grass/trunk/gui/wxpython/gis_set.py	2008-03-27 21:47:00 UTC (rev 30771)
@@ -728,8 +728,7 @@
         #        sizer.SetSizeHints(self)
         self.Layout()
 
-# class GListBox(wx.ListCtrl, listmix.ListCtrlAutoWidthMixin):
-class GListBox(wx.ListCtrl):
+class GListBox(wx.ListCtrl, listmix.ListCtrlAutoWidthMixin):
     """Use wx.ListCtrl instead of wx.ListBox, different style for
     non-selectable items (e.g. mapsets with denied permission)"""
     def __init__(self, parent, id, size,
@@ -737,12 +736,10 @@
 
         wx.ListCtrl.__init__(self, parent, id, size=size,
                              style=wx.LC_REPORT | wx.LC_NO_HEADER | wx.LC_SINGLE_SEL |
-                             wx.BORDER_RAISED)
+                             wx.BORDER_SUNKEN)
 
-        self.width = size[0] - 20 # FIXME (width of vertical scrollbar)
+        listmix.ListCtrlAutoWidthMixin.__init__(self)
         
-        # listmix.ListCtrlAutoWidthMixin.__init__(self)
-        
         self.InsertColumn(0, '')
 
         self.selected = wx.NOT_FOUND
@@ -764,9 +761,6 @@
                 self.SetItemTextColour(idx, wx.Colour(150, 150, 150))
             idx += 1
 
-        for col in range(self.GetColumnCount()):
-            self.SetColumnWidth(col, self.width)
-            
     def Clear(self):
         self.DeleteAllItems()
 



More information about the grass-commit mailing list