8000 Backport PR #14509: Fix too large icon spacing in Qt5 on non-HiDPI sc… · matplotlib/matplotlib@98ade29 · GitHub
[go: up one dir, main page]

Skip to content

Commit 98ade29

Browse files
dstansbyMeeseeksDev[bot]
authored andcommitted
Backport PR #14509: Fix too large icon spacing in Qt5 on non-HiDPI screens
1 parent 4e268d1 commit 98ade29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/backends/backend_qt5.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -727,7 +727,7 @@ def _init_toolbar(self):
727727
# Esthetic adjustments - we need to set these explicitly in PyQt5
728728
# otherwise the layout looks different - but we don't want to set it if
729729
# not using HiDPI icons otherwise they look worse than before.
730-
if is_pyqt5():
730+
if is_pyqt5() and self.canvas._dpi_ratio > 1:
731731
self.setIconSize(QtCore.QSize(24, 24))
732732
self.layout().setSpacing(12)
733733

0 commit comments

Comments
 (0)
0