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

feat: full screen #180

Merged
merged 12 commits into from
Dec 29, 2024
Merged

feat: full screen #180

merged 12 commits into from
Dec 29, 2024

Conversation

flekschas
Copy link
Owner

@flekschas flekschas commented Dec 29, 2024

This PR adds the ability to open a scatter plot in full-screen mode. The full-screen mode allows to customize and up-scale a scatter plot for better exporting as PNG.

Description

What was changed in this pull request?

  1. This PR adds the ability to open a scatter plot in full-screen mode. To open the full screen mode, click on the third button that features an expand icon.
  2. In full-screen mode, one can open up a resize panel via the arrow button in the bottom-left corner. This panel allows to easily adjust the width/height of the scatter plot for exporting. It's now also possible to up-scale the exported image.
  3. Finally, since there are more and more widget buttons now, I also added the ability to customize the control buttons. For instance, scatter.show(buttons=['full_screen', 'download', 'reset']) only shows three out of the seven buttons.

Why is it necessary?

Fixes #38
Fixes #103

Example

In the following I'm demonstrating how to enter the full-screen mode and how to customize the scatter plot's width, height, and scale for exporting the plot at 4800x3200 pixels (1200 width, 800height, 2x up-scale, and 2x device pixel ratio)

full-screen-export.mp4

Final exported image

jupyter-scatter (4)

Checklist

  • Provided a concise title as a semantic commit message (e.g. "fix: correctly handle undefined properties")
  • CHANGELOG.md updated
  • Tests added or updated
  • Documentation in API.md/README.md added or updated
  • Example(s) added or updated
  • Screenshot, gif, or video attached for visual changes

Copy link

netlify bot commented Dec 29, 2024

Deploy Preview for calm-platypus-50e85d canceled.

Name Link
🔨 Latest commit fbefdcf
🔍 Latest deploy log https://app.netlify.com/sites/calm-platypus-50e85d/deploys/677147ede72e3e0008e2eb4d

@flekschas flekschas merged commit 2ad54ae into main Dec 29, 2024
10 checks passed
@flekschas flekschas deleted the flekschas/full-screen branch December 29, 2024 13:17
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

Successfully merging this pull request may close these issues.

feat: exporting plots in high and custom resolution Feature request: customizable controls
1 participant