Changeset 3269
- Timestamp:
- Feb 10, 2018 10:43:45 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIphsGUI.py
r3268 r3269 4671 4671 Obj = event.GetEventObject() 4672 4672 item = Indx[Obj.GetId()] 4673 if not len(atm[-1]['SS1'][item]):4674 atm[-1]['SS1'][ 'Spos'] = [0,[]]4675 atm[-1]['SS1'][ Stype][0] = waveType.GetValue()4673 if len(atm[-1]['SS1'][item]) <= 1: 4674 atm[-1]['SS1'][item] = [0,] 4675 atm[-1]['SS1'][item][0] = waveType.GetValue() 4676 4676 wx.CallAfter(RepaintAtomInfo,G2frame.waveData.GetScrollPos(wx.VERTICAL)) 4677 4677 else: … … 4684 4684 item = Indx[Obj.GetId()] 4685 4685 nt = numVals[Stype] 4686 if not len(atm[-1]['SS1'][item] [1]) and waveTyp in ['ZigZag','Block','Crenel','SawTooth']:4686 if not len(atm[-1]['SS1'][item]) and waveTyp in ['ZigZag','Block','Crenel','SawTooth']: 4687 4687 nt = numVals[waveTyp] 4688 atm[-1]['SS1'][item] [1].append([[0.0 for i in range(nt)],False])4688 atm[-1]['SS1'][item].append([[0.0 for i in range(nt)],False]) 4689 4689 wx.CallAfter(RepaintAtomInfo,G2frame.waveData.GetScrollPos(wx.VERTICAL)) 4690 4690 … … 4699 4699 val = min(1.0,max(0.0,val)) 4700 4700 elif ival == 0: #Tmin 4701 val = max(-1.,min(val,atm[-1]['SS1'][item][1][ iwave][1][1]))4701 val = max(-1.,min(val,atm[-1]['SS1'][item][1][0][ival])) 4702 4702 except ValueError: 4703 val = atm[-1]['SS1'][item][iwave ][1][ival]4703 val = atm[-1]['SS1'][item][iwave+1][0][ival] 4704 4704 Obj.SetValue('%.5f'%val) 4705 atm[-1]['SS1'][item][iwave ][1][ival] = val4705 atm[-1]['SS1'][item][iwave+1][0][ival] = val 4706 4706 4707 4707 def OnRefWave(event): 4708 4708 Obj = event.GetEventObject() 4709 4709 item,iwave = Indx[Obj.GetId()] 4710 atm[-1]['SS1'][item][ 1][iwave][2] = not atm[-1]['SS1'][item][1][iwave][2]4710 atm[-1]['SS1'][item][iwave+1][1] = not atm[-1]['SS1'][item][iwave+1][1] 4711 4711 4712 4712 def OnDelWave(event): 4713 4713 Obj = event.GetEventObject() 4714 4714 item,iwave = Indx[Obj.GetId()] 4715 del atm[-1]['SS1'][item][ 1][iwave]4715 del atm[-1]['SS1'][item][iwave+1] 4716 4716 wx.CallAfter(RepaintAtomInfo,G2frame.waveData.GetScrollPos(wx.VERTICAL)) 4717 4717 … … 4835 4835 for ia,atom in enumerate(atomData): 4836 4836 for name in names: 4837 for wave in atom[-1]['SS1'][name] :4837 for wave in atom[-1]['SS1'][name][1:]: 4838 4838 wave[1] = flags[name][ia] 4839 4839 finally:
Note: See TracChangeset
for help on using the changeset viewer.