Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 655c513

Browse filesBrowse files
committed
Fix for PyQt5.7 support.
Just getting rid of a slot with an incorrect signature (for which PyQt5.7 is more strict). Tested on PyQt5.6.1 and 5.7, PyQt4.11.4, PySide 1.2.4.
1 parent b5b5a67 commit 655c513
Copy full SHA for 655c513

File tree

Expand file treeCollapse file tree

1 file changed

+5
-9
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+5
-9
lines changed

‎lib/matplotlib/backends/backend_qt5.py

Copy file name to clipboardExpand all lines: lib/matplotlib/backends/backend_qt5.py
+5-9Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -474,18 +474,18 @@ def __init__(self, canvas, num):
474474

475475
self.window._destroying = False
476476

477+
# add text label to status bar
478+
self.statusbar_label = QtWidgets.QLabel()
479+
self.window.statusBar().addWidget(self.statusbar_label)
480+
477481
self.toolbar = self._get_toolbar(self.canvas, self.window)
478482
if self.toolbar is not None:
479483
self.window.addToolBar(self.toolbar)
480-
self.toolbar.message.connect(self._show_message)
484+
self.toolbar.message.connect(self.statusbar_label.setText)
481485
tbs_height = self.toolbar.sizeHint().height()
482486
else:
483487
tbs_height = 0
484488

485-
# add text label to status bar
486-
self.statusbar_label = QtWidgets.QLabel()
487-
self.window.statusBar().addWidget(self.statusbar_label)
488-
489489
# resize the main window so it will display the canvas with the
490490
# requested size:
491491
cs = canvas.sizeHint()
@@ -507,10 +507,6 @@ def notify_axes_change(fig):
507507
self.canvas.figure.add_axobserver(notify_axes_change)
508508
self.window.raise_()
509509

510-
@QtCore.Slot()
511-
def _show_message(self, s):
512-
self.statusbar_label.setText(s)
513-
514510
def full_screen_toggle(self):
515511
if self.window.isFullScreen():
516512
self.window.showNormal()

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.