mailr12931 - /1.3/gui/components/spectrum.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 - 15:59:
Author: bugman
Date: Thu Jun  9 15:59:58 2011
New Revision: 12931

URL: http://svn.gna.org/viewcvs/relax?rev=12931&view=rev
Log:
The Rx peak list grid GUI element now also uses the add_text_sel_element() 
base method.


Modified:
    1.3/gui/components/spectrum.py

Modified: 1.3/gui/components/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/gui/components/spectrum.py?rev=12931&r1=12930&r2=12931&view=diff
==============================================================================
--- 1.3/gui/components/spectrum.py (original)
+++ 1.3/gui/components/spectrum.py Thu Jun  9 15:59:58 2011
@@ -245,7 +245,7 @@
         self.subparent.add_subtitle(box, "Data points")
 
         # Add the cycle delay time element.
-        self.add_cycle_delay(box)
+        self.delay_time = self.subparent.add_text_sel_element(box, 
self.parent, text="Single delay cycle time [s]", width_text=230, 
width_control=350)
 
         # A sizer for the buttons and grid.
         sizer = wx.BoxSizer(wx.HORIZONTAL)
@@ -305,35 +305,6 @@
 
         # Pack buttons
         sizer.Add(button_sizer, 0, 0, 0)
-
-
-    def add_cycle_delay(self, box):
-        """Create and add the cycle delay time GUI element to the given box.
-
-        @param box:     The box element to pack the cycle delay time GUI 
element into.
-        @type box:      wx.BoxSizer instance
-        """
-
-        # Horizontal packing for this element.
-        sizer = wx.BoxSizer(wx.HORIZONTAL)
-
-        # The label.
-        label = wx.StaticText(self.parent, -1, "Single delay cycle time [s]")
-        label.SetMinSize((230, 17))
-        label.SetFont(self.gui.font_normal)
-        sizer.Add(label, 0, 
wx.LEFT|wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
-
-        # The text input field.
-        self.delay_time = wx.TextCtrl(self.parent, -1)
-        self.delay_time.SetMinSize((350, 27))
-        sizer.Add(self.delay_time, 0, 
wx.ALIGN_CENTER_VERTICAL|wx.ADJUST_MINSIZE, 0)
-
-        # Bind the change of contents.
-        self.delay_time.Bind(wx.EVT_KEY_DOWN, self.change_delay_down)
-        self.delay_time.Bind(wx.EVT_KEY_UP, self.change_delay_up)
-
-        # Add the element to the box.
-        box.Add(sizer, 0, wx.EXPAND|wx.SHAPED, 0)
 
 
     def add_grid(self, sizer):




Related Messages


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