[GRASS-SVN] r53366 - grass/trunk/gui/wxpython/gui_core
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Oct 11 13:21:38 PDT 2012
Author: martinl
Date: 2012-10-11 13:21:37 -0700 (Thu, 11 Oct 2012)
New Revision: 53366
Modified:
grass/trunk/gui/wxpython/gui_core/ghelp.py
Log:
wxGUI: use menustyle also for menutree
Modified: grass/trunk/gui/wxpython/gui_core/ghelp.py
===================================================================
--- grass/trunk/gui/wxpython/gui_core/ghelp.py 2012-10-11 14:36:00 UTC (rev 53365)
+++ grass/trunk/gui/wxpython/gui_core/ghelp.py 2012-10-11 20:21:37 UTC (rev 53366)
@@ -43,6 +43,7 @@
from core.gcmd import GError, DecodeString
from gui_core.widgets import FormListbook, StaticWrapText, ItemTree, ScrolledPanel
from core.debug import Debug
+from core.settings import UserSettings
class SearchModuleWindow(wx.Panel):
"""!Search module window (used in MenuTreeWindow)"""
@@ -340,6 +341,8 @@
super(MenuTree, self).__init__(parent, **kwargs)
+ self.menustyle = UserSettings.Get(group = 'appearance', key = 'menustyle', subkey = 'selection')
+
def Load(self, data = None):
"""!Load menu data tree
@@ -368,8 +371,15 @@
self.__AppendItems(itemSub, eachItem[1])
else:
if eachItem[0]:
+ label = eachItem[0]
+ if eachItem[3]:
+ if self.menustyle == 1:
+ label += ' [' + eachItem[3] + ']'
+ elif self.menustyle == 2:
+ label = '[' + eachItem[3] + ']'
+
itemNew = self.AppendItem(parentId = item,
- text = eachItem[0])
+ text = label)
data = { 'item' : eachItem[0],
'description' : eachItem[1],
More information about the grass-commit
mailing list