MoleditPy 2.2.0a2__py3-none-any.whl → 2.2.0a3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. moleditpy/modules/constants.py +1 -1
  2. moleditpy/modules/main_window_main_init.py +31 -13
  3. moleditpy/modules/plugin_interface.py +1 -10
  4. moleditpy/modules/plugin_manager.py +0 -3
  5. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/METADATA +1 -1
  6. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/RECORD +10 -27
  7. moleditpy/plugins/Analysis/ms_spectrum_neo.py +0 -919
  8. moleditpy/plugins/File/animated_xyz_giffer.py +0 -583
  9. moleditpy/plugins/File/cube_viewer.py +0 -689
  10. moleditpy/plugins/File/gaussian_fchk_freq_analyzer.py +0 -1148
  11. moleditpy/plugins/File/mapped_cube_viewer.py +0 -552
  12. moleditpy/plugins/File/orca_out_freq_analyzer.py +0 -1226
  13. moleditpy/plugins/File/paste_xyz.py +0 -336
  14. moleditpy/plugins/Input Generator/gaussian_input_generator_neo.py +0 -930
  15. moleditpy/plugins/Input Generator/orca_input_generator_neo.py +0 -1028
  16. moleditpy/plugins/Input Generator/orca_xyz2inp_gui.py +0 -286
  17. moleditpy/plugins/Optimization/all-trans_optimizer.py +0 -65
  18. moleditpy/plugins/Optimization/complex_molecule_untangler.py +0 -268
  19. moleditpy/plugins/Optimization/conf_search.py +0 -224
  20. moleditpy/plugins/Utility/atom_colorizer.py +0 -262
  21. moleditpy/plugins/Utility/console.py +0 -163
  22. moleditpy/plugins/Utility/pubchem_ressolver.py +0 -244
  23. moleditpy/plugins/Utility/vdw_radii_overlay.py +0 -432
  24. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/WHEEL +0 -0
  25. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/entry_points.txt +0 -0
  26. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/licenses/LICENSE +0 -0
  27. {moleditpy-2.2.0a2.dist-info → moleditpy-2.2.0a3.dist-info}/top_level.txt +0 -0
@@ -16,7 +16,7 @@ from PyQt6.QtGui import QFont, QColor
16
16
  from rdkit import Chem
17
17
 
18
18
  #Version
19
- VERSION = '2.2.0a2'
19
+ VERSION = '2.2.0a3'
20
20
 
21
21
  ATOM_RADIUS = 18
22
22
  BOND_OFFSET = 3.5
@@ -32,7 +32,7 @@ except Exception:
32
32
  # PyQt6 Modules
33
33
  from PyQt6.QtWidgets import (
34
34
  QApplication, QWidget, QVBoxLayout, QHBoxLayout,
35
- QPushButton, QSplitter, QToolBar, QSizePolicy, QLabel, QToolButton, QMenu, QMessageBox
35
+ QPushButton, QSplitter, QToolBar, QSizePolicy, QLabel, QToolButton, QMenu, QMessageBox, QFileDialog
36
36
  )
37
37
 
38
38
  from PyQt6.QtGui import (
@@ -1901,20 +1901,38 @@ class MainWindowMainInit(object):
1901
1901
  parent_menu.addAction(action)
1902
1902
 
1903
1903
  # 4. Integrate Export Actions into Export Button and Menu
1904
+ # 4. Integrate Export Actions into Export Button AND Main File->Export Menu
1904
1905
  if self.plugin_manager.export_actions:
1906
+ # Find Main File -> Export menu
1907
+ main_export_menu = None
1908
+ for top_action in self.menuBar().actions():
1909
+ if top_action.text().replace('&', '') == 'File' and top_action.menu():
1910
+ for sub_action in top_action.menu().actions():
1911
+ if sub_action.text().replace('&', '') == 'Export' and sub_action.menu():
1912
+ main_export_menu = sub_action.menu()
1913
+ break
1914
+ if main_export_menu: break
1915
+
1916
+ # List of menus to populate
1917
+ target_menus = []
1905
1918
  if hasattr(self, 'export_button') and self.export_button.menu():
1906
- # Add separator
1907
- sep = self.export_button.menu().addSeparator()
1908
- sep.setData(PLUGIN_ACTION_TAG)
1909
-
1910
- for exp in self.plugin_manager.export_actions:
1911
- label = exp['label']
1912
- callback = exp['callback']
1913
-
1914
- a = QAction(label, self)
1915
- a.triggered.connect(callback)
1916
- a.setData(PLUGIN_ACTION_TAG)
1917
- self.export_button.menu().addAction(a)
1919
+ target_menus.append(self.export_button.menu())
1920
+ if main_export_menu:
1921
+ target_menus.append(main_export_menu)
1922
+
1923
+ for menu in target_menus:
1924
+ # Add separator
1925
+ sep = menu.addSeparator()
1926
+ sep.setData(PLUGIN_ACTION_TAG)
1927
+
1928
+ for exp in self.plugin_manager.export_actions:
1929
+ label = exp['label']
1930
+ callback = exp['callback']
1931
+
1932
+ a = QAction(label, self)
1933
+ a.triggered.connect(callback)
1934
+ a.setData(PLUGIN_ACTION_TAG)
1935
+ menu.addAction(a)
1918
1936
 
1919
1937
  # 5. Integrate File Openers into Import Menu
1920
1938
  if hasattr(self, 'import_menu') and self.plugin_manager.file_openers:
@@ -159,16 +159,7 @@ class PluginContext:
159
159
  self._manager.register_3d_style(self._plugin_name, style_name, callback)
160
160
 
161
161
 
162
- def add_panel_button(self, text: str, callback: Callable, panel: str = "right"):
163
- """
164
- Add a button to the bottom control panel.
165
-
166
- Args:
167
- text: Label on the button.
168
- callback: Function to call on click.
169
- panel: "left" (2D Editor) or "right" (3D Viewer). Default "right".
170
- """
171
- self._manager.register_panel_button(self._plugin_name, text, callback, panel)
162
+
172
163
 
173
164
 
174
165
 
@@ -40,7 +40,6 @@ class PluginManager:
40
40
  # Registries for actions
41
41
  self.menu_actions = [] # List of (plugin_name, path, callback, text, icon, shortcut)
42
42
  self.toolbar_actions = []
43
- self.context_menu_3d_actions = []
44
43
  self.drop_handlers = [] # List of (priority, plugin_name, callback)
45
44
 
46
45
  # Extended Registries (Added to prevent lazy initialization "monkey patching")
@@ -49,7 +48,6 @@ class PluginManager:
49
48
  self.file_openers = {}
50
49
  self.analysis_tools = []
51
50
  self.save_handlers = {}
52
- self.save_handlers = {}
53
51
  self.load_handlers = {}
54
52
  self.custom_3d_styles = {} # style_name -> {'plugin': name, 'callback': func}
55
53
 
@@ -98,7 +96,6 @@ class PluginManager:
98
96
  self.plugins = []
99
97
  self.menu_actions = []
100
98
  self.toolbar_actions = []
101
- self.context_menu_3d_actions = []
102
99
  self.drop_handlers = []
103
100
 
104
101
  # Clear extended registries
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: MoleditPy
3
- Version: 2.2.0a2
3
+ Version: 2.2.0a3
4
4
  Summary: A cross-platform, simple, and intuitive molecular structure editor built in Python. It allows 2D molecular drawing and 3D structure visualization. It supports exporting structure files for input to DFT calculation software.
5
5
  Author-email: HiroYokoyama <titech.yoko.hiro@gmail.com>
6
6
  License: GNU GENERAL PUBLIC LICENSE
@@ -12,7 +12,7 @@ moleditpy/modules/bond_item.py,sha256=eVkEeKvM4igYI67DYxpey3FllqDyt_iWDo4VPYMhaP
12
12
  moleditpy/modules/bond_length_dialog.py,sha256=k5x_DhK9Q8CSwouKhEo_kLRRdaYHDaK84KDNmuDNLvY,14868
13
13
  moleditpy/modules/calculation_worker.py,sha256=KiGQY7i-QCQofEoE0r65KoQgpEGFcbhmxWv6egfkUdc,42324
14
14
  moleditpy/modules/color_settings_dialog.py,sha256=Ow44BhCOLo0AFb6klO001k6B4drOgKX9DeNBQhZLp5o,15474
15
- moleditpy/modules/constants.py,sha256=7m9mLA8eKnYh2PPXu5pXMtRndPdZVQdSej_WjMGpsrI,4704
15
+ moleditpy/modules/constants.py,sha256=KNnQdr1hATDivMItO0ylf-0bSLTDmjrH6EBBQ53kkis,4704
16
16
  moleditpy/modules/constrained_optimization_dialog.py,sha256=IEdNVhFoNSEMeA5ABpUH9Q88-YzDXFloQM2gwnPwnHY,30150
17
17
  moleditpy/modules/custom_interactor_style.py,sha256=NjsXE2a43IDNEanZBlcG9eR4ZIERT1MsQC6lbfesapQ,38453
18
18
  moleditpy/modules/custom_qt_interactor.py,sha256=MFaTuDh-FPeFBS4303CqxsxmsOIOW4QXUz6USwI8PHQ,2451
@@ -25,7 +25,7 @@ moleditpy/modules/main_window_dialog_manager.py,sha256=S1ROCWqzB2uVSKHY4o5CbTtJA
25
25
  moleditpy/modules/main_window_edit_3d.py,sha256=uY203adPg3CLyAdbG2NCThG2Am0WduzPDan9rXAlc14,19841
26
26
  moleditpy/modules/main_window_edit_actions.py,sha256=lUFxNFTUQzeXN8CNlb4_4S9j4M1EEq8kpJmh9dCzM3M,64818
27
27
  moleditpy/modules/main_window_export.py,sha256=e0HA_jeaokIOBunQqGxUn5QKdniCmE8GrsE1Igy6zm8,38351
28
- moleditpy/modules/main_window_main_init.py,sha256=2MWBLY_u4UoSC4orjhDh1WcfR8FoWEnhR9ibUeA_fnE,88438
28
+ moleditpy/modules/main_window_main_init.py,sha256=AZb2GZmvUYsVBhV2c54FEoWmFXRPkdSMlsshKraOGPs,89315
29
29
  moleditpy/modules/main_window_molecular_parsers.py,sha256=Ex4-urYsKf6PyHp4XToOhgXzuYWa_n7q--QmHci4OCU,48401
30
30
  moleditpy/modules/main_window_project_io.py,sha256=q1vEmWQDqla32HVkmk8-j0OY9ut5TI5NJ4ikahewkEo,17259
31
31
  moleditpy/modules/main_window_string_importers.py,sha256=mQVDv2Dj4MwnPgMRe2IqdAAKnB_quE6QfYeAgCjfv28,10892
@@ -38,8 +38,8 @@ moleditpy/modules/molecule_scene.py,sha256=khdt7h9Mk_D1cMbYeHGtq7P9aFXo0xG-hcShU
38
38
  moleditpy/modules/move_group_dialog.py,sha256=65HVXTJSaQ9lp03XFhI1l7OzUsXmH_aqd8OgwjpjfGg,27174
39
39
  moleditpy/modules/periodic_table_dialog.py,sha256=ItEZUts1XCietz9paY-spvbzxh6SXak3GnikwqkHZCw,4006
40
40
  moleditpy/modules/planarize_dialog.py,sha256=yY8o-SxT8vGEHVWnjDTXecRv5NUaEejEsXH-836Xk8g,8681
41
- moleditpy/modules/plugin_interface.py,sha256=54zMHkjf9TCyXyAqYeYvnG-R4mWhTaSZ8oIQt3lHqvQ,8082
42
- moleditpy/modules/plugin_manager.py,sha256=ghIKOBsWlTmzsQJXtncH9nyfQJUF_dwBOKrU4iBlNo0,13576
41
+ moleditpy/modules/plugin_interface.py,sha256=W6Hw1OLqMkcg8XU-S347v2sDBMEoo6iiCSbmL6MjZrA,7639
42
+ moleditpy/modules/plugin_manager.py,sha256=cxbqIE7Rb_KeBd-cG1vF2ySY2qNx8IJVRXjVPyQMFDc,13457
43
43
  moleditpy/modules/plugin_manager_window.py,sha256=m2lJ-UltwoXQ2SYA1im6Q0v-5SfqWL2HcOBCTzUmiBw,9963
44
44
  moleditpy/modules/settings_dialog.py,sha256=Nr7yE8UmYRi3VObWvRlrnv0DnjSjmYXbvqryZ02O12k,65348
45
45
  moleditpy/modules/template_preview_item.py,sha256=djdq3tz73d_fJGOvai3E-V9Hk9q9ZW7skx7BV59mooA,6556
@@ -50,26 +50,9 @@ moleditpy/modules/zoomable_view.py,sha256=hjwljui13QpvjvxJHY4Evot4jMQvxRBQUNH5HU
50
50
  moleditpy/modules/assets/icon.icns,sha256=wD5R6-Vw7K662tVKhu2E1ImN0oUuyAP4youesEQsn9c,139863
51
51
  moleditpy/modules/assets/icon.ico,sha256=RfgFcx7-dHY_2STdsOQCQziY5SNhDr3gPnjO6jzEDPI,147975
52
52
  moleditpy/modules/assets/icon.png,sha256=kCFN1WacYIdy0GN6SFEbNA00ef39pCczBnFdkkBI8Bs,147110
53
- moleditpy/plugins/Analysis/ms_spectrum_neo.py,sha256=dmTh48f9to2efOX0-jpQXSQVq7OoKpA_r0U6SScFAV8,35533
54
- moleditpy/plugins/File/animated_xyz_giffer.py,sha256=yCCgl9Gladki7eNJ6j-82dx8SloB6zwuzNvEHRTp2lo,20716
55
- moleditpy/plugins/File/cube_viewer.py,sha256=_An7KX89FIxbCF7WJbbNiZXKZPfC55NCfT7Y-7suxx8,24836
56
- moleditpy/plugins/File/gaussian_fchk_freq_analyzer.py,sha256=tBQs8xQYIPWab26G2tpadoW4rqYcDSuXaR4a3HaFATs,45152
57
- moleditpy/plugins/File/mapped_cube_viewer.py,sha256=tO1hbjXG2xp0pRXmwVBNCO0c0HUu1HU7zIFJ4S7buls,19557
58
- moleditpy/plugins/File/orca_out_freq_analyzer.py,sha256=6opjTpcK3B2XUIPk8fpOKlZ_IjaBCNZAREYOO3OJsuk,48219
59
- moleditpy/plugins/File/paste_xyz.py,sha256=kV-_CMmXLcqMIyFNRAeiwsOECPE64GCizT3hDCNfaXk,15112
60
- moleditpy/plugins/Input Generator/gaussian_input_generator_neo.py,sha256=3EXzxcxmJmgxVF9F-jFOPYJksubUdxZxvmNoUx7DTW4,37769
61
- moleditpy/plugins/Input Generator/orca_input_generator_neo.py,sha256=vqMpwJ9NaUw2SLcSqgIhWpdUaaJjnBvWHc4S0vtA7FI,40013
62
- moleditpy/plugins/Input Generator/orca_xyz2inp_gui.py,sha256=6d6v_UC9s-2bJihGqCX3usIplw-lOUVq96kEBf32S3g,11045
63
- moleditpy/plugins/Optimization/all-trans_optimizer.py,sha256=_7zAnYIRShPquIOFUf8_5N1o0g7iIXKFmcD0Eey8Lac,2532
64
- moleditpy/plugins/Optimization/complex_molecule_untangler.py,sha256=kGJ1nIWdLCcSxmKJOHLhTW4SAQSrESMkKsILeDqKbhA,10837
65
- moleditpy/plugins/Optimization/conf_search.py,sha256=equ6W02Yf2DAYSj1jSNeVrQSYPPpdlNrPDt3lm_Bek8,9110
66
- moleditpy/plugins/Utility/atom_colorizer.py,sha256=BUO-EkIeWwkGE6DtOuXgw0QkDABet_YfNXfpPZFWBlQ,9936
67
- moleditpy/plugins/Utility/console.py,sha256=4_WgDiEHhalDFOLJGmYNRa1odzxdtg46qr9DUz_ht4I,5943
68
- moleditpy/plugins/Utility/pubchem_ressolver.py,sha256=w1Zfm_2LTDhuU6uYKQSSaGpyU36-14kvDssc0L8hsDc,10048
69
- moleditpy/plugins/Utility/vdw_radii_overlay.py,sha256=C7cD82AiJIeaQk12gKjIt0oneJny2fDRAbw-t01vpEg,16533
70
- moleditpy-2.2.0a2.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
71
- moleditpy-2.2.0a2.dist-info/METADATA,sha256=0pjsuxHg7SWfSJWfdNf-0zi2R5j4fbG0s8KSPYWeE3s,59277
72
- moleditpy-2.2.0a2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
73
- moleditpy-2.2.0a2.dist-info/entry_points.txt,sha256=yH1h9JjALhok1foXT3-hYrC4ufoZt8b7oiBcsdnGNNM,54
74
- moleditpy-2.2.0a2.dist-info/top_level.txt,sha256=ARICrS4ihlPXqywlKl6o-oJa3Qz3gZRWu_VZsQ3_c44,10
75
- moleditpy-2.2.0a2.dist-info/RECORD,,
53
+ moleditpy-2.2.0a3.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
54
+ moleditpy-2.2.0a3.dist-info/METADATA,sha256=7GT1-GCaoevIBcSCUeQoXqwxNQRMlldgIVXHg9zOg3c,59277
55
+ moleditpy-2.2.0a3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
56
+ moleditpy-2.2.0a3.dist-info/entry_points.txt,sha256=yH1h9JjALhok1foXT3-hYrC4ufoZt8b7oiBcsdnGNNM,54
57
+ moleditpy-2.2.0a3.dist-info/top_level.txt,sha256=ARICrS4ihlPXqywlKl6o-oJa3Qz3gZRWu_VZsQ3_c44,10
58
+ moleditpy-2.2.0a3.dist-info/RECORD,,