PythonQwt 0.12.1__py3-none-any.whl → 0.12.2__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.
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/METADATA +5 -8
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/RECORD +42 -42
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/WHEEL +1 -1
- qwt/__init__.py +19 -19
- qwt/_math.py +6 -6
- qwt/column_symbol.py +3 -5
- qwt/dyngrid_layout.py +1 -1
- qwt/legend.py +9 -8
- qwt/null_paintdevice.py +1 -1
- qwt/painter.py +0 -1
- qwt/painter_command.py +2 -1
- qwt/plot.py +1 -1
- qwt/plot_curve.py +2 -1
- qwt/plot_grid.py +5 -5
- qwt/plot_layout.py +8 -2
- qwt/plot_marker.py +7 -9
- qwt/plot_series.py +2 -3
- qwt/qthelpers.py +0 -1
- qwt/scale_div.py +2 -2
- qwt/scale_engine.py +7 -8
- qwt/scale_widget.py +11 -9
- qwt/tests/__init__.py +8 -2
- qwt/tests/comparative_benchmarks.py +1 -1
- qwt/tests/test_cartesian.py +1 -2
- qwt/tests/test_cpudemo.py +8 -8
- qwt/tests/test_curvedemo1.py +3 -4
- qwt/tests/test_curvedemo2.py +3 -5
- qwt/tests/test_data.py +6 -6
- qwt/tests/test_errorbar.py +11 -6
- qwt/tests/test_eventfilter.py +1 -1
- qwt/tests/test_highdpi.py +36 -0
- qwt/tests/test_image.py +7 -8
- qwt/tests/test_logcurve.py +1 -1
- qwt/tests/test_mapdemo.py +4 -4
- qwt/tests/test_multidemo.py +2 -3
- qwt/tests/test_simple.py +2 -3
- qwt/tests/test_stylesheet.py +9 -0
- qwt/toqimage.py +1 -2
- qwt/transform.py +2 -2
- qwt/tests/conftest.py +0 -9
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/LICENSE +0 -0
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/entry_points.txt +0 -0
- {PythonQwt-0.12.1.dist-info → PythonQwt-0.12.2.dist-info}/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: PythonQwt
|
|
3
|
-
Version: 0.12.
|
|
3
|
+
Version: 0.12.2
|
|
4
4
|
Summary: Qt plotting widgets for Python
|
|
5
5
|
Author-email: Pierre Raybaut <pierre.raybaut@gmail.com>
|
|
6
6
|
License: PythonQwt License Agreement
|
|
@@ -686,11 +686,10 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
686
686
|
Requires-Python: <4,>=3.8
|
|
687
687
|
Description-Content-Type: text/markdown
|
|
688
688
|
License-File: LICENSE
|
|
689
|
-
Requires-Dist: NumPy
|
|
689
|
+
Requires-Dist: NumPy <2,>=1.21
|
|
690
690
|
Requires-Dist: QtPy >=1.9
|
|
691
691
|
Provides-Extra: dev
|
|
692
|
-
Requires-Dist:
|
|
693
|
-
Requires-Dist: isort ; extra == 'dev'
|
|
692
|
+
Requires-Dist: ruff ; extra == 'dev'
|
|
694
693
|
Requires-Dist: pylint ; extra == 'dev'
|
|
695
694
|
Requires-Dist: Coverage ; extra == 'dev'
|
|
696
695
|
Provides-Extra: doc
|
|
@@ -699,8 +698,6 @@ Requires-Dist: sphinx >6 ; extra == 'doc'
|
|
|
699
698
|
Requires-Dist: python-docs-theme ; extra == 'doc'
|
|
700
699
|
Provides-Extra: test
|
|
701
700
|
Requires-Dist: pytest ; extra == 'test'
|
|
702
|
-
Requires-Dist: pytest-cov ; extra == 'test'
|
|
703
|
-
Requires-Dist: pytest-qt ; extra == 'test'
|
|
704
701
|
Requires-Dist: pytest-xvfb ; extra == 'test'
|
|
705
702
|
|
|
706
703
|
# PythonQwt: Qt plotting widgets for Python
|
|
@@ -714,7 +711,7 @@ Requires-Dist: pytest-xvfb ; extra == 'test'
|
|
|
714
711
|
|
|
715
712
|
ℹ️ Created in 2014 by Pierre Raybaut and maintained by the [PlotPyStack](https://github.com/PlotPyStack) organization.
|
|
716
713
|
|
|
717
|
-

|
|
714
|
+

|
|
718
715
|
|
|
719
716
|
The `PythonQwt` project was initiated to solve -at least temporarily- the
|
|
720
717
|
obsolescence issue of `PyQwt` (the Python-Qwt C++ bindings library) which is
|
|
@@ -810,7 +807,7 @@ The `qwt` package short-term roadmap is the following:
|
|
|
810
807
|
|
|
811
808
|
### Optional dependencies
|
|
812
809
|
|
|
813
|
-
- coverage, pytest
|
|
810
|
+
- coverage, pytest (for unit tests)
|
|
814
811
|
- sphinx (for documentation generation)
|
|
815
812
|
|
|
816
813
|
## Installation
|
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
qwt/__init__.py,sha256=
|
|
2
|
-
qwt/_math.py,sha256=
|
|
1
|
+
qwt/__init__.py,sha256=qmUZ7PCUne03V_hvXxEy8GeqCG0utEIYPa96Zz2xavg,5917
|
|
2
|
+
qwt/_math.py,sha256=Y4qZ0b3RPSliSUdeqVvR8wJ6tqVIAmqyN1Vldrz1UGg,1576
|
|
3
3
|
qwt/color_map.py,sha256=D8hCwm6u88vqlDDYd8Cw9H24DDbgv7-3DYmsmu1w_g4,11733
|
|
4
|
-
qwt/column_symbol.py,sha256=
|
|
5
|
-
qwt/dyngrid_layout.py,sha256=
|
|
4
|
+
qwt/column_symbol.py,sha256=d25qz_LtVODQ8sJz1SQXoctoSWqwwbL88kAoeaSMkUo,5716
|
|
5
|
+
qwt/dyngrid_layout.py,sha256=oIE88HSKmN25P4dhBBPfOQK-t4wRnG-IAKlzIDveEyY,13433
|
|
6
6
|
qwt/graphic.py,sha256=f6IcwY5uxJ3v13xvG0aaF8b8puyuLlB9Yy_ukw6Syj0,28051
|
|
7
7
|
qwt/interval.py,sha256=N3WrKihuS_VeYSRZxV8Lnp-5Ac39txumFcLHcnDrTTQ,12722
|
|
8
|
-
qwt/legend.py,sha256=
|
|
9
|
-
qwt/null_paintdevice.py,sha256=
|
|
10
|
-
qwt/painter.py,sha256=
|
|
11
|
-
qwt/painter_command.py,sha256=
|
|
12
|
-
qwt/plot.py,sha256=
|
|
8
|
+
qwt/legend.py,sha256=Y8C5qxaEKnFqbPUxQqlbtEHgz6w_bMd3tNjSr_EPTik,31234
|
|
9
|
+
qwt/null_paintdevice.py,sha256=Hne_os_0ebWPSz66BsxUJsNOkxfVVxnLT5Q930EsnC0,9136
|
|
10
|
+
qwt/painter.py,sha256=UGh-MC_9qw3fNF9GJ_1xbcAkVG6hD5op7jg9M2CcIXI,16527
|
|
11
|
+
qwt/painter_command.py,sha256=b_uZb56YlzYFG3ZmB5ykjkBQQAadQD8epknsQSEai54,6957
|
|
12
|
+
qwt/plot.py,sha256=T0z-0t-4FexibCHMl1NmDxEx9dy5LHg3J0CU80Bs3pg,75777
|
|
13
13
|
qwt/plot_canvas.py,sha256=BxRz9EJtzmBEntKt-Wug7NIRwX391WxgcTgB3_rqFGo,30273
|
|
14
|
-
qwt/plot_curve.py,sha256=
|
|
14
|
+
qwt/plot_curve.py,sha256=2wKjSI-4vfyvVwEvC2esiXH8dATbAm8lQzH5VSSNKqI,37081
|
|
15
15
|
qwt/plot_directpainter.py,sha256=BKcHrYqKZJ7Y8bMKAlgV-Nmu7mpUue8d-_CSTVxW9Lw,10130
|
|
16
|
-
qwt/plot_grid.py,sha256=
|
|
17
|
-
qwt/plot_layout.py,sha256=
|
|
18
|
-
qwt/plot_marker.py,sha256=
|
|
16
|
+
qwt/plot_grid.py,sha256=w9JVrDruw69VMH9hUSnp28XHuQv6WzVn0Nhy6ZWff2A,16563
|
|
17
|
+
qwt/plot_layout.py,sha256=OZ37rC9xHmhl6R_jFGJFNWfqObbOF5dxRdVWbsHUwkM,46139
|
|
18
|
+
qwt/plot_marker.py,sha256=_n7JmVi9rO6fLfSKOG_Xc_gh9amFRhycMDObprAxJ7I,21240
|
|
19
19
|
qwt/plot_renderer.py,sha256=I4YvEDgA2CTEDq6bj_ptGI214R-QAc184Yp_x7yA-Cg,27166
|
|
20
|
-
qwt/plot_series.py,sha256=
|
|
21
|
-
qwt/qthelpers.py,sha256=
|
|
22
|
-
qwt/scale_div.py,sha256=
|
|
20
|
+
qwt/plot_series.py,sha256=Uvk5U8WzuLB4Rmtxg1LL79Kwtb3ow-yxFZSCBguCbtM,11038
|
|
21
|
+
qwt/qthelpers.py,sha256=0ocvS1zvEU_2YQBN99zuXtfmabcA3nl58EZzCycrEZ4,1457
|
|
22
|
+
qwt/scale_div.py,sha256=2Ay5mgduXgSm4OrDMcaEWIzenAiBuEASZRoX99PWEE4,9276
|
|
23
23
|
qwt/scale_draw.py,sha256=zAUhQ6xCbs0fc9YKfszX7GWdBLsazvS7AcQboju-_xc,37890
|
|
24
|
-
qwt/scale_engine.py,sha256=
|
|
24
|
+
qwt/scale_engine.py,sha256=h5GiwVAphx75DXzm9LCzjHoxz7INGSOYT97sjtGLcd8,29044
|
|
25
25
|
qwt/scale_map.py,sha256=WobkNna6_RPXYZjGK7gZLykNxN_kYnrcB6fEaWgnL2w,9182
|
|
26
|
-
qwt/scale_widget.py,sha256=
|
|
26
|
+
qwt/scale_widget.py,sha256=RyPD4Hx-ID2O8ibhJrKY0ndLRA3NjVHPOGRIVC5fBBA,27081
|
|
27
27
|
qwt/symbol.py,sha256=fJwxXcg4wrbi7JJ_PZzzG0CBxwo36KZEXosjXIQSVSY,40371
|
|
28
28
|
qwt/text.py,sha256=Z3qg6HBKqgCuTPhJ4VpKTqUBGbLtbPMJ-UBI9V6DAGI,42074
|
|
29
|
-
qwt/toqimage.py,sha256=
|
|
30
|
-
qwt/transform.py,sha256=
|
|
31
|
-
qwt/tests/__init__.py,sha256=
|
|
32
|
-
qwt/tests/comparative_benchmarks.py,sha256=
|
|
33
|
-
qwt/tests/conftest.py,sha256=JHMXAgmHphJ8hWXjqVBBLxe0XlRb3rKOu9GRKVbcr_A,272
|
|
29
|
+
qwt/toqimage.py,sha256=H2u_qDt32n7HGZakWvs3Ve0G3u04Uk2ZQYp8MuZkkmU,1723
|
|
30
|
+
qwt/transform.py,sha256=XA5-y7k6odCFzuNaFcLcX3HX5J2pJrO47AdWkFtmv_0,5992
|
|
31
|
+
qwt/tests/__init__.py,sha256=BNCdp7BHS9JyrFgm-zW_m5Hexr8YxgqTOP-l-v57ZvU,1148
|
|
32
|
+
qwt/tests/comparative_benchmarks.py,sha256=nGhNjsA_pRG4W065fDFpyOQL36fMW6D5TCsLMU39Bhs,1883
|
|
34
33
|
qwt/tests/test_backingstore.py,sha256=HU9UQmElbQ6X5b3Nbpr8LtGURRZ0vPzhBJ3IlD1_LvA,547
|
|
35
34
|
qwt/tests/test_bodedemo.py,sha256=_ya6NroUuvGs0BaUcAGn8Adp0ek90JTDevfqN9ew_LE,9691
|
|
36
|
-
qwt/tests/test_cartesian.py,sha256=
|
|
37
|
-
qwt/tests/test_cpudemo.py,sha256=
|
|
35
|
+
qwt/tests/test_cartesian.py,sha256=5CJyC85P_YFF5iAIaAL6m7Nt1y1-_UDpZAbHKyIVAFk,3964
|
|
36
|
+
qwt/tests/test_cpudemo.py,sha256=vl_CmMwDSKyhwPztovqryRX265Owq52_G4HGJUBZZi4,13196
|
|
38
37
|
qwt/tests/test_curvebenchmark1.py,sha256=TNg5ZUZaXYDgy_XwlVP62fm4ePCZYbaepmBwaUoGOMc,5987
|
|
39
38
|
qwt/tests/test_curvebenchmark2.py,sha256=XBMzvKOkh54InjGEaTlzZtSBXyhZQoYfFXfejrFAMMI,2811
|
|
40
|
-
qwt/tests/test_curvedemo1.py,sha256=
|
|
41
|
-
qwt/tests/test_curvedemo2.py,sha256=
|
|
42
|
-
qwt/tests/test_data.py,sha256=
|
|
43
|
-
qwt/tests/test_errorbar.py,sha256=
|
|
44
|
-
qwt/tests/test_eventfilter.py,sha256=
|
|
45
|
-
qwt/tests/
|
|
39
|
+
qwt/tests/test_curvedemo1.py,sha256=hwHS6ceSqnvflhIuw_7Y05yroE8cDAvchubOgw3Dzd4,4309
|
|
40
|
+
qwt/tests/test_curvedemo2.py,sha256=IfZIuuIQk2pzOC15pMhzHkHzg9Ey4YvHmDpvP4CyVOY,4207
|
|
41
|
+
qwt/tests/test_data.py,sha256=c-rHb6wUrLK-8NJUI1fnf5c4G-gr0uypzYqCLy4C9EQ,3255
|
|
42
|
+
qwt/tests/test_errorbar.py,sha256=fEcQrMYAQBiHh5SWkBjFMJnQ_caf3hhzlLN26TzEXxA,11133
|
|
43
|
+
qwt/tests/test_eventfilter.py,sha256=sfsxeTb9ddb27rZzqdPBdQwMLkKXCaXTA4qeJwM1j7Q,16800
|
|
44
|
+
qwt/tests/test_highdpi.py,sha256=PJYSUjuf_Pqb7UsB43bi7cMQa2jBF-zjK0BayGbGqPM,1089
|
|
45
|
+
qwt/tests/test_image.py,sha256=IDScsN7Ii-uhNG3lMEXuDXSNQxdfbhr7-qnEMquyWJI,6753
|
|
46
46
|
qwt/tests/test_loadtest.py,sha256=z2rkUlWSOtFR2ENewKYP-PdomB_NBoqFjUL_UO8yxnc,1693
|
|
47
|
-
qwt/tests/test_logcurve.py,sha256=
|
|
48
|
-
qwt/tests/test_mapdemo.py,sha256=
|
|
49
|
-
qwt/tests/test_multidemo.py,sha256=
|
|
50
|
-
qwt/tests/test_simple.py,sha256=
|
|
51
|
-
qwt/tests/test_stylesheet.py,sha256=
|
|
47
|
+
qwt/tests/test_logcurve.py,sha256=X2HlDICDrTT7uHxCvRnzrhUnVwDiqFai8sKdlYmaLV4,1169
|
|
48
|
+
qwt/tests/test_mapdemo.py,sha256=8PigPTGhQcu1LapvtXCxebjgK78tOTRsD30-BqPpUnM,3529
|
|
49
|
+
qwt/tests/test_multidemo.py,sha256=Mtl_7l1S1g8QLzaP4cyTYHexFtQb-kzCrZwKX0DS_5Q,2609
|
|
50
|
+
qwt/tests/test_simple.py,sha256=BjbDpn8lkGa_2pWFktREdg1bhx1zbmAFXZSDU3ksvxw,2425
|
|
51
|
+
qwt/tests/test_stylesheet.py,sha256=7KxMwAVKVTriPCpgK0GvlEQjbWgULt_nGRHK4ogodqs,987
|
|
52
52
|
qwt/tests/test_symbols.py,sha256=JSusDGUV7Q6xxMLsINj9wYPGzg9RWf1cdIXKAqTR_us,5808
|
|
53
53
|
qwt/tests/test_vertical.py,sha256=lBRg8Dyig5xakM8sqnujiCNpDYGK2M-5jrCl5d6R3fU,3369
|
|
54
54
|
qwt/tests/utils.py,sha256=cZ_qBvLbK2MoH_ZcZfOqYQeWJ3tTMN6fLYwatIF6448,10810
|
|
@@ -74,9 +74,9 @@ qwt/tests/data/symbol.svg,sha256=UaJE-IbdgVejSV-WVGzkQf8qWHWXYL2gjglWeNRFg9Y,132
|
|
|
74
74
|
qwt/tests/data/symbols.png,sha256=wiqRBc2MJluJ-am9LtZ0K9DHV9BnreYMiEvfzJUFzCk,55586
|
|
75
75
|
qwt/tests/data/testlauncher.png,sha256=WmucObp30QYYKsVRBs5-6t1aEN0FbIWRmOVFN1gt-vQ,139676
|
|
76
76
|
qwt/tests/data/vertical.png,sha256=EvyG6q6rZm6pTT08Y_nzdBYCnqmoX1QDuEQtp2pyGlw,34076
|
|
77
|
-
PythonQwt-0.12.
|
|
78
|
-
PythonQwt-0.12.
|
|
79
|
-
PythonQwt-0.12.
|
|
80
|
-
PythonQwt-0.12.
|
|
81
|
-
PythonQwt-0.12.
|
|
82
|
-
PythonQwt-0.12.
|
|
77
|
+
PythonQwt-0.12.2.dist-info/LICENSE,sha256=qjEk8TRuXmFS7QC-omINvD1UPGqWaOs6CzcCZoMEhdI,33457
|
|
78
|
+
PythonQwt-0.12.2.dist-info/METADATA,sha256=71Z6Z-kVUS4YridJx4qrgk1eZ2f2lL512ewLIwfXTcE,45442
|
|
79
|
+
PythonQwt-0.12.2.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
80
|
+
PythonQwt-0.12.2.dist-info/entry_points.txt,sha256=pdPda-YcYigCi00hR4tMxWKu6byxM2x3zA8BQFDYvwI,46
|
|
81
|
+
PythonQwt-0.12.2.dist-info/top_level.txt,sha256=KB1IBdWRWnaItyJMaECwZiEi1jWt3IvqCrRVVhMjTu8,4
|
|
82
|
+
PythonQwt-0.12.2.dist-info/RECORD,,
|
qwt/__init__.py
CHANGED
|
@@ -27,36 +27,36 @@ External resources:
|
|
|
27
27
|
.. _GitHub: https://github.com/PlotPyStack/PythonQwt
|
|
28
28
|
"""
|
|
29
29
|
|
|
30
|
-
__version__ = "0.12.1"
|
|
31
|
-
QWT_VERSION_STR = "6.1.5"
|
|
32
|
-
|
|
33
30
|
import warnings
|
|
34
31
|
|
|
35
|
-
from qwt.color_map import QwtLinearColorMap
|
|
32
|
+
from qwt.color_map import QwtLinearColorMap # noqa: F401
|
|
36
33
|
from qwt.interval import QwtInterval
|
|
37
|
-
from qwt.legend import QwtLegend, QwtLegendData, QwtLegendLabel
|
|
38
|
-
from qwt.painter import QwtPainter
|
|
39
|
-
from qwt.plot import QwtPlot
|
|
40
|
-
from qwt.plot_canvas import QwtPlotCanvas
|
|
34
|
+
from qwt.legend import QwtLegend, QwtLegendData, QwtLegendLabel # noqa: F401
|
|
35
|
+
from qwt.painter import QwtPainter # noqa: F401
|
|
36
|
+
from qwt.plot import QwtPlot # noqa: F401
|
|
37
|
+
from qwt.plot_canvas import QwtPlotCanvas # noqa: F401
|
|
41
38
|
from qwt.plot_curve import QwtPlotCurve as QPC # see deprecated section
|
|
42
|
-
from qwt.plot_curve import QwtPlotItem
|
|
43
|
-
from qwt.plot_directpainter import QwtPlotDirectPainter
|
|
39
|
+
from qwt.plot_curve import QwtPlotItem # noqa: F401
|
|
40
|
+
from qwt.plot_directpainter import QwtPlotDirectPainter # noqa: F401
|
|
44
41
|
from qwt.plot_grid import QwtPlotGrid as QPG # see deprecated section
|
|
45
|
-
from qwt.plot_marker import QwtPlotMarker
|
|
46
|
-
from qwt.plot_renderer import QwtPlotRenderer
|
|
47
|
-
from qwt.plot_series import (
|
|
42
|
+
from qwt.plot_marker import QwtPlotMarker # noqa: F401
|
|
43
|
+
from qwt.plot_renderer import QwtPlotRenderer # noqa: F401
|
|
44
|
+
from qwt.plot_series import ( # noqa: F401
|
|
48
45
|
QwtPlotSeriesItem,
|
|
49
46
|
QwtPointArrayData,
|
|
50
47
|
QwtSeriesData,
|
|
51
48
|
QwtSeriesStore,
|
|
52
49
|
)
|
|
53
|
-
from qwt.scale_div import QwtScaleDiv
|
|
54
|
-
from qwt.scale_draw import QwtAbstractScaleDraw, QwtScaleDraw
|
|
55
|
-
from qwt.scale_engine import QwtLinearScaleEngine, QwtLogScaleEngine
|
|
56
|
-
from qwt.scale_map import QwtScaleMap
|
|
50
|
+
from qwt.scale_div import QwtScaleDiv # noqa: F401
|
|
51
|
+
from qwt.scale_draw import QwtAbstractScaleDraw, QwtScaleDraw # noqa: F401
|
|
52
|
+
from qwt.scale_engine import QwtLinearScaleEngine, QwtLogScaleEngine # noqa: F401
|
|
53
|
+
from qwt.scale_map import QwtScaleMap # noqa: F401
|
|
57
54
|
from qwt.symbol import QwtSymbol as QSbl # see deprecated section
|
|
58
|
-
from qwt.text import QwtText
|
|
59
|
-
from qwt.toqimage import array_to_qimage as toQImage
|
|
55
|
+
from qwt.text import QwtText # noqa: F401
|
|
56
|
+
from qwt.toqimage import array_to_qimage as toQImage # noqa: F401
|
|
57
|
+
|
|
58
|
+
__version__ = "0.12.2"
|
|
59
|
+
QWT_VERSION_STR = "6.1.5"
|
|
60
60
|
|
|
61
61
|
|
|
62
62
|
## ============================================================================
|
qwt/_math.py
CHANGED
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
# Copyright (c) 2015 Pierre Raybaut, for the Python translation/optimization
|
|
6
6
|
# (see LICENSE file for more details)
|
|
7
7
|
|
|
8
|
-
from qtpy.QtCore import qFuzzyCompare
|
|
9
|
-
|
|
10
8
|
import math
|
|
11
9
|
|
|
10
|
+
from qtpy.QtCore import qFuzzyCompare
|
|
11
|
+
|
|
12
12
|
|
|
13
13
|
def qwtFuzzyCompare(value1, value2, intervalSize):
|
|
14
14
|
eps = abs(1.0e-6 * intervalSize)
|
|
@@ -38,16 +38,16 @@ def qwtSign(x):
|
|
|
38
38
|
|
|
39
39
|
|
|
40
40
|
def qwtSqr(x):
|
|
41
|
-
return x
|
|
41
|
+
return x**2
|
|
42
42
|
|
|
43
43
|
|
|
44
44
|
def qwtFastAtan(x):
|
|
45
45
|
if x < -1.0:
|
|
46
|
-
return -0.5 * math.pi - x / (x
|
|
46
|
+
return -0.5 * math.pi - x / (x**2 + 0.28)
|
|
47
47
|
elif x > 1.0:
|
|
48
|
-
return 0.5 * math.pi - x / (x
|
|
48
|
+
return 0.5 * math.pi - x / (x**2 + 0.28)
|
|
49
49
|
else:
|
|
50
|
-
return x / (1.0 + x
|
|
50
|
+
return x / (1.0 + x**2 * 0.28)
|
|
51
51
|
|
|
52
52
|
|
|
53
53
|
def qwtFastAtan2(y, x):
|
qwt/column_symbol.py
CHANGED
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
# Copyright (c) 2015 Pierre Raybaut, for the Python translation/optimization
|
|
6
6
|
# (see LICENSE file for more details)
|
|
7
7
|
|
|
8
|
-
from
|
|
8
|
+
from qtpy.QtCore import QLineF, QRectF, Qt
|
|
9
|
+
from qtpy.QtGui import QPalette, QPolygonF
|
|
9
10
|
|
|
10
|
-
from
|
|
11
|
-
from qtpy.QtCore import QRectF, Qt, QLineF
|
|
11
|
+
from qwt.interval import QwtInterval
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
def qwtDrawBox(p, rect, pal, lw):
|
|
@@ -80,7 +80,6 @@ class QwtColumnSymbol_PrivateData(object):
|
|
|
80
80
|
|
|
81
81
|
|
|
82
82
|
class QwtColumnSymbol(object):
|
|
83
|
-
|
|
84
83
|
# enum Style
|
|
85
84
|
NoStyle = -1
|
|
86
85
|
Box = 0
|
|
@@ -134,7 +133,6 @@ class QwtColumnSymbol(object):
|
|
|
134
133
|
|
|
135
134
|
|
|
136
135
|
class QwtColumnRect(object):
|
|
137
|
-
|
|
138
136
|
# enum Direction
|
|
139
137
|
LeftToRight, RightToLeft, BottomToTop, TopToBottom = list(range(4))
|
|
140
138
|
|
qwt/dyngrid_layout.py
CHANGED
|
@@ -15,8 +15,8 @@ The `dyngrid_layout` module provides the `QwtDynGridLayout` class.
|
|
|
15
15
|
:members:
|
|
16
16
|
"""
|
|
17
17
|
|
|
18
|
+
from qtpy.QtCore import QRect, QSize, Qt
|
|
18
19
|
from qtpy.QtWidgets import QLayout
|
|
19
|
-
from qtpy.QtCore import Qt, QRect, QSize
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
class QwtDynGridLayout_PrivateData(object):
|
qwt/legend.py
CHANGED
|
@@ -21,22 +21,23 @@ QwtLegend
|
|
|
21
21
|
|
|
22
22
|
import math
|
|
23
23
|
|
|
24
|
+
from qtpy.QtCore import QEvent, QPoint, QRect, QRectF, QSize, Qt, Signal
|
|
25
|
+
|
|
26
|
+
# qDrawWinButton,
|
|
27
|
+
from qtpy.QtGui import QPainter, QPalette, QPixmap
|
|
24
28
|
from qtpy.QtWidgets import (
|
|
29
|
+
QApplication,
|
|
25
30
|
QFrame,
|
|
26
31
|
QScrollArea,
|
|
27
|
-
QWidget,
|
|
28
|
-
QVBoxLayout,
|
|
29
|
-
QApplication,
|
|
30
|
-
QStyleOption,
|
|
31
32
|
QStyle,
|
|
32
|
-
|
|
33
|
+
QStyleOption,
|
|
34
|
+
QVBoxLayout,
|
|
35
|
+
QWidget,
|
|
33
36
|
)
|
|
34
|
-
from qtpy.QtGui import QPalette, QPixmap, QPainter
|
|
35
|
-
from qtpy.QtCore import Signal, QEvent, QSize, Qt, QRect, QRectF, QPoint
|
|
36
37
|
|
|
37
|
-
from qwt.text import QwtText, QwtTextLabel
|
|
38
38
|
from qwt.dyngrid_layout import QwtDynGridLayout
|
|
39
39
|
from qwt.painter import QwtPainter
|
|
40
|
+
from qwt.text import QwtText, QwtTextLabel
|
|
40
41
|
|
|
41
42
|
|
|
42
43
|
class QwtLegendData(object):
|
qwt/null_paintdevice.py
CHANGED
qwt/painter.py
CHANGED
qwt/painter_command.py
CHANGED
qwt/plot.py
CHANGED
qwt/plot_curve.py
CHANGED
qwt/plot_grid.py
CHANGED
|
@@ -13,13 +13,13 @@ QwtPlotGrid
|
|
|
13
13
|
:members:
|
|
14
14
|
"""
|
|
15
15
|
|
|
16
|
-
from
|
|
17
|
-
from
|
|
16
|
+
from qtpy.QtCore import QLineF, Qt
|
|
17
|
+
from qtpy.QtGui import QPen
|
|
18
|
+
|
|
18
19
|
from qwt._math import qwtFuzzyGreaterOrEqual, qwtFuzzyLessOrEqual
|
|
20
|
+
from qwt.plot import QwtPlotItem
|
|
19
21
|
from qwt.qthelpers import qcolor_from_str
|
|
20
|
-
|
|
21
|
-
from qtpy.QtGui import QPen
|
|
22
|
-
from qtpy.QtCore import Qt, QLineF
|
|
22
|
+
from qwt.scale_div import QwtScaleDiv
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
class QwtPlotGrid_PrivateData(object):
|
qwt/plot_layout.py
CHANGED
|
@@ -136,7 +136,10 @@ class QwtPlotLayout_LayoutData(object):
|
|
|
136
136
|
if layout is not None:
|
|
137
137
|
mgn = layout.contentsMargins()
|
|
138
138
|
self.canvas.contentsMargins = [
|
|
139
|
-
mgn.left(),
|
|
139
|
+
mgn.left(),
|
|
140
|
+
mgn.top(),
|
|
141
|
+
mgn.right(),
|
|
142
|
+
mgn.bottom(),
|
|
140
143
|
]
|
|
141
144
|
|
|
142
145
|
|
|
@@ -575,7 +578,10 @@ class QwtPlotLayout(object):
|
|
|
575
578
|
else:
|
|
576
579
|
mgn = layout.contentsMargins()
|
|
577
580
|
left, top, right, bottom = (
|
|
578
|
-
mgn.left(),
|
|
581
|
+
mgn.left(),
|
|
582
|
+
mgn.top(),
|
|
583
|
+
mgn.right(),
|
|
584
|
+
mgn.bottom(),
|
|
579
585
|
)
|
|
580
586
|
for axis in QwtPlot.AXES:
|
|
581
587
|
if plot.axisEnabled(axis):
|
qwt/plot_marker.py
CHANGED
|
@@ -13,14 +13,14 @@ QwtPlotMarker
|
|
|
13
13
|
:members:
|
|
14
14
|
"""
|
|
15
15
|
|
|
16
|
-
from
|
|
17
|
-
from
|
|
16
|
+
from qtpy.QtCore import QLineF, QPointF, QRect, QRectF, QSizeF, Qt
|
|
17
|
+
from qtpy.QtGui import QPainter, QPen
|
|
18
|
+
|
|
18
19
|
from qwt.graphic import QwtGraphic
|
|
19
|
-
from qwt.
|
|
20
|
+
from qwt.plot import QwtPlot, QwtPlotItem
|
|
20
21
|
from qwt.qthelpers import qcolor_from_str
|
|
21
|
-
|
|
22
|
-
from
|
|
23
|
-
from qtpy.QtCore import Qt, QPointF, QRectF, QSizeF, QRect, QLineF
|
|
22
|
+
from qwt.symbol import QwtSymbol
|
|
23
|
+
from qwt.text import QwtText
|
|
24
24
|
|
|
25
25
|
|
|
26
26
|
class QwtPlotMarker_PrivateData(object):
|
|
@@ -240,9 +240,7 @@ class QwtPlotMarker(QwtPlotItem):
|
|
|
240
240
|
if self.__data.symbol and self.__data.symbol.style() != QwtSymbol.NoSymbol:
|
|
241
241
|
sz = self.__data.symbol.size()
|
|
242
242
|
width, height = int(sz.width()), int(sz.height())
|
|
243
|
-
clipRect = QRectF(
|
|
244
|
-
canvasRect.adjusted(-width, -height, width, height)
|
|
245
|
-
)
|
|
243
|
+
clipRect = QRectF(canvasRect.adjusted(-width, -height, width, height))
|
|
246
244
|
if clipRect.contains(pos):
|
|
247
245
|
self.__data.symbol.drawSymbols(painter, [pos])
|
|
248
246
|
self.drawLabel(painter, canvasRect, pos)
|
qwt/plot_series.py
CHANGED
|
@@ -20,7 +20,7 @@ QwtSeriesData
|
|
|
20
20
|
|
|
21
21
|
.. autoclass:: QwtSeriesData
|
|
22
22
|
:members:
|
|
23
|
-
|
|
23
|
+
|
|
24
24
|
QwtPointArrayData
|
|
25
25
|
~~~~~~~~~~~~~~~~~
|
|
26
26
|
|
|
@@ -35,12 +35,11 @@ QwtSeriesStore
|
|
|
35
35
|
"""
|
|
36
36
|
|
|
37
37
|
import numpy as np
|
|
38
|
+
from qtpy.QtCore import QPointF, QRectF, Qt
|
|
38
39
|
|
|
39
40
|
from qwt.plot import QwtPlotItem, QwtPlotItem_PrivateData
|
|
40
41
|
from qwt.text import QwtText
|
|
41
42
|
|
|
42
|
-
from qtpy.QtCore import Qt, QRectF, QPointF
|
|
43
|
-
|
|
44
43
|
|
|
45
44
|
class QwtPlotSeriesItem_PrivateData(QwtPlotItem_PrivateData):
|
|
46
45
|
def __init__(self):
|
qwt/qthelpers.py
CHANGED
qwt/scale_div.py
CHANGED
qwt/scale_engine.py
CHANGED
|
@@ -25,17 +25,16 @@ QwtLogScaleEngine
|
|
|
25
25
|
:members:
|
|
26
26
|
"""
|
|
27
27
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
from qwt.transform import QwtLogTransform
|
|
31
|
-
from qwt._math import qwtFuzzyCompare
|
|
32
|
-
from qwt.transform import QwtTransform
|
|
28
|
+
import math
|
|
29
|
+
import sys
|
|
33
30
|
|
|
31
|
+
import numpy as np
|
|
34
32
|
from qtpy.QtCore import qFuzzyCompare
|
|
35
33
|
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
|
|
34
|
+
from qwt._math import qwtFuzzyCompare
|
|
35
|
+
from qwt.interval import QwtInterval
|
|
36
|
+
from qwt.scale_div import QwtScaleDiv
|
|
37
|
+
from qwt.transform import QwtLogTransform, QwtTransform
|
|
39
38
|
|
|
40
39
|
DBL_MAX = sys.float_info.max
|
|
41
40
|
LOG_MIN = 1.0e-100
|
qwt/scale_widget.py
CHANGED
|
@@ -15,17 +15,16 @@ QwtScaleWidget
|
|
|
15
15
|
|
|
16
16
|
import math
|
|
17
17
|
|
|
18
|
+
from qtpy.QtCore import QRectF, QSize, Qt, Signal
|
|
19
|
+
from qtpy.QtGui import QPainter, QPalette
|
|
20
|
+
from qtpy.QtWidgets import QSizePolicy, QStyle, QStyleOption, QWidget
|
|
21
|
+
|
|
22
|
+
from qwt.color_map import QwtColorMap, QwtLinearColorMap
|
|
23
|
+
from qwt.interval import QwtInterval
|
|
24
|
+
from qwt.painter import QwtPainter
|
|
18
25
|
from qwt.scale_draw import QwtScaleDraw
|
|
19
26
|
from qwt.scale_engine import QwtLinearScaleEngine
|
|
20
|
-
from qwt.color_map import QwtLinearColorMap
|
|
21
27
|
from qwt.text import QwtText
|
|
22
|
-
from qwt.painter import QwtPainter
|
|
23
|
-
from qwt.interval import QwtInterval
|
|
24
|
-
from qwt.color_map import QwtColorMap
|
|
25
|
-
|
|
26
|
-
from qtpy.QtGui import QPainter, QPalette
|
|
27
|
-
from qtpy.QtWidgets import QWidget, QSizePolicy, QStyleOption, QStyle, QApplication
|
|
28
|
-
from qtpy.QtCore import Qt, QRectF, QSize, Signal, QEvent
|
|
29
28
|
|
|
30
29
|
|
|
31
30
|
class ColorBar(object):
|
|
@@ -639,7 +638,10 @@ class QwtScaleWidget(QWidget):
|
|
|
639
638
|
else:
|
|
640
639
|
mgn = self.layout().contentsMargins()
|
|
641
640
|
left, top, right, bottom = (
|
|
642
|
-
mgn.left(),
|
|
641
|
+
mgn.left(),
|
|
642
|
+
mgn.top(),
|
|
643
|
+
mgn.right(),
|
|
644
|
+
mgn.bottom(),
|
|
643
645
|
)
|
|
644
646
|
return size + QSize(left + right, top + bottom)
|
|
645
647
|
|
qwt/tests/__init__.py
CHANGED
|
@@ -9,10 +9,16 @@ PythonQwt test package
|
|
|
9
9
|
======================
|
|
10
10
|
"""
|
|
11
11
|
|
|
12
|
-
from qtpy import QtWidgets as QW
|
|
13
12
|
from qtpy import QtCore as QC
|
|
13
|
+
from qtpy import QtWidgets as QW
|
|
14
14
|
|
|
15
|
-
from qwt.tests.utils import
|
|
15
|
+
from qwt.tests.utils import (
|
|
16
|
+
QT_API,
|
|
17
|
+
TestEnvironment,
|
|
18
|
+
TestLauncher,
|
|
19
|
+
run_all_tests,
|
|
20
|
+
take_screenshot,
|
|
21
|
+
)
|
|
16
22
|
|
|
17
23
|
|
|
18
24
|
def run(wait=True):
|
qwt/tests/test_cartesian.py
CHANGED
|
@@ -9,10 +9,9 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
-
|
|
13
12
|
from qtpy.QtCore import Qt
|
|
14
13
|
|
|
15
|
-
from qwt import QwtPlot,
|
|
14
|
+
from qwt import QwtPlot, QwtPlotCurve, QwtPlotGrid, QwtPlotItem, QwtScaleDraw
|
|
16
15
|
from qwt.tests import utils
|
|
17
16
|
|
|
18
17
|
|
qwt/tests/test_cpudemo.py
CHANGED
|
@@ -9,20 +9,20 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import os
|
|
12
|
-
import numpy as np
|
|
13
12
|
|
|
14
|
-
|
|
15
|
-
from qtpy.
|
|
16
|
-
from qtpy.
|
|
13
|
+
import numpy as np
|
|
14
|
+
from qtpy.QtCore import QRect, Qt, QTime
|
|
15
|
+
from qtpy.QtGui import QBrush, QColor
|
|
16
|
+
from qtpy.QtWidgets import QLabel, QVBoxLayout, QWidget
|
|
17
17
|
|
|
18
18
|
from qwt import (
|
|
19
|
-
QwtPlot,
|
|
20
|
-
QwtPlotMarker,
|
|
21
|
-
QwtScaleDraw,
|
|
22
19
|
QwtLegend,
|
|
20
|
+
QwtLegendData,
|
|
21
|
+
QwtPlot,
|
|
23
22
|
QwtPlotCurve,
|
|
24
23
|
QwtPlotItem,
|
|
25
|
-
|
|
24
|
+
QwtPlotMarker,
|
|
25
|
+
QwtScaleDraw,
|
|
26
26
|
QwtText,
|
|
27
27
|
)
|
|
28
28
|
from qwt.tests import utils
|
qwt/tests/test_curvedemo1.py
CHANGED
|
@@ -9,12 +9,11 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
-
|
|
13
|
-
from qtpy.QtWidgets import QFrame
|
|
14
|
-
from qtpy.QtGui import QPen, QBrush, QFont, QPainter
|
|
15
12
|
from qtpy.QtCore import QSize, Qt
|
|
13
|
+
from qtpy.QtGui import QBrush, QFont, QPainter, QPen
|
|
14
|
+
from qtpy.QtWidgets import QFrame
|
|
16
15
|
|
|
17
|
-
from qwt import
|
|
16
|
+
from qwt import QwtPlotCurve, QwtPlotItem, QwtScaleMap, QwtSymbol
|
|
18
17
|
from qwt.tests import utils
|
|
19
18
|
|
|
20
19
|
|
qwt/tests/test_curvedemo2.py
CHANGED
|
@@ -9,13 +9,11 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
-
|
|
12
|
+
from qtpy.QtCore import QSize, Qt
|
|
13
|
+
from qtpy.QtGui import QBrush, QColor, QPainter, QPalette, QPen
|
|
13
14
|
from qtpy.QtWidgets import QFrame
|
|
14
|
-
from qtpy.QtGui import QPen, QBrush, QColor, QPainter, QPalette
|
|
15
|
-
from qtpy.QtCore import QSize
|
|
16
|
-
from qtpy.QtCore import Qt
|
|
17
15
|
|
|
18
|
-
from qwt import QwtScaleMap, QwtSymbol
|
|
16
|
+
from qwt import QwtPlotCurve, QwtScaleMap, QwtSymbol
|
|
19
17
|
from qwt.tests import utils
|
|
20
18
|
|
|
21
19
|
Size = 15
|
qwt/tests/test_data.py
CHANGED
|
@@ -9,19 +9,19 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import random
|
|
12
|
-
import numpy as np
|
|
13
12
|
|
|
14
|
-
|
|
15
|
-
from qtpy.QtGui import QPen, QBrush
|
|
13
|
+
import numpy as np
|
|
16
14
|
from qtpy.QtCore import QSize, Qt
|
|
15
|
+
from qtpy.QtGui import QBrush, QPen
|
|
16
|
+
from qtpy.QtWidgets import QFrame
|
|
17
17
|
|
|
18
18
|
from qwt import (
|
|
19
|
+
QwtAbstractScaleDraw,
|
|
20
|
+
QwtLegend,
|
|
19
21
|
QwtPlot,
|
|
22
|
+
QwtPlotCurve,
|
|
20
23
|
QwtPlotMarker,
|
|
21
24
|
QwtSymbol,
|
|
22
|
-
QwtLegend,
|
|
23
|
-
QwtPlotCurve,
|
|
24
|
-
QwtAbstractScaleDraw,
|
|
25
25
|
)
|
|
26
26
|
from qwt.tests import utils
|
|
27
27
|
|
qwt/tests/test_errorbar.py
CHANGED
|
@@ -9,11 +9,10 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
+
from qtpy.QtCore import QLineF, QRectF, QSize, Qt
|
|
13
|
+
from qtpy.QtGui import QBrush, QPen
|
|
12
14
|
|
|
13
|
-
from
|
|
14
|
-
from qtpy.QtCore import QSize, QRectF, QLineF, Qt
|
|
15
|
-
|
|
16
|
-
from qwt import QwtPlot, QwtSymbol, QwtPlotGrid, QwtPlotCurve
|
|
15
|
+
from qwt import QwtPlot, QwtPlotCurve, QwtPlotGrid, QwtSymbol
|
|
17
16
|
from qwt.tests import utils
|
|
18
17
|
|
|
19
18
|
|
|
@@ -199,7 +198,10 @@ class ErrorBarPlotCurve(QwtPlotCurve):
|
|
|
199
198
|
if self.errorCap > 0:
|
|
200
199
|
# draw the caps
|
|
201
200
|
cap = self.errorCap / 2
|
|
202
|
-
|
|
201
|
+
(
|
|
202
|
+
n,
|
|
203
|
+
i,
|
|
204
|
+
) = (
|
|
203
205
|
len(y),
|
|
204
206
|
0,
|
|
205
207
|
)
|
|
@@ -235,7 +237,10 @@ class ErrorBarPlotCurve(QwtPlotCurve):
|
|
|
235
237
|
ymin = self.__y - self.__dy[0]
|
|
236
238
|
ymax = self.__y + self.__dy[1]
|
|
237
239
|
x = self.__x
|
|
238
|
-
|
|
240
|
+
(
|
|
241
|
+
n,
|
|
242
|
+
i,
|
|
243
|
+
) = (
|
|
239
244
|
len(x),
|
|
240
245
|
0,
|
|
241
246
|
)
|
qwt/tests/test_eventfilter.py
CHANGED
|
@@ -12,7 +12,7 @@ import os
|
|
|
12
12
|
|
|
13
13
|
import numpy as np
|
|
14
14
|
from qtpy.QtCore import QEvent, QObject, QPoint, QRect, QSize, Qt, Signal
|
|
15
|
-
from qtpy.QtGui import QBrush, QColor, QPainter, QPen
|
|
15
|
+
from qtpy.QtGui import QBrush, QColor, QPainter, QPen
|
|
16
16
|
from qtpy.QtWidgets import QApplication, QMainWindow, QToolBar, QWhatsThis, QWidget
|
|
17
17
|
|
|
18
18
|
from qwt import (
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the terms of the PyQwt License
|
|
4
|
+
# Copyright (C) 2003-2009 Gerard Vermeulen, for the original PyQwt example
|
|
5
|
+
# Copyright (c) 2015 Pierre Raybaut, for the PyQt5/PySide port and further
|
|
6
|
+
# developments (e.g. ported to PythonQwt API)
|
|
7
|
+
# (see LICENSE file for more details)
|
|
8
|
+
|
|
9
|
+
SHOW = True # Show test in GUI-based test launcher
|
|
10
|
+
|
|
11
|
+
import os
|
|
12
|
+
|
|
13
|
+
import pytest
|
|
14
|
+
|
|
15
|
+
from qwt.tests import utils
|
|
16
|
+
from qwt.tests.test_simple import SimplePlot
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class HighDPIPlot(SimplePlot):
|
|
20
|
+
NUM_POINTS = 5000000 # 5 million points needed to test high DPI support
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
@pytest.mark.skip(reason="This test is not relevant for the automated test suite")
|
|
24
|
+
def test_highdpi():
|
|
25
|
+
"""Test high DPI support"""
|
|
26
|
+
|
|
27
|
+
# Performance should be the same with "1" and "2" scale factors:
|
|
28
|
+
# (as of today, this is not the case, but it has to be fixed in the future:
|
|
29
|
+
# https://github.com/PlotPyStack/PythonQwt/issues/83)
|
|
30
|
+
os.environ["QT_SCALE_FACTOR"] = "2"
|
|
31
|
+
|
|
32
|
+
utils.test_widget(HighDPIPlot, (800, 480))
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
if __name__ == "__main__":
|
|
36
|
+
test_highdpi()
|
qwt/tests/test_image.py
CHANGED
|
@@ -9,20 +9,19 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
-
|
|
13
|
-
from qtpy.QtGui import QPen, qRgb
|
|
14
12
|
from qtpy.QtCore import Qt
|
|
13
|
+
from qtpy.QtGui import QPen, qRgb
|
|
15
14
|
|
|
16
15
|
from qwt import (
|
|
17
|
-
|
|
18
|
-
QwtPlotMarker,
|
|
16
|
+
QwtInterval,
|
|
19
17
|
QwtLegend,
|
|
20
|
-
QwtPlotGrid,
|
|
21
|
-
QwtPlotCurve,
|
|
22
|
-
QwtPlotItem,
|
|
23
18
|
QwtLegendData,
|
|
24
19
|
QwtLinearColorMap,
|
|
25
|
-
|
|
20
|
+
QwtPlot,
|
|
21
|
+
QwtPlotCurve,
|
|
22
|
+
QwtPlotGrid,
|
|
23
|
+
QwtPlotItem,
|
|
24
|
+
QwtPlotMarker,
|
|
26
25
|
QwtScaleMap,
|
|
27
26
|
toQImage,
|
|
28
27
|
)
|
qwt/tests/test_logcurve.py
CHANGED
qwt/tests/test_mapdemo.py
CHANGED
|
@@ -10,13 +10,13 @@ SHOW = True # Show test in GUI-based test launcher
|
|
|
10
10
|
|
|
11
11
|
import random
|
|
12
12
|
import time
|
|
13
|
-
import numpy as np
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
from qtpy.QtGui import QPen, QBrush
|
|
14
|
+
import numpy as np
|
|
17
15
|
from qtpy.QtCore import QSize, Qt
|
|
16
|
+
from qtpy.QtGui import QBrush, QPen
|
|
17
|
+
from qtpy.QtWidgets import QMainWindow, QToolBar
|
|
18
18
|
|
|
19
|
-
from qwt import QwtPlot,
|
|
19
|
+
from qwt import QwtPlot, QwtPlotCurve, QwtSymbol
|
|
20
20
|
from qwt.tests import utils
|
|
21
21
|
|
|
22
22
|
|
qwt/tests/test_multidemo.py
CHANGED
|
@@ -9,10 +9,9 @@
|
|
|
9
9
|
SHOW = True # Show test in GUI-based test launcher
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
|
-
|
|
13
|
-
from qtpy.QtWidgets import QGridLayout, QWidget
|
|
14
|
-
from qtpy.QtGui import QPen
|
|
15
12
|
from qtpy.QtCore import Qt
|
|
13
|
+
from qtpy.QtGui import QPen
|
|
14
|
+
from qtpy.QtWidgets import QGridLayout, QWidget
|
|
16
15
|
|
|
17
16
|
from qwt import QwtPlot, QwtPlotCurve
|
|
18
17
|
from qwt.tests import utils
|
qwt/tests/test_simple.py
CHANGED
|
@@ -20,6 +20,7 @@ FNAMES = ("test_simple.svg", "test_simple.pdf", "test_simple.png")
|
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
class SimplePlot(qwt.QwtPlot):
|
|
23
|
+
NUM_POINTS = 100
|
|
23
24
|
TEST_EXPORT = True
|
|
24
25
|
|
|
25
26
|
def __init__(self):
|
|
@@ -30,13 +31,11 @@ class SimplePlot(qwt.QwtPlot):
|
|
|
30
31
|
self.setAxisTitle(qwt.QwtPlot.yLeft, "Y-axis")
|
|
31
32
|
self.enableAxis(self.xBottom)
|
|
32
33
|
self.setCanvasBackground(Qt.white)
|
|
33
|
-
canvas = self.canvas()
|
|
34
|
-
canvas.setBorderRadius(50)
|
|
35
34
|
|
|
36
35
|
qwt.QwtPlotGrid.make(self, color=Qt.lightGray, width=0, style=Qt.DotLine)
|
|
37
36
|
|
|
38
37
|
# insert a few curves
|
|
39
|
-
x = np.
|
|
38
|
+
x = np.linspace(0.0, 10.0, self.NUM_POINTS)
|
|
40
39
|
qwt.QwtPlotCurve.make(x, np.sin(x), "y = sin(x)", self, linecolor="red")
|
|
41
40
|
qwt.QwtPlotCurve.make(x, np.cos(x), "y = cos(x)", self, linecolor="blue")
|
|
42
41
|
|
qwt/tests/test_stylesheet.py
CHANGED
|
@@ -2,7 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
SHOW = True # Show test in GUI-based test launcher
|
|
4
4
|
|
|
5
|
+
import os
|
|
6
|
+
|
|
5
7
|
import numpy as np
|
|
8
|
+
import pytest
|
|
9
|
+
import qtpy
|
|
6
10
|
from qtpy.QtCore import Qt
|
|
7
11
|
|
|
8
12
|
import qwt
|
|
@@ -19,6 +23,11 @@ class StyleSheetPlot(qwt.QwtPlot):
|
|
|
19
23
|
qwt.QwtPlotCurve.make(x, np.sinc(x), "y = sinc(x)", self, linecolor="green")
|
|
20
24
|
|
|
21
25
|
|
|
26
|
+
# Skip the test for PySide6 on Linux
|
|
27
|
+
@pytest.mark.skipif(
|
|
28
|
+
qtpy.API_NAME == "PySide6" and os.name == "posix",
|
|
29
|
+
reason="Fails on Linux with PySide6 for unknown reasons",
|
|
30
|
+
)
|
|
22
31
|
def test_stylesheet():
|
|
23
32
|
"""Stylesheet test"""
|
|
24
33
|
utils.test_widget(StyleSheetPlot, size=(600, 400))
|
qwt/toqimage.py
CHANGED
qwt/transform.py
CHANGED
|
@@ -14,7 +14,7 @@ QwtTransform
|
|
|
14
14
|
|
|
15
15
|
.. autoclass:: QwtTransform
|
|
16
16
|
:members:
|
|
17
|
-
|
|
17
|
+
|
|
18
18
|
QwtNullTransform
|
|
19
19
|
~~~~~~~~~~~~~~~~
|
|
20
20
|
|
|
@@ -26,7 +26,7 @@ QwtLogTransform
|
|
|
26
26
|
|
|
27
27
|
.. autoclass:: QwtLogTransform
|
|
28
28
|
:members:
|
|
29
|
-
|
|
29
|
+
|
|
30
30
|
QwtPowerTransform
|
|
31
31
|
~~~~~~~~~~~~~~~~~
|
|
32
32
|
|
qwt/tests/conftest.py
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
# -*- coding: utf-8 -*-
|
|
2
|
-
|
|
3
|
-
"""pytest configuration for PythonQwt package tests."""
|
|
4
|
-
|
|
5
|
-
import os
|
|
6
|
-
from qwt.tests.utils import TestEnvironment
|
|
7
|
-
|
|
8
|
-
# Set the unattended environment variable to 1 to avoid any user interaction
|
|
9
|
-
os.environ[TestEnvironment.UNATTENDED_ENV] = "1"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|