- Timestamp:
- Feb 10, 2009 12:04:46 PM (16 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 16bf519
- Parents:
- 8b30e62
- Location:
- sansview
- Files:
-
- 2 added
- 2 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
sansview/perspectives/fitting/fitpage1D.py
r8aac6e1 r2268d10 92 92 i+=1 93 93 94 # Minimum value of data 95 self.data_min = wx.StaticText(self, -1,str(format_number(numpy.min(data.x)))) 96 # Maximum value of data 97 self.data_max = wx.StaticText(self, -1,str(format_number(numpy.max(data.x)))) 94 98 95 #Filing the sizer containing data related fields 99 96 ix = 0 … … 110 107 #set maximum range for x in linear scale 111 108 if not hasattr(self.data,"data"): #Display only for 1D data fit 109 # Minimum value of data 110 self.data_min = wx.StaticText(self, -1,str(format_number(numpy.min(data.x)))) 111 # Maximum value of data 112 self.data_max = wx.StaticText(self, -1,str(format_number(numpy.max(data.x)))) 112 113 self.text4_3 = wx.StaticText(self, -1, 'Maximum Data Range(Linear)', style=wx.ALIGN_LEFT) 113 114 self.sizer2.Add(self.text4_3,(iy,ix),(1,1),\ -
sansview/perspectives/fitting/fitting.py
r9dd69ec r2268d10 92 92 TODO: replace the text with a nice image 93 93 """ 94 from helpDialog import HelpWindow 95 dialog = HelpWindow(None, -1, 'HelpWindow') 96 if dialog.ShowModal() == wx.ID_OK: 97 pass 98 dialog.Destroy() 94 #from helpDialog import HelpWindow 95 #dialog = HelpWindow(None, -1, 'HelpWindow') 96 #if dialog.ShowModal() == wx.ID_OK: 97 # pass 98 #dialog.Destroy() 99 from helpPanel import HelpWindow 100 frame = HelpWindow(None, -1, 'HelpWindow') 101 frame.Show(True) 102 103 99 104 100 105 -
sansview/perspectives/fitting/helpPanel.py
rb92884a r2268d10 60 60 self.Centre() 61 61 62 class HelpWindow(wx. Dialog):62 class HelpWindow(wx.Frame): 63 63 def __init__(self, parent, id, title): 64 wx. Dialog.__init__(self, parent, id, title, size=(600, 450))64 wx.Frame.__init__(self, parent, id, title, size=(600, 450)) 65 65 66 66 vbox1 = wx.BoxSizer(wx.HORIZONTAL) … … 76 76 header.SetForegroundColour('WHITE') 77 77 hbox = wx.BoxSizer(wx.HORIZONTAL) 78 st = wx.StaticText(header, -1, ' ', (5, 5))78 st = wx.StaticText(header, -1, 'Contents', (5, 5)) 79 79 font = st.GetFont() 80 80 font.SetPointSize(10) … … 90 90 headerl.SetForegroundColour('WHITE') 91 91 hboxl = wx.BoxSizer(wx.HORIZONTAL) 92 lst = wx.StaticText(headerl, -1, ' Contents', (5, 5))92 lst = wx.StaticText(headerl, -1, 'Menu', (5, 5)) 93 93 fontl = lst.GetFont() 94 94 fontl.SetPointSize(10) … … 99 99 self.lhelp = html.HtmlWindow(lpanel, -1, style=wx.NO_BORDER) 100 100 self.rhelp = html.HtmlWindow(rpanel, -1, style=wx.NO_BORDER) 101 101 page1="""<html> 102 <body> 103 <p>Select topic on Menu</p> 104 </body> 105 </html>""" 102 106 page="""<html> 103 107 <body> … … 109 113 <li><a href ="doc/single_fit_help.html" target ="showframe">Single Fit</a><br></li> 110 114 <li><a href ="doc/model_use_help.html" target ="showframe">Visualize Model</a><br></li> 115 <li><a href ="doc/averaging_help.html" target ="showframe">Data Averaging</a><br></li> 111 116 </ul> 112 117 </body> 113 118 </html>""" 114 119 self.rhelp.SetPage(page1) 115 120 self.lhelp.SetPage(page) 116 121 self.lhelp.Bind(wx.html.EVT_HTML_LINK_CLICKED,self.OnLinkClicked ) … … 132 137 self.rhelp.LoadPage(link) 133 138 139 class ViewApp(wx.App): 140 def OnInit(self): 141 frame = HelpWindow(None, -1, 'HelpWindow') 142 frame.Show(True) 143 self.SetTopWindow(frame) 144 145 return True 146 134 147 135 class MyApp(wx.App): 136 def OnInit(self): 137 138 dialog = HelpWindow(None, -1, 'HelpWindow') 139 if dialog.ShowModal() == wx.ID_OK: 140 pass 141 dialog.Destroy() 142 143 return 1 144 145 146 # end of class MyApp 147 148 if __name__ == "__main__": 149 app = MyApp(0) 150 app.MainLoop() 151 152 148 if __name__ == "__main__": 149 app = ViewApp(0) 150 app.MainLoop()
Note: See TracChangeset
for help on using the changeset viewer.