- Timestamp:
- Sep 15, 2016 8:33:57 AM (8 years ago)
- Branches:
- 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
- Children:
- 1729738
- Parents:
- f0858b6
- git-author:
- Lewis O'Driscoll <lewis.o'driscoll@…> (08/12/16 04:31:53)
- git-committer:
- Piotr Rozyczko <rozyczko@…> (09/15/16 08:33:57)
- Location:
- src/sas/sasgui
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/guiframe/local_perspectives/plotting/SimplePlot.py
rd85c194 rb742b2b9 188 188 """ 189 189 def __init__(self, parent, id, title, scale='log_{10}', 190 size=wx.Size(550, 470) ):190 size=wx.Size(550, 470), show_menu_icons=True): 191 191 """ 192 192 comment … … 202 202 self._default_save_location = None 203 203 self.scale = scale 204 self._show_menu_icons = show_menu_icons 204 205 self.plotpanel = SimplePlotPanel(self, -1) 205 206 self._build_menubar() … … 213 214 quit_bmp = wx.ArtProvider.GetBitmap(wx.ART_QUIT, wx.ART_TOOLBAR, tsize) 214 215 print_bmp = wx.ArtProvider.GetBitmap(wx.ART_PRINT, wx.ART_TOOLBAR, tsize) 215 preview_bmp = wx.ArtProvider.GetBitmap(wx.ART_REPORT_VIEW, wx.ART_TOOLBAR, tsize)216 216 copy_bmp = wx.ArtProvider.GetBitmap(wx.ART_COPY, wx.ART_TOOLBAR, tsize) 217 217 menu_bar = wx.MenuBar() … … 219 219 menu = wx.Menu() 220 220 id = wx.NewId() 221 item = wx.MenuItem(menu, id, "&Save Image") 222 item.SetBitmap(save_bmp) 223 menu.AppendItem(item) 221 save_item = wx.MenuItem(menu, id, "&Save Image") 222 menu.AppendItem(save_item) 224 223 wx.EVT_MENU(self, id, self.on_save_file) 225 224 226 225 id = wx.NewId() 227 item = wx.MenuItem(menu, id, "&Print Image") 228 item.SetBitmap(print_bmp) 229 menu.AppendItem(item) 226 print_item = wx.MenuItem(menu, id, "&Print Image") 227 menu.AppendItem(print_item) 230 228 wx.EVT_MENU(self, id, self.on_print_image) 231 229 232 230 menu.AppendSeparator() 233 231 id = wx.NewId() 234 item = wx.MenuItem(menu, id, "&Quit") 235 item.SetBitmap(quit_bmp) 236 menu.AppendItem(item) 232 quit_item = wx.MenuItem(menu, id, "&Quit") 233 menu.AppendItem(quit_item) 237 234 238 235 menu_bar.Append(menu, "&File") … … 241 238 menu_edit = wx.Menu() 242 239 id = wx.NewId() 243 item = wx.MenuItem(menu_edit, id, "&Copy") 244 item.SetBitmap(copy_bmp) 245 menu_edit.AppendItem(item) 240 copy_item = wx.MenuItem(menu_edit, id, "&Copy") 241 menu_edit.AppendItem(copy_item) 246 242 wx.EVT_MENU(self, id, self.on_copy_image) 243 244 if self._show_menu_icons: 245 save_item.SetBitmap(save_bmp) 246 print_item.SetBitmap(print_bmp) 247 quit_item.SetBitmap(quit_bmp) 248 copy_item.SetBitmap(copy_bmp) 247 249 248 250 menu_bar.Append(menu_edit, "&Edit") … … 324 326 except: 325 327 self.Destroy() 326 -
src/sas/sasgui/perspectives/calculator/image_viewer.py
rd0248bd rb742b2b9 73 73 parent.put_icon(plot_frame) 74 74 except: 75 print "parent", parent76 75 err_msg += "Failed to load '%s'.\n" % basename 77 76 if err_msg: … … 109 108 """ 110 109 # Initialize the Frame object 111 PlotFrame.__init__(self, parent, id, title, scale, size) 110 PlotFrame.__init__(self, parent, id, title, scale, size, 111 show_menu_icons=False) 112 112 self.parent = parent 113 113 self.data = image … … 437 437 ImageView(None).load() 438 438 app.MainLoop() 439
Note: See TracChangeset
for help on using the changeset viewer.