Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Remove print_figure overrides in backend subclasses #25713

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions lib/matplotlib/backends/backend_qtagg.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,6 @@ def paintEvent(self, event):
finally:
painter.end()

def print_figure(self, *args, **kwargs):
super().print_figure(*args, **kwargs)
self.draw()


@_BackendQT.export
class _BackendQTAgg(_BackendQT):
Expand Down
9 changes: 0 additions & 9 deletions lib/matplotlib/backends/backend_wx.py
Original file line number Diff line number Diff line change
Expand Up @@ -614,15 +614,6 @@ def gui_repaint(self, drawDC=None):
'xpm': 'X pixmap',
}

def print_figure(self, filename, *args, **kwargs):
# docstring inherited
super().print_figure(filename, *args, **kwargs)
# Restore the current view; this is needed because the artist contains
# methods rely on particular attributes of the rendered figure for
# determining things like bounding boxes.
if self._isDrawn:
self.draw()

def _on_paint(self, event):
"""Called when wxPaintEvt is generated."""
_log.debug("%s - _on_paint()", type(self))
Expand Down