Package VisionEgg :: Package PyroApps :: Module GridGUI
[frames] | no frames]

Source Code for Module VisionEgg.PyroApps.GridGUI

 1  #!/usr/bin/env python 
 2  # 
 3  # The Vision Egg: GridGUI 
 4  # 
 5  # Copyright (C) 2001-2003 Andrew Straw. 
 6  # Author: Andrew Straw <astraw@users.sourceforge.net> 
 7  # URL: <http://www.visionegg.org/> 
 8  # 
 9  # Distributed under the terms of the GNU Lesser General Public License 
10  # (LGPL). See LICENSE.TXT that came with this file. 
11  # 
12  # $Id$ 
13   
14  import VisionEgg, string 
15  __version__ = VisionEgg.release_name 
16  __cvs__ = string.split('$Revision$')[1] 
17  __date__ = string.join(string.split('$Date$')[1:3], ' ') 
18  __author__ = 'Andrew Straw <astraw@users.sourceforge.net>' 
19   
20  import sys, os 
21  import Tkinter 
22  import VisionEgg.PyroApps.EPhysGUIUtils as client_utils 
23   
24 -def get_control_list():
25 return [("grid_server",GridControlFrame,GridControlFrame.title)]
26
27 -class GridMetaParameters:
28 - def __init__(self):
29 pass
30
31 -class GridControlFrame(client_utils.StimulusControlFrame):
32 title = "Grid for 3D calibration"
33 - def __init__(self, master=None, suppress_go_buttons=0,**kw):
34 client_utils.StimulusControlFrame.__init__(self, 35 master, 36 suppress_go_buttons, 37 GridControlFrame.title, 38 GridMetaParameters, 39 **kw) 40 Tkinter.Label( self.param_frame, 41 text="No variables to control" ).grid()
42
43 - def get_shortname(self):
44 """Used as basename for saving parameter files""" 45 return "grid"
46
47 - def update_tk_vars(self):
48 pass
49
50 - def send_values(self,dummy_arg=None):
51 pass 52 if self.connected: 53 self.meta_controller.set_parameters( self.meta_params )
54
55 - def get_duration_sec(self):
56 return 0.0
57 58 if __name__=='__main__': 59 frame = GridControlFrame() 60 frame.pack(expand=1,fill=Tkinter.BOTH) 61 frame.winfo_toplevel().title("%s"%(os.path.basename(os.path.splitext(sys.argv[0])[0]),)) 62 frame.mainloop() 63