MoleditPy-linux 4.4.0__tar.gz → 4.4.1__tar.gz

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 (81) hide show
  1. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/PKG-INFO +3 -3
  2. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/README.md +2 -2
  3. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/pyproject.toml +1 -1
  4. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/PKG-INFO +3 -3
  5. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/compute_logic.py +5 -1
  6. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/molecular_scene_handler.py +3 -2
  7. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/LICENSE +0 -0
  8. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/setup.cfg +0 -0
  9. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/SOURCES.txt +0 -0
  10. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/dependency_links.txt +0 -0
  11. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/entry_points.txt +0 -0
  12. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/requires.txt +0 -0
  13. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/MoleditPy_linux.egg-info/top_level.txt +0 -0
  14. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/__init__.py +0 -0
  15. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/__main__.py +0 -0
  16. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/assets/file_icon.ico +0 -0
  17. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/assets/icon.icns +0 -0
  18. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/assets/icon.ico +0 -0
  19. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/assets/icon.png +0 -0
  20. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/core/__init__.py +0 -0
  21. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/core/mol_geometry.py +0 -0
  22. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/core/molecular_data.py +0 -0
  23. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/main.py +0 -0
  24. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/plugins/__init__.py +0 -0
  25. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/plugins/plugin_interface.py +0 -0
  26. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/plugins/plugin_manager.py +0 -0
  27. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/plugins/plugin_manager_window.py +0 -0
  28. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/__init__.py +0 -0
  29. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/about_dialog.py +0 -0
  30. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/align_plane_dialog.py +0 -0
  31. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/alignment_dialog.py +0 -0
  32. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/analysis_window.py +0 -0
  33. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/angle_dialog.py +0 -0
  34. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/app_state.py +0 -0
  35. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/atom_item.py +0 -0
  36. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/atom_picking.py +0 -0
  37. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/base_picking_dialog.py +0 -0
  38. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/bond_item.py +0 -0
  39. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/bond_length_dialog.py +0 -0
  40. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/calculation_worker.py +0 -0
  41. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/color_settings_dialog.py +0 -0
  42. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/constrained_optimization_dialog.py +0 -0
  43. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/custom_interactor_style.py +0 -0
  44. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/custom_qt_interactor.py +0 -0
  45. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/dialog_3d_picking_mixin.py +0 -0
  46. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/dialog_logic.py +0 -0
  47. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/dihedral_dialog.py +0 -0
  48. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/edit_3d_logic.py +0 -0
  49. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/edit_actions_logic.py +0 -0
  50. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/export_logic.py +0 -0
  51. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/geometry_base_dialog.py +0 -0
  52. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/io_logic.py +0 -0
  53. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/main_window.py +0 -0
  54. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/main_window_init.py +0 -0
  55. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/mirror_dialog.py +0 -0
  56. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/molecule_scene.py +0 -0
  57. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/move_group_dialog.py +0 -0
  58. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/move_selected_atoms_dialog.py +0 -0
  59. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/periodic_table_dialog.py +0 -0
  60. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/planarize_dialog.py +0 -0
  61. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/plugin_menu_manager.py +0 -0
  62. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_dialog.py +0 -0
  63. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_tabs/__init__.py +0 -0
  64. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_tabs/settings_2d_tab.py +0 -0
  65. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_tabs/settings_3d_tabs.py +0 -0
  66. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_tabs/settings_other_tab.py +0 -0
  67. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/settings_tabs/settings_tab_base.py +0 -0
  68. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/string_importers.py +0 -0
  69. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/template_preview_item.py +0 -0
  70. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/template_preview_view.py +0 -0
  71. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/translation_dialog.py +0 -0
  72. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/ui_manager.py +0 -0
  73. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/user_template_dialog.py +0 -0
  74. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/view_3d_logic.py +0 -0
  75. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/ui/zoomable_view.py +0 -0
  76. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/__init__.py +0 -0
  77. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/constants.py +0 -0
  78. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/default_settings.py +0 -0
  79. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/sip_isdeleted_safe.py +0 -0
  80. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/suppress_log.py +0 -0
  81. {moleditpy_linux-4.4.0 → moleditpy_linux-4.4.1}/src/moleditpy_linux/utils/system_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: MoleditPy-linux
3
- Version: 4.4.0
3
+ Version: 4.4.1
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
@@ -757,7 +757,7 @@ This application combines a modern GUI built with **PyQt6**, powerful cheminform
757
757
  * **Mirror:** Create a mirror image of the molecule across a selected plane (XY, XZ, or YZ).
758
758
  * **Set Bond Length, Angle, & Dihedral Angle:** Set precise numerical values for distances, angles, and torsional angles.
759
759
  * **Constrained Optimization:** Perform force field optimization (MMFF/UFF) while applying fixed constraints to specific distances, angles, or dihedral angles.
760
- * **3D Measurement Tools:** A dedicated "Measure" mode allows you to click on atoms in the 3D view to instantly measure and display:
760
+ * **3D Measurement Tools:** The "Select" mode allows you to click on atoms in the 3D view to instantly measure and display:
761
761
  * **Distance** (between 2 atoms)
762
762
  * **Angle** (between 3 atoms)
763
763
  * **Dihedral Angle** (between 4 atoms)
@@ -893,7 +893,7 @@ Additionally, please cite the plugins you used.
893
893
  * **鏡像作成:** 選択した平面 (XY, XZ, YZ) に対して分子の鏡像を作成します。
894
894
  * **結合長・角度・二面角:** 原子を選択し、目標値を入力することで、距離、角度、ねじれ角を正確に設定します。
895
895
  * **制約付き最適化:** 特定の距離、角度、二面角を固定したまま、力場計算 (MMFF/UFF) による構造最適化を実行します。
896
- * **3D測定ツール:** 専用の「Measure」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
896
+ * **3D測定ツール:** 「Select」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
897
897
  * **距離** (2原子間)
898
898
  * **角度** (3原子間)
899
899
  * **二面角** (4原子間)
@@ -54,7 +54,7 @@ This application combines a modern GUI built with **PyQt6**, powerful cheminform
54
54
  * **Mirror:** Create a mirror image of the molecule across a selected plane (XY, XZ, or YZ).
55
55
  * **Set Bond Length, Angle, & Dihedral Angle:** Set precise numerical values for distances, angles, and torsional angles.
56
56
  * **Constrained Optimization:** Perform force field optimization (MMFF/UFF) while applying fixed constraints to specific distances, angles, or dihedral angles.
57
- * **3D Measurement Tools:** A dedicated "Measure" mode allows you to click on atoms in the 3D view to instantly measure and display:
57
+ * **3D Measurement Tools:** The "Select" mode allows you to click on atoms in the 3D view to instantly measure and display:
58
58
  * **Distance** (between 2 atoms)
59
59
  * **Angle** (between 3 atoms)
60
60
  * **Dihedral Angle** (between 4 atoms)
@@ -190,7 +190,7 @@ Additionally, please cite the plugins you used.
190
190
  * **鏡像作成:** 選択した平面 (XY, XZ, YZ) に対して分子の鏡像を作成します。
191
191
  * **結合長・角度・二面角:** 原子を選択し、目標値を入力することで、距離、角度、ねじれ角を正確に設定します。
192
192
  * **制約付き最適化:** 特定の距離、角度、二面角を固定したまま、力場計算 (MMFF/UFF) による構造最適化を実行します。
193
- * **3D測定ツール:** 専用の「Measure」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
193
+ * **3D測定ツール:** 「Select」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
194
194
  * **距離** (2原子間)
195
195
  * **角度** (3原子間)
196
196
  * **二面角** (4原子間)
@@ -5,7 +5,7 @@ build-backend = "setuptools.build_meta"
5
5
  [project]
6
6
  name = "MoleditPy-linux"
7
7
 
8
- version = "4.4.0"
8
+ version = "4.4.1"
9
9
 
10
10
  license = {file = "LICENSE"}
11
11
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: MoleditPy-linux
3
- Version: 4.4.0
3
+ Version: 4.4.1
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
@@ -757,7 +757,7 @@ This application combines a modern GUI built with **PyQt6**, powerful cheminform
757
757
  * **Mirror:** Create a mirror image of the molecule across a selected plane (XY, XZ, or YZ).
758
758
  * **Set Bond Length, Angle, & Dihedral Angle:** Set precise numerical values for distances, angles, and torsional angles.
759
759
  * **Constrained Optimization:** Perform force field optimization (MMFF/UFF) while applying fixed constraints to specific distances, angles, or dihedral angles.
760
- * **3D Measurement Tools:** A dedicated "Measure" mode allows you to click on atoms in the 3D view to instantly measure and display:
760
+ * **3D Measurement Tools:** The "Select" mode allows you to click on atoms in the 3D view to instantly measure and display:
761
761
  * **Distance** (between 2 atoms)
762
762
  * **Angle** (between 3 atoms)
763
763
  * **Dihedral Angle** (between 4 atoms)
@@ -893,7 +893,7 @@ Additionally, please cite the plugins you used.
893
893
  * **鏡像作成:** 選択した平面 (XY, XZ, YZ) に対して分子の鏡像を作成します。
894
894
  * **結合長・角度・二面角:** 原子を選択し、目標値を入力することで、距離、角度、ねじれ角を正確に設定します。
895
895
  * **制約付き最適化:** 特定の距離、角度、二面角を固定したまま、力場計算 (MMFF/UFF) による構造最適化を実行します。
896
- * **3D測定ツール:** 専用の「Measure」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
896
+ * **3D測定ツール:** 「Select」モードで3Dビュー内の原子をクリックするだけで、以下の値を即座に測定・表示します。
897
897
  * **距離** (2原子間)
898
898
  * **角度** (3原子間)
899
899
  * **二面角** (4原子間)
@@ -455,7 +455,8 @@ class ComputeManager:
455
455
  if item:
456
456
  item.has_problem = True
457
457
  item.update()
458
- self.host.init_manager.view_2d.setFocus()
458
+ # Defer so Qt finishes routing the modal result before restoring focus.
459
+ QTimer.singleShot(0, self.host.init_manager.view_2d.setFocus)
459
460
 
460
461
  def _setup_mol_block_for_worker(self, mol: Chem.Mol) -> str:
461
462
  mol_block = self.host.state_manager.data.to_mol_block()
@@ -617,6 +618,9 @@ class ComputeManager:
617
618
  with suppress_log(TypeError, RuntimeError):
618
619
  QMessageBox.critical(self.host, "Calculation Error", msg)
619
620
 
621
+ # Restore 2D editor focus so keyboard shortcuts remain active.
622
+ QTimer.singleShot(0, self.host.init_manager.view_2d.setFocus)
623
+
620
624
  def create_atom_id_mapping(self) -> None:
621
625
  """Map 2D atom IDs to 3D RDKit indices."""
622
626
  if not self.host.view_3d_manager.current_mol:
@@ -426,11 +426,12 @@ class TemplateMixin:
426
426
  else:
427
427
  angle_step = 2 * math.pi / n
428
428
  start_angle = -math.pi / 2 if n % 2 != 0 else -math.pi / 2 - angle_step / 2
429
+ circumradius = bond_len / (2 * math.sin(math.pi / n))
429
430
  points = [
430
431
  pos
431
432
  + QPointF(
432
- bond_len * math.cos(start_angle + i * angle_step),
433
- bond_len * math.sin(start_angle + i * angle_step),
433
+ circumradius * math.cos(start_angle + i * angle_step),
434
+ circumradius * math.sin(start_angle + i * angle_step),
434
435
  )
435
436
  for i in range(n)
436
437
  ]
File without changes