Changeset 5272
- Timestamp:
- May 6, 2022 2:02:14 PM (17 months ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIdataGUI.py
r5271 r5272 397 397 * We know of problems with Python <2.7 and <3.6. 398 398 * A problem has been noted with wx4.0.7.post2 with Python 3.10 that we can't yet duplicate (2/4/22). 399 * We anticipate that Python 3.10 will flag code that previously worked fine 400 with errors where we pass a floating point number to a wxpython routine that 401 expects a int value. 399 402 400 403 * wxPython: … … 446 449 if compareVersions(platform.python_version(), 447 450 versionDict['tooNewWarn']['python']) >= 0: 448 print (22*' '+"-- This version of Python is too new for testing") 449 Image = None 451 print (22*' '+"-- We are anticipating significant problems with this new version of Python. Please report them.") 450 452 version = '?' 451 453 versionDict['errors'] = '' … … 478 480 break 479 481 print(" {:12s}{} {}".format(s+':',m.__version__,msg)) 482 Image = None 480 483 try: 481 484 from PIL import Image -
trunk/GSASIIphsGUI.py
r5269 r5272 3608 3608 G2frame.GetStatusBar().SetStatusText('Warning: The location of the origin is arbitrary in '+SGData['SGPolax'],1) 3609 3609 if 'phoenix' in wx.version(): 3610 Atoms.Unbind(wg.EVT_GRID_CELL_CHANGED) 3610 3611 Atoms.Bind(wg.EVT_GRID_CELL_CHANGED, ChangeAtomCell) 3611 3612 else: 3613 Atoms.Unbind(wg.EVT_GRID_CELL_CHANGE) 3612 3614 Atoms.Bind(wg.EVT_GRID_CELL_CHANGE, ChangeAtomCell) 3615 Atoms.Unbind(wg.EVT_GRID_CELL_LEFT_DCLICK) 3616 Atoms.Unbind(wg.EVT_GRID_LABEL_LEFT_DCLICK) 3617 Atoms.Unbind(wg.EVT_GRID_LABEL_LEFT_CLICK) 3618 Atoms.Unbind(wg.EVT_GRID_LABEL_RIGHT_CLICK) 3613 3619 Atoms.Bind(wg.EVT_GRID_CELL_LEFT_DCLICK, AtomTypeSelect) 3614 3620 Atoms.Bind(wg.EVT_GRID_LABEL_LEFT_DCLICK, RefreshAtomGrid) … … 8969 8975 drawAtoms.SetColSize(colLabels.index('Color'),50) 8970 8976 if 'phoenix' in wx.version(): 8977 drawAtoms.Unbind(wg.EVT_GRID_CELL_CHANGED) 8971 8978 drawAtoms.Bind(wg.EVT_GRID_CELL_CHANGED, RefreshDrawAtomGrid) 8972 8979 else: 8980 drawAtoms.Unbind(wg.EVT_GRID_CELL_CHANGE) 8973 8981 drawAtoms.Bind(wg.EVT_GRID_CELL_CHANGE, RefreshDrawAtomGrid) 8982 drawAtoms.Unbind(wg.EVT_GRID_LABEL_LEFT_DCLICK) 8983 drawAtoms.Unbind(wg.EVT_GRID_CELL_LEFT_DCLICK) 8984 drawAtoms.Unbind(wg.EVT_GRID_LABEL_LEFT_CLICK) 8974 8985 drawAtoms.Bind(wg.EVT_GRID_LABEL_LEFT_DCLICK, RefreshDrawAtomGrid) 8975 8986 drawAtoms.Bind(wg.EVT_GRID_CELL_LEFT_DCLICK, RefreshDrawAtomGrid) … … 13302 13313 # FillPawleyReflectionsGrid executable starts here 13303 13314 G2frame.GetStatusBar().SetStatusText('To delete a Pawley reflection: select row & press Delete',1) 13304 # oldSizer = PawleyRefList.GetSizer() 13305 # if oldSizer: oldSizer.Clear(True) 13315 if G2frame.PawleyRefl in G2frame.phaseDisplay.gridList: 13316 G2frame.phaseDisplay.gridList.remove(G2frame.PawleyRefl) 13317 oldSizer = PawleyRefList.GetSizer() 13318 if oldSizer: oldSizer.Clear(True) 13306 13319 generalData = data['General'] 13307 13320 PawleyPeaks = data['Pawley ref'] 13308 # removed because it interfered with normal ops. & crashed GSAS-II 13309 # if len(PawleyPeaks) == 0 or not generalData['doPawley']: 13310 # msg = ('Pawley refinement not yet set up. Use the "Pawley setup"'+ 13311 # ' and "Pawley create" menu commands to change this. '+ 13312 # '(Note settings also found on General tab).') 13313 # if not generalData['doPawley']: 13314 # msg += '\n\nCall Pawley setup?' 13315 # else: 13316 # msg += '\n\nCall Pawley create?' 13317 # dlg = wx.MessageDialog(G2frame,msg,'Pawley not setup', 13318 # wx.YES_NO | wx.ICON_QUESTION) 13319 # try: 13320 # dlg.CenterOnParent() 13321 # result = dlg.ShowModal() 13322 # if result == wx.ID_YES and not generalData['doPawley']: 13323 # wx.CallAfter(OnPawleySet,None) 13324 # elif result == wx.ID_YES: 13325 # wx.CallAfter(OnPawleyLoad,None) 13326 # finally: 13327 # dlg.Destroy() 13321 13328 13322 mainSizer = wx.BoxSizer(wx.VERTICAL) 13329 13323 topSizer = wx.BoxSizer(wx.HORIZONTAL) 13330 topSizer.Add(wx.StaticText(PawleyRefList,label='Pawley reflections for %s:'%generalData['Name']),0,WACV) 13324 if len(PawleyPeaks) and generalData['doPawley']: 13325 topSizer.Add(wx.StaticText(PawleyRefList,label='Pawley reflections for %s:'%generalData['Name']),0,WACV) 13326 else: 13327 topSizer.Add(wx.StaticText(PawleyRefList,label='There are no Pawley reflections for %s:'%generalData['Name']),0,WACV) 13331 13328 topSizer.Add((-1,-1),1,wx.EXPAND) 13332 13329 topSizer.Add(G2G.HelpButton(PawleyRefList,helpIndex=G2frame.dataWindow.helpKey)) 13333 13330 mainSizer.Add(topSizer,0,wx.EXPAND) 13334 13331 rowLabels = [] 13335 if len(PawleyPeaks) :13332 if len(PawleyPeaks) and generalData['doPawley']: 13336 13333 for i in range(len(PawleyPeaks)): rowLabels.append(str(i)) 13337 13334 if generalData['Modulated']: … … 13346 13343 pos = [5,6] 13347 13344 PawleyTable = G2G.Table(PawleyPeaks,rowLabels=rowLabels,colLabels=colLabels,types=Types) 13345 G2frame.PawleyRefl = G2G.GSGrid(PawleyRefList) 13348 13346 G2frame.PawleyRefl.SetTable(PawleyTable, True) 13349 G2frame.PawleyRefl.Bind(wx.EVT_KEY_DOWN, KeyEditPawleyGrid) 13347 G2frame.PawleyRefl.Unbind(wx.EVT_KEY_DOWN) 13348 G2frame.PawleyRefl.Bind(wx.EVT_KEY_DOWN, KeyEditPawleyGrid) 13349 G2frame.PawleyRefl.Unbind(wg.EVT_GRID_LABEL_LEFT_DCLICK) 13350 13350 G2frame.PawleyRefl.Bind(wg.EVT_GRID_LABEL_LEFT_DCLICK, onRefineDClick) 13351 13351 for r in range(G2frame.PawleyRefl.GetNumberRows()): … … 13359 13359 mainSizer.Add(G2frame.PawleyRefl) 13360 13360 else: 13361 mainSizer.Add(wx.StaticText(PawleyRefList,label=' There are no Pawley reflections')) 13361 msg = ('\tPawley refinement has not yet been set up. Use the Operations->"Pawley setup"'+ 13362 ' menu command to change this.\n\t'+ 13363 '(If Pawley settings have already been set on the General tab, use Operations->"Pawley create").') 13364 mainSizer.Add(wx.StaticText(PawleyRefList,label=msg)) 13362 13365 SetPhaseWindow(PawleyRefList,mainSizer) 13363 13366 … … 13370 13373 pawlNegWt.Enable(generalData['doPawley']) 13371 13374 generalData = data['General'] 13372 startPawley = generalData['doPawley'] 13375 prevPawleySetting = generalData['doPawley'] 13376 generalData['doPawley'] = True # make Pawley extraction the default if we get here 13373 13377 startDmin = generalData['Pawley dmin'] 13374 13378 genDlg = wx.Dialog(G2frame,title='Set Pawley Parameters', … … 13425 13429 res = genDlg.ShowModal() 13426 13430 genDlg.Destroy() 13427 13428 if generalData['doPawley'] and res == wx.ID_OK and (not startPawley or startDmin != generalData['Pawley dmin']): 13429 dlg = wx.MessageDialog(G2frame,'Do you want to initialize the Pawley reflections with the settings?','Initialize Pawley?', 13431 if res == wx.ID_NO: return 13432 13433 # ask to generate the reflections if the extraction setting or dmin has changed 13434 if generalData['doPawley'] and res == wx.ID_OK and ( 13435 not prevPawleySetting or startDmin != generalData['Pawley dmin']): 13436 dlg = wx.MessageDialog(G2frame,'Do you want to generate the Pawley reflections with these settings? ("Pawley create" command)','Initialize Pawley?', 13430 13437 wx.YES_NO | wx.ICON_QUESTION) 13431 13438 try: … … 13678 13685 G2frame.MapPeaksTable = G2G.Table(mapPeaks,rowLabels=rowLabels,colLabels=colLabels,types=Types) 13679 13686 MapPeaks.SetTable(G2frame.MapPeaksTable, True) 13687 MapPeaks.Unbind(wg.EVT_GRID_LABEL_LEFT_CLICK) 13680 13688 MapPeaks.Bind(wg.EVT_GRID_LABEL_LEFT_CLICK, RowSelect) 13681 13689 for r in range(MapPeaks.GetNumberRows()): … … 14536 14544 Pages.append('Texture') 14537 14545 PawleyRefList = wx.ScrolledWindow(G2frame.phaseDisplay) 14538 G2frame.PawleyRefl = G2G.GSGrid(PawleyRefList) 14546 G2frame.PawleyRefl = None # grid now created when needed 14547 # G2frame.PawleyRefl = G2G.GSGrid(PawleyRefList) 14539 14548 # G2frame.PawleyRefl.SetScrollRate(0,0) 14540 G2frame.phaseDisplay.gridList.append(G2frame.PawleyRefl)14549 # G2frame.phaseDisplay.gridList.append(G2frame.PawleyRefl) 14541 14550 G2frame.phaseDisplay.AddPage(PawleyRefList,'Pawley reflections') 14542 14551 Pages.append('Pawley reflections') -
trunk/help/gsasII-phase.html
r5262 r5272 5646 5646 this way. <o:p></o:p></span></p> 5647 5647 5648 <h4 style='margin-left:.25in'><a name= Texture></a><a name="_Ref74983049"></a><a5648 <h4 style='margin-left:.25in'><a name=Phase-Texture></a><a name="_Ref74983049"></a><a 5649 5649 name=Phase-Texture></a>Texture</h4> 5650 5650 … … 6978 6978 6979 6979 <p class=MsoNormal style='margin-left:.5in;tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><a 6980 name=" _Pawley_reflections"></a><o:p> </o:p></p>6980 name="Phase-Pawley_reflections"></a><o:p> </o:p></p> 6981 6981 6982 6982 <h4>Pawley reflections</h4> … … 7483 7483 </span></div> 7484 7484 7485 <p class=MsoNormal><span style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last 7486 modified: Thu Mar 24 16:28:36 CDT 2022 <!-- hhmts end --><o:p></o:p></span></p> 7485 <p class=MsoNormal><span style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last modified: Fri May 6 13:29:00 CDT 2022 <!-- hhmts end --><o:p></o:p></span></p> 7487 7486 7488 7487 </div> -
trunk/help/gsasII-pwdr.html
r5262 r5272 4825 4825 style='mso-fareast-font-family:"Times New Roman"'><o:p></o:p></span></u></h4> 4826 4826 4827 <p class=MsoNormal><a name= Background></a><span style='mso-fareast-font-family:4827 <p class=MsoNormal><a name=PWDR_Background></a><span style='mso-fareast-font-family: 4828 4828 "Times New Roman"'>This window shows the choice of background functions and 4829 4829 coefficients to be used in fitting this powder pattern. There are four types of … … 6041 6041 6042 6042 <p class=MsoNormal style='tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span 6043 style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last 6044 modified: Wed Mar 23 12:18:41 CDT 2022 <!-- hhmts end --><o:p></o:p></span></p> 6043 style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last modified: Fri May 6 13:32:49 CDT 2022 <!-- hhmts end --><o:p></o:p></span></p> 6045 6044 6046 6045 </div>
Note: See TracChangeset
for help on using the changeset viewer.