Releases: PlotPyStack/PythonQwt
Releases · PlotPyStack/PythonQwt
v0.16.2
Immutable
release. Only release title and notes can be modified.
Version 0.16.2
Bug fixes
- Fixed a
QFont/GDI handle leak that release 0.16.1 only masked: the font-key cache retained a strong reference to every distinctQFontit had seen (up to 1024 entries), each pinning its underlying font engine and, on Windows GDI builds, anHFONThandle, accumulating towards the per-process GDI limit. The cache is now a single-slot, leak-free memo and the remaining metrics caches use proper LRU eviction instead of a clear-on-overflow that periodically rebuiltQFontMetricsresults - Fixed delayed release of native GDI handles caused by Python reference cycles:
QwtPlotItemandQwtPlotCanvasheld strong back-references to their parentQwtPlot, so plots were only reclaimed by the cyclic garbage collector. These back-references are now weak, matching the C++ Qwt parent/child model, so a plot is freed by reference counting alone and could otherwise exhaust the ~10000 GDI-object limit on Windows under heavy create/destroy churn - Fixed noisy "Unhandled exception"
AttributeErrortracebacks at teardown on Python 3.14 / Qt 6: during widget destruction Qt still delivers events and calls size-hint methods onQwtPlotobjects whose Python__dict__has already been cleared. Access to private instance data inQwtPlot.eventFilterandQwtPlot.minimumSizeHintis now guarded
Performance
- Restored most of the text-layout performance lost to the GDI-leak fix by reinstating a bounded, leak-free
id(font)fast path inQwtText.textSize(the layout cache holds a strong reference to its single cached font, so the font id cannot be reused)
Other changes
- Added GDI-handle and font-cache telemetry/benchmark scripts under
scripts/(bench_gdi_loadtest.py,telemetry_fontcache.py) and a pytest stress test (qwt/tests/test_issue107_gdi_leak.py) to detect resource leaks under repeated plot create/render/destroy cycles
v0.16.1
Immutable
release. Only release title and notes can be modified.
Version 0.16.1
Bug fixes
- Fixed Issue #107: corrected a Windows crash/access violation that could occur in long-running sessions creating and rendering large amounts of data, due to GDI handle exhaustion caused by object lifetime and cache growth
- Preserved the rendering performance improvements introduced in 0.16.0 while restoring safer Qt object ownership for internal text/scale-draw private data and adding defensive limits to font-metrics caches
v0.16.0
Immutable
release. Only release title and notes can be modified.
Performance
- Major performance optimizations addressing Issue #93 (rendering performance degradation with Qt 6, also benefitting Qt 5):
QwtText: removed unnecessaryQObjectinheritance and added a font key cache to avoid expensiveQFonthashing on every text rendering operationQwtText: cached Qt alignment and text format flags as plain integers to bypassPyQt6enum overhead in hot pathsQwtText: enabled font key caching fast path for Qt 6, kept disabled for Qt 5 to preserve consistent text renderingQwtGraphicandQwtPainterCommand: cached Qt flags as integers to reduce per-command overhead, especially under PyQt6QwtScaleDraw,QwtScaleEngine,QwtScaleMapandQwtScaleDiv: micro-optimizations on the tick computation and coordinate transform code paths
- Added benchmarking and visual regression scripts under
scripts/(bench_qt.ps1,bench_plotpy_loadtest.py,profile_loadtest.py,lineprofile_loadtest.py,capture_screenshots.py,diff_screenshots.py) to measure and validate rendering performance and correctness
Bug fixes
- Merged PR #105: fixed legend icon being rendered incorrectly - thanks to @Adrian-B-Moreira
- Fixed
QPaintDevicewarnings onDevicePixelRatioandDevicePixelRatioScaledmetrics inQwtNullPaintDevice - Fixed integer division in
QwtScaleEngineso that medium ticks are actually produced (previously, the medium tick step was truncated to zero in some configurations) - Fixed
QwtScaleMaprectangle transform and degenerate scale handling (when source or destination interval has zero width)
Other changes
- Internal refactor: removed unnecessary
QObjectinheritance fromQwtText(QwtTextinstances are no longerQObjectsubclasses; this is an internal change with no impact on the public plotting API, but downstream code relying on Qt signals/slots onQwtTextinstances should be adapted) - Development workflow: replaced legacy
.batscripts with a unifiedscripts/run_with_env.pyenvironment loader, refactored VS Code tasks, added coverage tasks and CI gating of PyPI deployment on the test suite passing - Documentation: updated README, Sphinx documentation, dependencies and added AI coding agent instructions
v0.15.0
Immutable
release. Only release title and notes can be modified.
Version 0.15.0
- Added support for
QwtDateTimeScaleDrawandQwtDateTimeScaleEnginefor datetime axis support (seeQwtDateTimeScaleDrawandQwtDateTimeScaleEngineclasses in theqwtmodule) - Improved font rendering for rotated text in
QwtPlainTextEngine.drawmethod: disabled font hinting to avoid character misalignment in rotated text
v0.14.6
Version 0.14.6
- Fixed Issue #100 - TypeError in
QwtSymbol.drawSymbolmethod due to outdatedrenderSymbolscall - Fixed Issue #101 -
RuntimeWarning: overflow encountered in castwhen plottingnumpy.float32curve data - Merged PR #103: [FIX] wrong handling of
border.rectListwith PySide6 backend - thanks to @martinschwinzerl
v0.14.5
v0.14.4
Version 0.14.4
- Fixed canvas rectangle type in
drawItemsmethod call inQwtPlot.drawCanvas(was causing a hard crash when printing to PDF a canvas with upstreamPlotPyproject)
v0.14.3
Version 0.14.3
- Fixed Issue #94 - Different logarithmic scale behavior when compared to Qwt
- Merged PR #91: Fix: legend now showing up when enabled later - thanks to @nicoddemus
- Removed
QwtPlotItem.setIconandQwtPlotItem.iconmethods (introduced in 0.9.0 but not used in PythonQwt)
v0.14.2
Version 0.14.2
- Merged PR #89: fixed call to
ScaleEngine.autoScaleinQwtPlot.updateAxes(returned values were not used) - thanks to @nicoddemus - Merged PR #90: updated
QwtLinearScaleEngine.autoScalemethod implementation to the latest Qwt version - thanks to @nicoddemus
v0.14.1
Version 0.14.1
- Handled
RuntimeErrorwhen runningtest_eventfilter.pyon Ubuntu 22.04 (Python 3.12, PyQt5) - Fixed
ResourceWarning: unclosed fileintest_cpudemo.py(purely test issue) - Fixed segmentation fault in
test_multidemo.py(purely test issue, related to test utility moduleqwt.tests.utils) - Update GitHub actions to use the latest versions of actions/checkout, actions/setup-python, ...