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 e66039b

Browse filesBrowse files
committed
Merge pull request matplotlib#2680 from tacaswell/deprec_toolbarqt4Agg
Deprecate toolbarqt4agg
2 parents b795756 + 6ca7268 commit e66039b
Copy full SHA for e66039b

File tree

Expand file treeCollapse file tree

3 files changed

+16
-1
lines changed
Filter options
Expand file treeCollapse file tree

3 files changed

+16
-1
lines changed

‎doc/api/api_changes.rst

Copy file name to clipboardExpand all lines: doc/api/api_changes.rst
+3Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,9 @@ original location:
116116
* The ``fmt`` argument of :meth:`~matplotlib.axes.Axes.plot_date` has been
117117
changed from ``bo`` to just ``o``, so color cycling can happen by default.
118118

119+
* Removed the class `FigureManagerQTAgg` and deprecated `NavigationToolbar2QTAgg`
120+
which will be removed in 1.5.
121+
119122
.. _changes_in_1_3:
120123

121124

‎examples/user_interfaces/embedding_in_qt4_wtoolbar.py

Copy file name to clipboardExpand all lines: examples/user_interfaces/embedding_in_qt4_wtoolbar.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from matplotlib.backend_bases import key_press_handler
88
from matplotlib.backends.backend_qt4agg import (
99
FigureCanvasQTAgg as FigureCanvas,
10-
NavigationToolbar2QTAgg as NavigationToolbar)
10+
NavigationToolbar2QT as NavigationToolbar)
1111
from matplotlib.backends import qt4_compat
1212
use_pyside = qt4_compat.QT_API == qt4_compat.QT_API_PYSIDE
1313

‎lib/matplotlib/backends/backend_qt4agg.py

Copy file name to clipboardExpand all lines: lib/matplotlib/backends/backend_qt4agg.py
+12Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import os # not used
1010
import sys
1111
import ctypes
12+
import warnings
1213

1314
import matplotlib
1415
from matplotlib.figure import Figure
@@ -24,6 +25,7 @@
2425
from .backend_qt4 import draw_if_interactive
2526
from .backend_qt4 import backend_version
2627
######
28+
from matplotlib.cbook import mplDeprecation
2729

2830
DEBUG = False
2931

@@ -168,5 +170,15 @@ def print_figure(self, *args, **kwargs):
168170
self.draw()
169171

170172

173+
class NavigationToolbar2QTAgg(NavigationToolbar2QT):
174+
def __init__(*args, **kwargs):
175+
warnings.warn('This class has been deprecated in 1.4 ' +
176+
'as it has no additional functionality over ' +
177+
'`NavigationToolbar2QT`. Please change your code to '
178+
'use `NavigationToolbar2QT` instead',
179+
mplDeprecation)
180+
NavigationToolbar2QT.__init__(*args, **kwargs)
181+
182+
171183
FigureCanvas = FigureCanvasQTAgg
172184
FigureManager = FigureManagerQT

0 commit comments

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