Skip to content

Commit 72c3c8a

Browse files
committed
Add stub for Draw Atoms box of enclosure
1 parent 6607a8e commit 72c3c8a

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

GSASII/GSASIIdataGUI.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7297,7 +7297,7 @@ def _makemenu(): # routine to create menu when first used
72977297
'wxID_DRAWVIEWPOINT', 'wxID_DRAWTRANSFORM', 'wxID_DRAWDELETE', 'wxID_DRAWFILLCELL',
72987298
'wxID_DRAWADDEQUIV', 'wxID_DRAWFILLCOORD', 'wxID_DRAWDISAGLTOR', 'wxID_DRAWPLANE',
72997299
'wxID_DRAWDISTVP', 'wxID_DRAWADDSPHERE', 'wxID_DRWAEDITRADII',
7300-
'wxID_DRAWSETSEL', 'wxID_DRAWLOADSEL',
7300+
'wxID_DRAWSETSEL', 'wxID_DRAWLOADSEL', 'wxID_DRAWADDBOX'
73017301
)
73027302
G2G.Define_wxId('wxID_DRAWRESTRBOND', 'wxID_DRAWRESTRANGLE', 'wxID_DRAWRESTRPLANE', 'wxID_DRAWRESTRCHIRAL',)
73037303
self.DrawAtomsMenu = wx.MenuBar()
@@ -7320,6 +7320,7 @@ def _makemenu(): # routine to create menu when first used
73207320
self.DrawAtomEdit.Append(G2G.wxID_DRAWSETSEL,'Select from list','Select atoms from a filtered listbox')
73217321
self.DrawAtomEdit.Append(G2G.wxID_DRAWADDEQUIV,'Add atoms','Add symmetry & cell equivalents to drawing set from selected atoms')
73227322
self.DrawAtomEdit.Append(G2G.wxID_DRAWADDSPHERE,'Add sphere of atoms','Add atoms within sphere of enclosure')
7323+
self.DrawAtomEdit.Append(G2G.wxID_DRAWADDBOX,'Add box of atoms','Add atoms within box of enclosure')
73237324
self.DrawAtomEdit.Append(G2G.wxID_DRAWTRANSFORM,'Transform draw atoms','Transform selected atoms by symmetry & cell translations')
73247325
self.DrawAtomEdit.Append(G2G.wxID_DRAWFILLCOORD,'Fill CN-sphere','Fill coordination sphere for selected atoms')
73257326
self.DrawAtomEdit.Append(G2G.wxID_DRAWFILLCELL,'Fill unit cell','Fill unit cell with selected atoms')

GSASII/GSASIIphsGUI.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10574,7 +10574,7 @@ def RowSelect(event):
1057410574
'Generate bonded','Select from list')
1057510575
callList = (DrawAtomsDelete,DrawAtomStyle, DrawAtomLabel,
1057610576
DrawAtomColor,SetViewPoint,AddSymEquiv,
10577-
AddSphere,TransformSymEquiv,
10577+
AddSphere,AddBox,TransformSymEquiv,
1057810578
FillCoordSphere,SelDrawList)
1057910579
onRightClick = drawAtoms.setupPopup(lblList,callList)
1058010580
drawAtoms.Bind(wg.EVT_GRID_CELL_RIGHT_CLICK, onRightClick)
@@ -10785,6 +10785,10 @@ def AddSymEquiv(event):
1078510785
UpdateDrawAtoms()
1078610786
drawAtoms.ClearSelection()
1078710787
G2plt.PlotStructure(G2frame,data)
10788+
10789+
def AddBox(event):
10790+
print('Box of enclosure, TBD')
10791+
1078810792

1078910793
def AddSphere(event=None,selection=None,radius=None,targets=None):
1079010794
cx,ct,cs,ci = G2mth.getAtomPtrs(data,draw=True)
@@ -16945,6 +16949,7 @@ def FillMenus():
1694516949
G2frame.Bind(wx.EVT_MENU, SetViewPoint, id=G2G.wxID_DRAWVIEWPOINT)
1694616950
G2frame.Bind(wx.EVT_MENU, AddSymEquiv, id=G2G.wxID_DRAWADDEQUIV)
1694716951
G2frame.Bind(wx.EVT_MENU, AddSphere, id=G2G.wxID_DRAWADDSPHERE)
16952+
G2frame.Bind(wx.EVT_MENU, AddBox, id=G2G.wxID_DRAWADDBOX)
1694816953
G2frame.Bind(wx.EVT_MENU, TransformSymEquiv, id=G2G.wxID_DRAWTRANSFORM)
1694916954
G2frame.Bind(wx.EVT_MENU, FillCoordSphere, id=G2G.wxID_DRAWFILLCOORD)
1695016955
G2frame.Bind(wx.EVT_MENU, FillUnitCell, id=G2G.wxID_DRAWFILLCELL)

0 commit comments

Comments
 (0)