Changeset 4096
- Timestamp:
- Aug 16, 2019 12:43:05 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIplot.py
r4094 r4096 732 732 class GSASIItoolbar(Toolbar): 733 733 'Override the matplotlib toolbar so we can add more icons' 734 arrows = {}735 736 734 def __init__(self,plotCanvas,publish=None): 737 735 '''Adds additional icons to toolbar''' 736 self.arrows = {} 738 737 # try to remove a button from the bar 739 738 POS_CONFIG_SPLTS_BTN = 6 # position of button to remove … … 2014 2013 2015 2014 def OnMotion(event): 2016 2015 'Update the status line with infor based on the mouse position' 2017 2016 SetCursor(Page) 2018 2017 if event.button and G2frame.Contour and G2frame.TforYaxis: … … 2392 2391 G2frame.cid = None 2393 2392 if event.xdata is None or event.ydata is None: # ignore drag if cursor is outside of plot 2393 if GSASIIpath.GetConfigValue('debug'): print('Ignoring drag, invalid pos:',event.xdata,event.ydata) 2394 2394 wx.CallAfter(PlotPatterns,G2frame,plotType=plottype,extraKeys=extraKeys) 2395 2395 return 2396 2396 if not G2frame.PickId: 2397 if GSASIIpath.GetConfigValue('debug'): print('Ignoring drag, G2frame.PickId is not set') 2397 2398 return 2398 2399 … … 2440 2441 2441 2442 if G2frame.itemPicked is None: 2442 # after any mouse release event (could be a zoom), redraw magnification lines 2443 # after any mouse release event (could be a zoom) where nothing is selected, 2444 # redraw magnification lines 2443 2445 if magLineList: wx.CallAfter(PlotPatterns,G2frame,plotType=plottype,extraKeys=extraKeys) 2444 2446 return … … 2520 2522 data[1][0] = min(max(data[0][0],data[1][0]),data[1][1]) 2521 2523 data[1][1] = max(min(data[0][1],data[1][1]),data[1][0]) 2522 elif (G2frame.GPXtree.GetItemText(PickId) == 'Reflection Lists' or \2524 elif (G2frame.GPXtree.GetItemText(PickId) == 'Reflection Lists' or 2523 2525 'PWDR' in G2frame.GPXtree.GetItemText(PickId)) and xpos: 2524 2526 Id = G2gd.GetGPXtreeItemId(G2frame,PatternId,'Reflection Lists') … … 2533 2535 else: #1st row of refl ticks 2534 2536 Page.plotStyle['refOffset'] = event.ydata 2537 elif GSASIIpath.GetConfigValue('debug'): # should not happen! 2538 print('How did we get here?') 2539 GSASIIpath.IPyBreak() 2535 2540 PlotPatterns(G2frame,plotType=plottype,extraKeys=extraKeys) 2536 2541 G2frame.itemPicked = None
Note: See TracChangeset
for help on using the changeset viewer.