Changeset 3909 for trunk/GSASIIphsGUI.py


Ignore:
Timestamp:
Apr 19, 2019 10:42:41 AM (3 years ago)
Author:
vondreele
Message:

Add new menu item to Map Peaks - Invert peak position; inverts map and then redoes the map search

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIphsGUI.py

    r3908 r3909  
    90319031        G2plt.PlotStructure(G2frame,data)
    90329032       
     9033    def OnPeaksInvert(event):
     9034        if 'Map Peaks' in data:
     9035            generalData = data['General']
     9036            mapData = generalData['Map']
     9037            try:
     9038                mapData['rho'] = np.flip(mapData['rho'],(0,1,2))
     9039            except TypeError:
     9040                mapData['rho'] = np.flip(mapData['rho'],0)
     9041                mapData['rho'] = np.flip(mapData['rho'],1)
     9042                mapData['rho'] = np.flip(mapData['rho'],2)               
     9043            OnSearchMaps(event)
     9044        FillMapPeaksGrid()
     9045        G2plt.PlotStructure(G2frame,data)
     9046       
    90339047    def OnPeaksEquiv(event):
    90349048        if 'Map Peaks' in data:
     
    95479561        G2frame.Bind(wx.EVT_MENU, OnShowBonds, id=G2G.wxID_SHOWBONDS)
    95489562        G2frame.Bind(wx.EVT_MENU, OnPeaksEquiv, id=G2G.wxID_FINDEQVPEAKS)
     9563        G2frame.Bind(wx.EVT_MENU, OnPeaksInvert, id=G2G.wxID_INVERTPEAKS)
    95499564        G2frame.Bind(wx.EVT_MENU, OnPeaksUnique, id=G2G.wxID_PEAKSUNIQUE)
    95509565        G2frame.Bind(wx.EVT_MENU, OnPeaksSave, id=G2G.wxID_PEAKSSAVE)
Note: See TracChangeset for help on using the changeset viewer.