Skip to content
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

Download figure as pdf, not as png. #339

Open
srosenzweig09 opened this issue Aug 17, 2021 · 6 comments
Open

Download figure as pdf, not as png. #339

srosenzweig09 opened this issue Aug 17, 2021 · 6 comments

Comments

@srosenzweig09
Copy link

Describe the issue

Widgets are displayed with a toolbar, which has a save/download button that saves the figure directly to my Downloads folder. I love this feature, but I would appreciate it even more if I can set it to download the image as a pdf instead of as a png. Is this a possibility?

@martinRenou
Copy link
Member

I believe this is not on the roadmap for ipympl, but maybe someone has another opinion, do you have any input on this @ianhi?

I guess this would be difficult to implement unless we find a JavaScript library that makes this easy.

@martinRenou
Copy link
Member

@ianhi
Copy link
Collaborator

ianhi commented Aug 17, 2021

This is the same underlying issue as #138 and #234 which is the savefig button doesn't respect rcparams because it doesn't follow the normal savefig path.

Ultimately I think ipympl should respect that from buttons. I think the way to have that happen is to have a bit more back and forth between front and backend when the save button is pushed. So it could like what I sketched out in #138 (comment)

@ianhi
Copy link
Collaborator

ianhi commented Aug 17, 2021

For pdf we need the option 1 i proposed which is just using the javascript to choose the filepath and then doing everything on hte backend

@abast
Copy link

abast commented Jun 6, 2024

Is there any news regarding this feature? pdf is the format I use most frequently as I can import it as vectorgraphic into illustrator, and this worflow would be much improved if I could download a pdf directly from the notebook.

@giulioiannelli
Copy link

I also found myself in the need of this functionality. Any news?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants