浏览代码

wxGUI: fix sash position (tested on Linux/Windows)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@40263 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 15 年之前
父节点
当前提交
0af94832c0
共有 3 个文件被更改,包括 7 次插入3 次删除
  1. 1 2
      gui/wxpython/gui_modules/goutput.py
  2. 3 0
      gui/wxpython/gui_modules/menuform.py
  3. 3 1
      gui/wxpython/wxgui.py

+ 1 - 2
gui/wxpython/gui_modules/goutput.py

@@ -283,10 +283,9 @@ class GMConsole(wx.SplitterWindow):
         # split window
         if self.parent.GetName() == 'LayerManager':
             self.SplitHorizontally(self.panelOutput, self.panelPrompt, -75)
-            self.SetMinimumPaneSize(100)
         else:
             self.SplitHorizontally(self.panelOutput, self.panelPrompt, -10)
-            self.SetMinimumPaneSize(45)
+        self.SetMinimumPaneSize(35)
         self.Fit()
         
         # layout

+ 3 - 0
gui/wxpython/gui_modules/menuform.py

@@ -851,6 +851,9 @@ class mainFrame(wx.Frame):
         if width > 640: width = 640
         if height > 480: height = 480
         self.SetSize((width,height))
+        
+        # fix goutput's pane size
+        self.goutput.SetSashPosition(int(self.GetSize()[1] * .75))
 
     def updateValuesHook(self):
         """!Update status bar data"""

+ 3 - 1
gui/wxpython/wxgui.py

@@ -179,9 +179,11 @@ class GMFrame(wx.Frame):
         # -> OnSize() -> UpdateMap()
         if self.curr_page and not self.curr_page.maptree.mapdisplay.IsShown():
             self.curr_page.maptree.mapdisplay.Show()
-
+        
         # redirect stderr to log area    
         self.goutput.Redirect()
+        # fix goutput's pane size
+        self.goutput.SetSashPosition(int(self.GetSize()[1] * .45))
         
         # start with layer manager on top
         self.curr_page.maptree.mapdisplay.Raise()