mailr12918 - /1.3/gui/analyses/results.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on June 09, 2011 - 13:06:
Author: bugman
Date: Thu Jun  9 13:06:06 2011
New Revision: 12918

URL: http://svn.gna.org/viewcvs/relax?rev=12918&view=rev
Log:
Regularised the text in the results tab.


Modified:
    1.3/gui/analyses/results.py

Modified: 1.3/gui/analyses/results.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/gui/analyses/results.py?rev=12918&r1=12917&r2=12918&view=diff
==============================================================================
--- 1.3/gui/analyses/results.py (original)
+++ 1.3/gui/analyses/results.py Thu Jun  9 13:06:06 2011
@@ -1,6 +1,7 @@
 
###############################################################################
 #                                                                            
 #
 # Copyright (C) 2010 Michael Bieri                                           
 #
+# Copyright (C) 2011 Edward d'Auvergne                                       
 #
 #                                                                            
 #
 # This file is part of the program relax.                                    
 #
 #                                                                            
 #
@@ -32,11 +33,12 @@
 from data import Relax_data_store; ds = Relax_data_store()
 
 # relaxGUI module imports.
+from gui.analyses.base import Base_frame
 from gui.paths import IMAGE_PATH
 
 
 
-class Results_summary:
+class Results_summary(Base_frame):
     """The base class for the noe frames."""
 
     def __init__(self, gui, notebook):
@@ -71,9 +73,8 @@
         # Use a vertical packing of elements.
         sizer = wx.BoxSizer(wx.VERTICAL)
 
-        # Add Title.
-        title = wx.StaticText(self.parent, -1, "\nModel-Free Results:", 
style=wx.ALIGN_RIGHT)
-        sizer.Add(title, 0, 
wx.LEFT|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
+        # Add a label.
+        self.add_subsubtitle(sizer, "Model-free results")
 
         # Selection to open.
         sizer1 = wx.BoxSizer(wx.HORIZONTAL)
@@ -103,9 +104,8 @@
         # Use a vertical packing of elements.
         sizer = wx.BoxSizer(wx.VERTICAL)
 
-        # Add Title.
-        title = wx.StaticText(self.parent, -1, "steady-state NOE Results:", 
style=wx.ALIGN_RIGHT)
-        sizer.Add(title, 0, 
wx.LEFT|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
+        # Add a label.
+        self.add_subsubtitle(sizer, "Steady-state NOE results")
 
         # Selection to open.
         sizer1 = wx.BoxSizer(wx.HORIZONTAL)
@@ -135,9 +135,8 @@
         # Use a vertical packing of elements.
         sizer = wx.BoxSizer(wx.VERTICAL)
 
-        # Add Title.
-        title = wx.StaticText(self.parent, -1, "\nRelaxation Results:", 
style=wx.ALIGN_RIGHT)
-        sizer.Add(title, 0, 
wx.LEFT|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
+        # Add a label.
+        self.add_subsubtitle(sizer, "Relaxation results")
 
         # Selection to open.
         sizer1 = wx.BoxSizer(wx.HORIZONTAL)
@@ -169,7 +168,7 @@
         box = wx.BoxSizer(wx.VERTICAL)
 
         # Add the title.
-        self.add_title(box)
+        self.add_title(box, "Results")
 
         # Add Noe results.
         self.add_noe_results(box)
@@ -189,16 +188,3 @@
         self.results_noe = ds.relax_gui.results_noe
         self.results_rx = ds.relax_gui.results_rx
         self.results_modelfree = ds.relax_gui.results_model_free
-
-
-    def add_title(self, box):
-        """Create and add the frame title to the given box."""
-
-        # The title.
-        label = wx.StaticText(self.parent, -1, "Results:")
-
-        # The font properties.
-        label.SetFont(wx.Font(16, wx.DEFAULT, wx.NORMAL, wx.NORMAL, 0, 
"Sans"))
-
-        # Pack the title.
-        box.Add(label, 0, wx.BOTTOM|wx.ADJUST_MINSIZE, 18)




Related Messages


Powered by MHonArc, Updated Thu Jun 09 13:20:02 2011