Skip to content

Commit

Permalink
Merge pull request #115 from molssi-seamm/dev
Browse files Browse the repository at this point in the history
Bugfixes for Lewis structure
  • Loading branch information
seamm authored Apr 24, 2023
2 parents e4a72bc + 63c3aef commit 8405c8f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
=======
History
=======
2023.4.24 -- Bugfixes for Lewis structure
* Correctly handle periodic systems in Lewis structure.
* Fixed and issue with the Lewis structure GUI not displaying all the widgets.

2023.3.31 -- Bugfix
Lewis structure could reference a variable before it was set, and crash.

Expand Down
3 changes: 2 additions & 1 deletion mopac_step/lewis_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ def __init__(self, flowchart=None, extension=None):
# Don't want user to change keywords!
del self._metadata["keywords"]
self.parameters = mopac_step.LewisStructureParameters()
self._lattice_opt = False

def description_text(self, P=None):
"""Return a short description of this step.
Expand Down Expand Up @@ -157,7 +158,7 @@ def run(self):

text = ""
lines = []
lines.append(" ".join(["LEWIS", "LET"] + extra_keywords))
lines.append(" ".join(["LEWIS", "LET", "GEO-OK"] + extra_keywords))
lines.append(system.name)
lines.append(configuration.name)

Expand Down
3 changes: 1 addition & 2 deletions mopac_step/tk_lewis_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@ def create_dialog(self, title="Edit Lewis Structure Step"):
frame = super().create_dialog(title=title)

# Create all the widgets
print(type(self.node))
print(type(self.node.parameters))
P = self.node.parameters
row = 0
widgets = []
Expand All @@ -65,6 +63,7 @@ def create_dialog(self, title="Edit Lewis Structure Step"):
w = self[key] = P[key].widget(frame)
w.grid(row=row, column=0, sticky=tk.EW)
widgets.append(w)
row += 1
sw.align_labels(widgets, sticky=tk.E)

self.setup_results()
Expand Down

0 comments on commit 8405c8f

Please sign in to comment.