Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents cab1abd + d2a0a0b commit f92e79cCopy full SHA for f92e79c
1 file changed
lib/matplotlib/backends/backend_qt5.py
@@ -588,7 +588,8 @@ def _icon(self, name):
588
if is_pyqt5():
589
name = name.replace('.png', '_large.png')
590
pm = QtGui.QPixmap(os.path.join(self.basedir, name))
591
- pm.setDevicePixelRatio(self.canvas._dpi_ratio)
+ if hasattr(pm, 'setDevicePixelRatio'):
592
+ pm.setDevicePixelRatio(self.canvas._dpi_ratio)
593
return QtGui.QIcon(pm)
594
595
def _init_toolbar(self):
0 commit comments