Changeset 2809 for trunk/GSASIIgrid.py
- Timestamp:
- Apr 26, 2017 9:51:43 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIgrid.py
r2797 r2809 173 173 'abc*':np.eye(3), } 174 174 commonNames = ['abc','bca','cab','a-cb','ba-c','-cba','P->A','A->P','P->B','B->P','P->C','C->P', 175 'P->I','I->P','P->F','F->P','H->R','R->H','R->O','O->R','abc*', ]175 'P->I','I->P','P->F','F->P','H->R','R->H','R->O','O->R','abc*','setting 1->2'] #don't put any new ones after the setting one! 176 176 177 177 # Should SGMessageBox, SymOpDialog, DisAglDialog be moved? … … 554 554 self.Phase['General']['SGData'] = SGData 555 555 else: 556 self.Trans = commonTrans[self.Common] 557 if 'R' == self.Common[-1]: 558 self.newSpGrp += ' r' 559 SGErr,SGData = G2spc.SpcGroup(self.newSpGrp) 560 self.Phase['General']['SGData'] = SGData 561 SGTxt.SetValue(self.newSpGrp) 556 if self.Common == commonNames[-1]: 557 self.Vec = G2spc.spg2origins[self.oldSpGrp] 558 self.newSpGrp = self.oldSpGrp 559 else: 560 self.Trans = commonTrans[self.Common] 561 if 'R' == self.Common[-1]: 562 self.newSpGrp += ' r' 563 SGErr,SGData = G2spc.SpcGroup(self.newSpGrp) 564 self.Phase['General']['SGData'] = SGData 565 SGTxt.SetValue(self.newSpGrp) 562 566 OnTest(event) 563 567 … … 622 626 commonSizer = wx.BoxSizer(wx.HORIZONTAL) 623 627 commonSizer.Add(wx.StaticText(self.panel,label=' Common transformations: '),0,WACV) 624 common = wx.ComboBox(self.panel,value=self.Common,choices=commonNames, 625 style=wx.CB_READONLY|wx.CB_DROPDOWN) 628 if self.oldSpGrp not in G2spc.spg2origins: 629 common = wx.ComboBox(self.panel,value=self.Common,choices=commonNames[-1], 630 style=wx.CB_READONLY|wx.CB_DROPDOWN) 631 else: 632 common = wx.ComboBox(self.panel,value=self.Common,choices=commonNames, 633 style=wx.CB_READONLY|wx.CB_DROPDOWN) 626 634 common.Bind(wx.EVT_COMBOBOX,OnCommon) 627 635 commonSizer.Add(common,0,WACV) … … 697 705 self.Phase['General']['Name'] += ' %s'%(self.Common) 698 706 self.Phase['General']['Cell'][1:] = G2lat.TransformCell(self.oldCell[:6],self.Trans) 699 return self.Phase,self.Trans,self.Vec,self.ifMag,self.ifConstr 707 return self.Phase,self.Trans,self.Vec,self.ifMag,self.ifConstr,self.Common 700 708 701 709 def OnOk(self,event): … … 1144 1152 commonSizer = wx.BoxSizer(wx.HORIZONTAL) 1145 1153 commonSizer.Add(wx.StaticText(self.panel,label=' Common transformations: '),0,WACV) 1146 common = wx.ComboBox(self.panel,value=self.Common,choices=commonNames[:- 1], #not the last one!1154 common = wx.ComboBox(self.panel,value=self.Common,choices=commonNames[:-2], #not the last two! 1147 1155 style=wx.CB_READONLY|wx.CB_DROPDOWN) 1148 1156 common.Bind(wx.EVT_COMBOBOX,OnCommon)
Note: See TracChangeset
for help on using the changeset viewer.