Changeset 4373


Ignore:
Timestamp:
Mar 19, 2020 9:34:58 AM (4 years ago)
Author:
vondreele
Message:

cleanup magnetic sym op display - now allows print of X1,x2,x3,x4 as well as x,y,z,t format
adds +1 or -1 for spin.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIctrlGUI.py

    r4368 r4373  
    32523252        self.panel = wx.Panel(self)
    32533253        self.spins = spins
     3254        self.useAlt = False
    32543255        mainSizer = wx.BoxSizer(wx.VERTICAL)
    32553256        mainSizer.Add((0,10))
     
    32823283        def OnPrintOps(event):
    32833284            print(' Symmetry operations for %s:'%self.text[0].split(':')[1])
    3284             for opText in G2spc.TextOps(self.text,self.table,reverse=True):
    3285                 print(opText.replace(' ',''))
     3285            for iop,opText in enumerate(G2spc.TextOps(self.text,self.table,reverse=True)):
     3286                if self.useAlt:
     3287                    opText = opText.replace('x','x1').replace('y','x2').replace('z','x3').replace('t','x4')
     3288                if len(self.spins):
     3289                    if self.spins[iop] > 0:
     3290                        print('%s,+%d'%(opText.replace(' ',''),self.spins[iop]))
     3291                    else:
     3292                        print('%s,%d'%(opText.replace(' ',''),self.spins[iop]))
     3293                else:   
     3294                    print(opText.replace(' ',''))
     3295                   
     3296        def OnAlt(event):
     3297            self.useAlt = altBtn.GetValue()
    32863298           
    32873299        mainSizer.Add(tableSizer,0,wx.ALIGN_LEFT)
     
    32933305        printBtn.Bind(wx.EVT_BUTTON, OnPrintOps)
    32943306        btnsizer.Add(printBtn)
     3307        altBtn = wx.CheckBox(self.panel,label=' Use alt. symbols?')
     3308        altBtn.Bind(wx.EVT_CHECKBOX,OnAlt)
     3309        btnsizer.Add(altBtn,0,WACV)
    32953310        mainSizer.Add((0,10))
    32963311        mainSizer.Add(btnsizer,0,wx.ALIGN_CENTER)
  • trunk/GSASIIphsGUI.py

    r4370 r4373  
    21822182            if SGData['SGGray']:
    21832183                SpGrp += " 1'"
    2184             if 'BNSlattsym' in SGData and '_' in SGData['BNSlattsym'][0]:
    2185                 SpGrp = SGData['BNSlattsym'][0]+SpGrp[1:]
    21862184            modSizer.Add(wx.StaticText(General,label=' Superspace group: %s '%SpGrp),0,WACV)
    21872185            if not SGData['SGFixed']:
Note: See TracChangeset for help on using the changeset viewer.