Closed
Description
Wishlist: a "copy image to clipboard" button in the Toolbar for interactive backends.
For the wx backend, I've had some success with adding such a button by altering the function matplotlib.backends.NavigationToolbar2Wx._init_toolbar() in backend_wx.py so that the last line:
self.Realize()
is replaced by:
_NTB2_COPY = wx.NewId()
self.AddSimpleTool(_NTB2_COPY, _load_bitmap('stock_up.xpm'),
'Copy', 'Copy plot image to clipboard')
bind(self, wx.EVT_TOOL, self.copy, id=_NTB2_COPY)
self.Realize()
def copy(self, evt):
self.canvas.Copy_to_Clipboard(event=evt) # bmp image