Skip to content

Commit 3a4e77c

Browse files
committed
Fix saving nbAgg figure after a partial blit.
This is a cross-port of matplotlib/ipympl#93.
1 parent 33d496b commit 3a4e77c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/backends/web_backend/js/nbagg_mpl.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ mpl.mpl_figure_comm = function (comm, msg) {
3333
var ws_proxy = comm_websocket_adapter(comm);
3434

3535
function ondownload(figure, _format) {
36-
window.open(figure.imageObj.src);
36+
window.open(figure.canvas.toDataURL());
3737
}
3838

3939
var fig = new mpl.figure(id, ws_proxy, ondownload, element.get(0));

0 commit comments

Comments
 (0)