@@ -27,21 +27,64 @@ def __init__(self, *args, **kwds):
2727 # begin wxGlade: SGConstrainDialog.__init__
2828 kwds ["style" ] = kwds .get ("style" , 0 ) | wx .DEFAULT_DIALOG_STYLE
2929 wx .Dialog .__init__ (self , * args , ** kwds )
30+ self .SetTitle ("Space Group Constraints" )
31+
32+ sizer_2 = wx .StaticBoxSizer (wx .StaticBox (self , wx .ID_ANY , "Space Group Constraints" ), wx .VERTICAL )
33+
3034 self .numConstrainedLabel = wx .StaticText (self , wx .ID_ANY , "" )
35+ sizer_2 .Add (self .numConstrainedLabel , 0 , wx .ALIGN_CENTER_HORIZONTAL | wx .ALL , 5 )
36+
37+ sizer_3 = wx .BoxSizer (wx .HORIZONTAL )
38+ sizer_2 .Add (sizer_3 , 0 , wx .EXPAND , 0 )
39+
3140 self .sgLabel = wx .StaticText (self , wx .ID_ANY , "Space Group" )
41+ sizer_3 .Add (self .sgLabel , 0 , wx .ALIGN_CENTER_VERTICAL | wx .ALL , 5 )
42+
3243 self .sgComboBox = wx .ComboBox (self , wx .ID_ANY , choices = ["P1" ], style = 0 )
44+ self .sgComboBox .SetSelection (0 )
45+ sizer_3 .Add (self .sgComboBox , 0 , wx .ALL , 5 )
46+
47+ sizer_4 = wx .BoxSizer (wx .HORIZONTAL )
48+ sizer_2 .Add (sizer_4 , 0 , wx .EXPAND , 0 )
49+
3350 self .offsetLabel = wx .StaticText (self , wx .ID_ANY , "Origin Offset" )
51+ sizer_4 .Add (self .offsetLabel , 0 , wx .ALIGN_CENTER_VERTICAL | wx .ALL , 5 )
52+
3453 self .offsetTextCtrlX = wx .TextCtrl (self , wx .ID_ANY , "0" )
54+ sizer_4 .Add (self .offsetTextCtrlX , 0 , wx .ALL , 5 )
55+
3556 self .offsetTextCtrlY = wx .TextCtrl (self , wx .ID_ANY , "0" )
57+ sizer_4 .Add (self .offsetTextCtrlY , 0 , wx .ALL , 5 )
58+
3659 self .offsetTextCtrlZ = wx .TextCtrl (self , wx .ID_ANY , "0" )
60+ sizer_4 .Add (self .offsetTextCtrlZ , 0 , wx .ALL , 5 )
61+
3762 self .positionCheckBox = wx .CheckBox (self , wx .ID_ANY , "constrain positions" )
63+ self .positionCheckBox .SetValue (1 )
64+ sizer_2 .Add (self .positionCheckBox , 0 , wx .ALL , 5 )
65+
3866 self .tfCheckBox = wx .CheckBox (self , wx .ID_ANY , "constrain temperature factors" )
67+ self .tfCheckBox .SetValue (1 )
68+ sizer_2 .Add (self .tfCheckBox , 0 , wx .ALL , 5 )
69+
3970 self .static_line_1 = wx .StaticLine (self , wx .ID_ANY )
71+ sizer_2 .Add (self .static_line_1 , 0 , wx .EXPAND , 0 )
72+
73+ sizer_4_copy = wx .BoxSizer (wx .HORIZONTAL )
74+ sizer_2 .Add (sizer_4_copy , 0 , wx .EXPAND , 0 )
75+
76+ sizer_4_copy .Add ((0 , 0 ), 1 , wx .EXPAND , 0 )
77+
4078 self .cancelButton = wx .Button (self , wx .ID_CANCEL , "Cancel" )
79+ sizer_4_copy .Add (self .cancelButton , 0 , wx .ALL , 5 )
80+
4181 self .okButton = wx .Button (self , wx .ID_OK , "OK" )
82+ sizer_4_copy .Add (self .okButton , 0 , wx .ALL , 5 )
4283
43- self .__set_properties ()
44- self .__do_layout ()
84+ self .SetSizer (sizer_2 )
85+ sizer_2 .Fit (self )
86+
87+ self .Layout ()
4588
4689 self .Bind (wx .EVT_COMBOBOX , self .onSGSelect , self .sgComboBox )
4790 self .Bind (wx .EVT_TEXT_ENTER , self .onSGTextEnter , self .sgComboBox )
@@ -55,41 +98,6 @@ def __init__(self, *args, **kwds):
5598 # end wxGlade
5699 self .__customProperties ()
57100
58- def __set_properties (self ):
59- # begin wxGlade: SGConstrainDialog.__set_properties
60- self .SetTitle ("Space Group Constraints" )
61- self .sgComboBox .SetSelection (0 )
62- self .positionCheckBox .SetValue (1 )
63- self .tfCheckBox .SetValue (1 )
64- # end wxGlade
65-
66- def __do_layout (self ):
67- # begin wxGlade: SGConstrainDialog.__do_layout
68- sizer_2 = wx .StaticBoxSizer (wx .StaticBox (self , wx .ID_ANY , "Space Group Constraints" ), wx .VERTICAL )
69- sizer_4_copy = wx .BoxSizer (wx .HORIZONTAL )
70- sizer_4 = wx .BoxSizer (wx .HORIZONTAL )
71- sizer_3 = wx .BoxSizer (wx .HORIZONTAL )
72- sizer_2 .Add (self .numConstrainedLabel , 0 , wx .ALIGN_CENTER | wx .ALL , 5 )
73- sizer_3 .Add (self .sgLabel , 0 , wx .ALIGN_CENTER_VERTICAL | wx .ALL , 5 )
74- sizer_3 .Add (self .sgComboBox , 0 , wx .ALL , 5 )
75- sizer_2 .Add (sizer_3 , 0 , wx .EXPAND , 0 )
76- sizer_4 .Add (self .offsetLabel , 0 , wx .ALIGN_CENTER_VERTICAL | wx .ALL , 5 )
77- sizer_4 .Add (self .offsetTextCtrlX , 0 , wx .ALL , 5 )
78- sizer_4 .Add (self .offsetTextCtrlY , 0 , wx .ALL , 5 )
79- sizer_4 .Add (self .offsetTextCtrlZ , 0 , wx .ALL , 5 )
80- sizer_2 .Add (sizer_4 , 0 , wx .EXPAND , 0 )
81- sizer_2 .Add (self .positionCheckBox , 0 , wx .ALL , 5 )
82- sizer_2 .Add (self .tfCheckBox , 0 , wx .ALIGN_CENTER_VERTICAL | wx .ALL , 5 )
83- sizer_2 .Add (self .static_line_1 , 0 , wx .EXPAND , 0 )
84- sizer_4_copy .Add ((0 , 0 ), 1 , wx .EXPAND , 0 )
85- sizer_4_copy .Add (self .cancelButton , 0 , wx .ALL , 5 )
86- sizer_4_copy .Add (self .okButton , 0 , wx .ALL , 5 )
87- sizer_2 .Add (sizer_4_copy , 0 , wx .EXPAND , 0 )
88- self .SetSizer (sizer_2 )
89- sizer_2 .Fit (self )
90- self .Layout ()
91- # end wxGlade
92-
93101 ###########################################################################
94102
95103 def __customProperties (self ):
0 commit comments