mailr14123 - in /branches/gui_testing: graphics/wizards/ gui/ gui/user_functions/


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

Header


Content

Posted by edward on August 04, 2011 - 13:34:
Author: bugman
Date: Thu Aug  4 13:34:52 2011
New Revision: 14123

URL: http://svn.gna.org/viewcvs/relax?rev=14123&view=rev
Log:
Implemented the grace.view user function GUI page and menu entry.


Modified:
    branches/gui_testing/graphics/wizards/grace.png
    branches/gui_testing/gui/menu.py
    branches/gui_testing/gui/user_functions/__init__.py
    branches/gui_testing/gui/user_functions/grace.py

Modified: branches/gui_testing/graphics/wizards/grace.png
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/graphics/wizards/grace.png?rev=14123&r1=14122&r2=14123&view=diff
==============================================================================
Binary files - no diff available.

Modified: branches/gui_testing/gui/menu.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/menu.py?rev=14123&r1=14122&r2=14123&view=diff
==============================================================================
--- branches/gui_testing/gui/menu.py (original)
+++ branches/gui_testing/gui/menu.py Thu Aug  4 13:34:52 2011
@@ -173,6 +173,9 @@
                 [wx.NewId(), "&spin", paths.icon_16x16.spin, 
self.gui.user_functions.deselect.spin],
             ]],
             [wx.NewId(), "&gpl",   paths.icon_16x16.gnu_head, 
self.gui.user_functions.gpl.run, []],
+            [wx.NewId(), "gra&ce", paths.icon_16x16.grace, None, [
+                [wx.NewId(), "&view",   paths.icon_16x16.grace, 
self.gui.user_functions.grace.view]
+            ]],
             [wx.NewId(), "&molecule", paths.icon_16x16.molecule, None, [
                 [wx.NewId(), "&copy",   paths.icon_16x16.copy, 
self.gui.user_functions.molecule.copy],
                 [wx.NewId(), "crea&te", paths.icon_16x16.add, 
self.gui.user_functions.molecule.create],

Modified: branches/gui_testing/gui/user_functions/__init__.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/user_functions/__init__.py?rev=14123&r1=14122&r2=14123&view=diff
==============================================================================
--- branches/gui_testing/gui/user_functions/__init__.py (original)
+++ branches/gui_testing/gui/user_functions/__init__.py Thu Aug  4 13:34:52 
2011
@@ -29,6 +29,7 @@
 # GUI module imports.
 from deselect import Deselect
 from gpl import Gpl
+from grace import Grace
 from molecule import Molecule
 from noe import Noe
 from pipe import Pipe
@@ -48,6 +49,7 @@
 __all__ = ['base',
            'deselect',
            'gpl',
+           'grace',
            'molecule',
            'noe',
            'pipe',
@@ -78,6 +80,7 @@
         # The user functions.
         self.deselect = Deselect(self.gui)
         self.gpl = Gpl(self.gui)
+        self.grace = Grace(self.gui)
         self.molecule = Molecule(self.gui)
         self.noe = Noe(self.gui)
         self.pipe = Pipe(self.gui)
@@ -99,6 +102,7 @@
         # Send the commands onwards to the user function classes.
         self.deselect.destroy()
         self.gpl.destroy()
+        self.grace.destroy()
         self.molecule.destroy()
         self.noe.destroy()
         self.pipe.destroy()

Modified: branches/gui_testing/gui/user_functions/grace.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/user_functions/grace.py?rev=14123&r1=14122&r2=14123&view=diff
==============================================================================
--- branches/gui_testing/gui/user_functions/grace.py (original)
+++ branches/gui_testing/gui/user_functions/grace.py Thu Aug  4 13:34:52 2011
@@ -37,19 +37,23 @@
 class Grace(UF_base):
     """The container class for holding all GUI elements."""
 
-    def view(self, event, param=None):
+    def view(self, event, file=None):
         """The grace.view user function.
 
         @param event:   The wx event.
         @type event:    wx event
-        @keyword param: The starting parameter.
-        @type param:    str
+        @keyword file:  The file to start the user function with.
+        @type file:     str
         """
 
         # Create the wizard.
         wizard = Wiz_window(size_x=800, size_y=600, 
title=self.get_title('grace', 'view'))
         page = View_page(wizard, self.gui)
         wizard.add_page(page)
+
+        # Default file name.
+        if file:
+            page.file.SetValue(file)
 
         # Execute the wizard.
         wizard.run()




Related Messages


Powered by MHonArc, Updated Thu Aug 04 13:40:01 2011