We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 68a61ff commit 0e6ea01Copy full SHA for 0e6ea01
1 file changed
qwt/tests/test_bodedemo.py
@@ -243,7 +243,12 @@ def __init__(self, *args):
243
self.print_(unattended=True)
244
245
def print_(self, unattended=False):
246
- printer = QPrinter(QPrinter.HighResolution)
+ try:
247
+ mode = QPrinter.HighResolution
248
+ except AttributeError:
249
+ # Some PySide6 / PyQt6 versions do not have this attribute on Linux
250
+ mode = QPrinter.ScreenResolution
251
+ printer = QPrinter(mode)
252
253
printer.setCreator("Bode example")
254
printer.setOrientation(QPrinter.Landscape)
0 commit comments