Changeset 83d9120 in sasview


Ignore:
Timestamp:
Jul 10, 2012 11:09:25 AM (12 years ago)
Author:
Jae Cho <jhjcho@…>
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:
4f0376d
Parents:
5da3cc5
Message:

fixed legend toggle on/off

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sansguiframe/src/sans/guiframe/local_perspectives/plotting/Plotter1D.py

    r5da3cc5 r83d9120  
    672672     
    673673 
    674     def on_graphApp_close(self,e): 
    675         # gets values from graph appearance dialog and sends them off 
    676         # to modify the plot 
    677  
    678         self.onGridOnOff(self.graphApp.get_togglegrid()) 
    679  
    680         self.onLegend(self.graphApp.get_togglelegend()) 
    681         self.ChangeLegendLoc(self.graphApp.get_legend_loc()) 
    682  
    683         self.xaxis_label = self.graphApp.get_xlab() 
    684         self.yaxis_label = self.graphApp.get_ylab() 
    685         self.xaxis_unit = self.graphApp.get_xunit() 
    686         self.yaxis_unit = self.graphApp.get_yunit() 
    687  
    688         self.xaxis(self.xaxis_label,self.xaxis_unit, 
    689                    self.graphApp.get_xfont(),self.graphApp.get_xcolor()) 
    690         self.yaxis(self.yaxis_label,self.yaxis_unit, 
    691                    self.graphApp.get_yfont(),self.graphApp.get_ycolor()) 
    692  
    693         self.graphApp.Destroy() 
     674    def on_graphApp_close(self, event): 
     675        """ 
     676        Gets values from graph appearance dialog and sends them off 
     677        to modify the plot 
     678        """ 
     679        graph_app = self.graphApp 
     680        toggle_grid = graph_app.get_togglegrid() 
     681        legend_loc = graph_app.get_legend_loc() 
     682        toggle_legend = graph_app.get_togglelegend() 
     683         
     684        self.onGridOnOff(toggle_grid ) 
     685        self.ChangeLegendLoc(legend_loc) 
     686        self.onLegend(toggle_legend) 
     687 
     688        self.xaxis_label = graph_app.get_xlab() 
     689        self.yaxis_label = graph_app.get_ylab() 
     690        self.xaxis_unit = graph_app.get_xunit() 
     691        self.yaxis_unit = graph_app.get_yunit() 
     692 
     693        self.xaxis(self.xaxis_label, self.xaxis_unit,  
     694                   graph_app.get_xfont(), graph_app.get_xcolor()) 
     695        self.yaxis(self.yaxis_label, self.yaxis_unit,  
     696                   graph_app.get_yfont(), graph_app.get_ycolor()) 
     697 
     698        graph_app.Destroy() 
Note: See TracChangeset for help on using the changeset viewer.