8000 Add missing check for None in Qt toolmanager. · matplotlib/matplotlib@b3dc410 · GitHub
[go: up one dir, main page]

Skip to content

Commit b3dc410

Browse files
committed
Add missing check for None in Qt toolmanager.
(The fix is already there in all other backends.)
1 parent 48b6327 commit b3dc410

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/matplotlib/backends/backend_qt5.py

Lines changed: 2 additions & 1 deletion
+
if image_file:
Original file line numberDiff line numberDiff line change
@@ -917,7 +917,8 @@ def add_toolitem(
917917
self, name, group, position, image_file, description, toggle):
918918

919919
button = QtWidgets.QToolButton(self)
920-
button.setIcon(NavigationToolbar2QT._icon(self, image_file))
920
921+
button.setIcon(NavigationToolbar2QT._icon(self, image_file))
921922
button.setText(name)
922923
if description:
923924
button.setToolTip(description)

0 commit comments

Comments
 (0)
0