Changeset 5122 for trunk/GSASIIElemGUI.py
- Timestamp:
- Jan 1, 2022 3:00:59 PM (15 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIElemGUI.py
r4660 r5122 20 20 import os 21 21 import wx.lib.colourselect as wscs 22 # for Python 3.10+, define a version of wxPoint that accepts float params 23 def wxPoint(x,y): return wx.Point(int(x),int(y)) 22 24 class PickElement(wx.Dialog): 23 25 '''Makes periodic table widget for picking element. Modes: … … 49 51 color=E[6] 50 52 self.ElButton(name=E[0], 51 pos=wx .Point(E[1]*self.butWid+25,E[2]*24+24),53 pos=wxPoint(E[1]*self.butWid+25,E[2]*24+24), 52 54 tip=E[3],color=color) 53 55 i+=1 54 56 if self.multiple: 55 57 b = wx.Button(self,wx.ID_CLOSE, 56 pos=wx .Point(16.5*self.butWid+25,7.75*24+24),label="Done")58 pos=wxPoint(16.5*self.butWid+25,7.75*24+24),label="Done") 57 59 b.Bind(wx.EVT_BUTTON, self.OnClose) 58 60 … … 246 248 for E in self.ElTable: 247 249 PickElements.ElButton(self,parent=elPanel,name=E[0], 248 pos=wx .Point(E[1]*30+20,E[2]*30+25),tip=E[3],color=E[4])250 pos=wxPoint(E[1]*30+20,E[2]*30+25),tip=E[3],color=E[4]) 249 251 i+=1 250 252 mainSizer.Add(elPanel,0,wx.EXPAND) … … 321 323 Elem = [] 322 324 for Elem in choice: 323 self.ElButton(name=Elem,pos=wx .Point(16+i*24, 16))325 self.ElButton(name=Elem,pos=wxPoint(16+i*24, 16)) 324 326 i+=1 325 327
Note: See TracChangeset
for help on using the changeset viewer.