babelplot 2026.1__tar.gz → 2026.2__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 (44) hide show
  1. {babelplot-2026.1 → babelplot-2026.2}/PKG-INFO +1 -1
  2. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/catalog/matplotlib_.py +4 -16
  3. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/catalog/vedo_.py +7 -13
  4. babelplot-2026.2/package/babelplot/constant/html_.py +39 -0
  5. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/constant/path.py +0 -1
  6. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/task/showing.py +10 -39
  7. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/backend.py +1 -1
  8. babelplot-2026.2/package/babelplot/version.py +1 -0
  9. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot.egg-info/PKG-INFO +1 -1
  10. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot.egg-info/SOURCES.txt +2 -1
  11. babelplot-2026.1/package/babelplot/version.py +0 -1
  12. {babelplot-2026.1 → babelplot-2026.2}/MANIFEST.in +0 -0
  13. {babelplot-2026.1 → babelplot-2026.2}/README-COPYRIGHT-utf8.txt +0 -0
  14. {babelplot-2026.1 → babelplot-2026.2}/README-LICENCE-utf8.txt +0 -0
  15. {babelplot-2026.1 → babelplot-2026.2}/README-template.rst +0 -0
  16. {babelplot-2026.1 → babelplot-2026.2}/README.rst +0 -0
  17. {babelplot-2026.1 → babelplot-2026.2}/documentation/wiki/description.asciidoc +0 -0
  18. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/__init__.py +0 -0
  19. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/api/type.py +0 -0
  20. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/catalog/bokeh_.py +0 -0
  21. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/catalog/plotly_.py +0 -0
  22. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/helper/creation.py +0 -0
  23. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/backend/helper/validation.py +0 -0
  24. {babelplot-2026.1/package/babelplot/constant → babelplot-2026.2/package/babelplot/config}/backend.py +0 -0
  25. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/constant/project.py +0 -0
  26. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/extension/enum_.py +0 -0
  27. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/runtime/backends.py +0 -0
  28. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/task/help.py +0 -0
  29. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/task/instantiation.py +0 -0
  30. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/task/plotting.py +0 -0
  31. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/dimension.py +0 -0
  32. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/ffp_base.py +0 -0
  33. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/figure.py +0 -0
  34. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/frame.py +0 -0
  35. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/plot.py +0 -0
  36. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/plot_function.py +0 -0
  37. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/plot_type.py +0 -0
  38. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot/type/translator.py +0 -0
  39. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot.egg-info/dependency_links.txt +0 -0
  40. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot.egg-info/requires.txt +0 -0
  41. {babelplot-2026.1 → babelplot-2026.2}/package/babelplot.egg-info/top_level.txt +0 -0
  42. {babelplot-2026.1 → babelplot-2026.2}/pyproject.toml +0 -0
  43. {babelplot-2026.1 → babelplot-2026.2}/setup.cfg +0 -0
  44. {babelplot-2026.1 → babelplot-2026.2}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: babelplot
3
- Version: 2026.1
3
+ Version: 2026.2
4
4
  Summary: A Meta Plotting Library That Speaks Several Backends
5
5
  Home-page: https://src.koda.cnrs.fr/eric.debreuve/babelplot/
6
6
  Author: Eric Debreuve
@@ -191,29 +191,17 @@ class figure_t(base_figure_t):
191
191
 
192
192
  def _BackendShow(self, modal: bool, /) -> None:
193
193
  """"""
194
- self.raw.show()
195
-
196
194
  if modal:
197
195
  if "qt" in mtpl.get_backend().lower():
196
+ # TODO: Is this distinction necessary?
198
197
  from matplotlib.backends.qt_compat import QtWidgets # noqa
199
198
 
200
199
  application = QtWidgets.QApplication.instance()
201
200
  application.exec()
202
201
  else:
203
- event_manager = self.raw.canvas
204
- event_manager.mpl_connect("close_event", _OnCloseEvent)
205
- event_manager.start_event_loop()
206
-
207
-
208
- def _OnCloseEvent(event: h.Any, /) -> None:
209
- """"""
210
- event.canvas.stop_event_loop()
211
-
212
- figures = tuple(map(pypl.figure, pypl.get_fignums()))
213
- if figures.__len__() > 0:
214
- event_manager = figures[0].canvas
215
- event_manager.mpl_connect("close_event", _OnCloseEvent)
216
- event_manager.start_event_loop()
202
+ pypl.show()
203
+ else:
204
+ self.raw.show()
217
205
 
218
206
 
219
207
  def _Arrows2(frame: backend_frame_2d_t, *args, **kwargs) -> backend_plot_t:
@@ -6,7 +6,6 @@ at project source root.
6
6
 
7
7
  import dataclasses as d
8
8
  import typing as h
9
- from multiprocessing import Process as process_t
10
9
 
11
10
  from color_spec_changer import NewTranslatedColor
12
11
  from numpy import ndarray as array_t
@@ -86,18 +85,13 @@ class figure_t(base_figure_t):
86
85
 
87
86
  def _BackendShow(self, modal: bool, /) -> None:
88
87
  """"""
89
- _ShowAndClose = lambda: BackendShow(
90
- self.backend_plots_s, shape=self.shape, sharecam=False
91
- ).close()
92
-
93
- # Passing [...].close shows the figures one by one. Using _ShowAndClose instead.
94
- process = process_t(target=_ShowAndClose)
95
- process.start()
96
-
97
- if modal:
98
- process.join()
99
- else:
100
- self.showing_process = process
88
+ BackendShow(
89
+ self.backend_plots_s,
90
+ shape=self.shape,
91
+ sharecam=False,
92
+ new=True,
93
+ interactive=modal,
94
+ )
101
95
 
102
96
 
103
97
  def _DefaultFunction(type_: plot_e, frame_dim: int, /) -> plot_function_h:
@@ -0,0 +1,39 @@
1
+ """
2
+ SEE COPYRIGHT, LICENCE, and DOCUMENTATION NOTICES: files
3
+ README-COPYRIGHT-utf8.txt, README-LICENCE-utf8.txt, and README-DOCUMENTATION-utf8.txt
4
+ at project source root.
5
+ """
6
+
7
+ TOO_BIG_OF_AN_HTML = 5_000_000
8
+
9
+ PATIENCE = """
10
+ <!DOCTYPE html>
11
+ <html>
12
+ <head>
13
+ <style>
14
+ html, body {
15
+ height: 100%;
16
+ }
17
+ div {
18
+ width: 100%;
19
+ height: 100%;
20
+ display: table;
21
+ text-align: center;
22
+ }
23
+ p {
24
+ display: table-cell;
25
+ vertical-align: middle;
26
+ font-size: 4vw;
27
+ font-weight: bold;
28
+ font-family: monospace;
29
+ color: darkgrey;
30
+ }
31
+ </style>
32
+ </head>
33
+ <body>
34
+ <div>
35
+ <p>Preparing Plot...</p>
36
+ <div/>
37
+ </body>
38
+ </html>
39
+ """
@@ -5,4 +5,3 @@ at project source root.
5
5
  """
6
6
 
7
7
  BACKEND_CATALOG_PY_PATH = "babelplot.backend.catalog"
8
- QT_RUNTIME_PY_PATH = "babelplot.runtime.application"
@@ -11,47 +11,15 @@ import tempfile as tmpf
11
11
  import time
12
12
  import typing as h
13
13
 
14
- from PyQt6.QtCore import QUrl as url_t # noqa
15
- from PyQt6.QtWebEngineWidgets import QWebEngineView as web_view_t # noqa
16
- from PyQt6.QtWidgets import QApplication as application_t # noqa
17
- from PyQt6.QtWidgets import QStackedWidget as stack_t # noqa
14
+ from PyQt6.QtCore import QUrl as url_t
15
+ from PyQt6.QtWebEngineWidgets import QWebEngineView as web_view_t
16
+ from PyQt6.QtWidgets import QApplication as application_t
17
+ from PyQt6.QtWidgets import QStackedWidget as stack_t
18
18
 
19
+ from ..constant.html_ import PATIENCE, TOO_BIG_OF_AN_HTML
19
20
  from ..constant.project import NAME
20
21
  from ..type.figure import figure_t
21
22
 
22
- TOO_BIG_OF_AN_HTML = 5_000_000
23
- PATIENCE = """
24
- <!DOCTYPE html>
25
- <html>
26
- <head>
27
- <style>
28
- html, body {
29
- height: 100%;
30
- }
31
- div {
32
- width: 100%;
33
- height: 100%;
34
- display: table;
35
- text-align: center;
36
- }
37
- p {
38
- display: table-cell;
39
- vertical-align: middle;
40
- font-size: 4vw;
41
- font-weight: bold;
42
- font-family: monospace;
43
- color: darkgrey;
44
- }
45
- </style>
46
- </head>
47
- <body>
48
- <div>
49
- <p>Preparing Plot...</p>
50
- <div/>
51
- </body>
52
- </html>
53
- """
54
-
55
23
 
56
24
  def ShowHTMLPlotWithPyQt(html: str | bytes, /) -> None:
57
25
  """"""
@@ -114,13 +82,16 @@ def ShowFigures(figures: h.Sequence[figure_t], /) -> None:
114
82
  figure.Show(modal=False)
115
83
  figures[0].Show(modal=True)
116
84
 
117
- still_running = tuple(_ for _ in figures if _.showing_process is not None)
85
+ still_running = tuple(
86
+ _.showing_process for _ in figures if _.showing_process is not None
87
+ )
118
88
  if still_running.__len__() == 0:
119
89
  return
120
90
 
121
91
  while still_running.__len__() > 0:
122
92
  time.sleep(0.1)
123
- still_running = tuple(_ for _ in still_running if _.showing_process.is_alive())
93
+ still_running = tuple(_ for _ in still_running if _.is_alive())
94
+ print("++++", "STILL RUNING", still_running)
124
95
 
125
96
  for figure in figures:
126
97
  figure.showing_process = None
@@ -14,7 +14,7 @@ from pathlib import Path as path_t
14
14
 
15
15
  from ft_logger import L
16
16
 
17
- from ..constant.backend import BACKEND_FROM_ALIAS, DEFAULT_BACKEND
17
+ from ..config.backend import BACKEND_FROM_ALIAS, DEFAULT_BACKEND
18
18
  from ..constant.path import BACKEND_CATALOG_PY_PATH
19
19
  from .plot_function import plot_function_h, plot_functions_h
20
20
  from .plot_type import plot_e, plot_type_h
@@ -0,0 +1 @@
1
+ __version__ = "2026.2"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: babelplot
3
- Version: 2026.1
3
+ Version: 2026.2
4
4
  Summary: A Meta Plotting Library That Speaks Several Backends
5
5
  Home-page: https://src.koda.cnrs.fr/eric.debreuve/babelplot/
6
6
  Author: Eric Debreuve
@@ -20,7 +20,8 @@ package/babelplot/backend/catalog/plotly_.py
20
20
  package/babelplot/backend/catalog/vedo_.py
21
21
  package/babelplot/backend/helper/creation.py
22
22
  package/babelplot/backend/helper/validation.py
23
- package/babelplot/constant/backend.py
23
+ package/babelplot/config/backend.py
24
+ package/babelplot/constant/html_.py
24
25
  package/babelplot/constant/path.py
25
26
  package/babelplot/constant/project.py
26
27
  package/babelplot/extension/enum_.py
@@ -1 +0,0 @@
1
- __version__ = "2026.1"
File without changes
File without changes
File without changes
File without changes
File without changes