Ignore:
Timestamp:
Sep 4, 2011 10:15:45 PM (13 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:
c994f8f
Parents:
2259920
Message:

enabled add text

File:
1 edited

Legend:

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

    r2259920 r902f373  
    279279        ax = event.inaxes 
    280280        if ax != None: 
    281             # data coordinate position 
    282             pos_x = "%8.3g"% event.xdata 
    283             pos_y = "%8.3g"% event.ydata 
    284             position = "x: %s    y: %s" % (pos_x, pos_y) 
    285             wx.PostEvent(self.parent, StatusEvent(status=position)) 
     281            try: 
     282                pos_x = float(event.xdata)# / size_x 
     283                pos_y = float(event.ydata)# / size_y 
     284                pos_x = "%8.3g"% pos_x 
     285                pos_y = "%8.3g"% pos_y 
     286                self.position = str(pos_x), str(pos_y) 
     287                wx.PostEvent(self.parent, StatusEvent(status=self.position)) 
     288            except: 
     289                self.position = None   
    286290        # unfocus all 
    287291        self.parent.set_plot_unfocus()   
Note: See TracChangeset for help on using the changeset viewer.