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

Pasted screenshots show up twice as big (HiDPI Retina screenshot) #333

Open
gth001 opened this issue Jan 9, 2024 · 1 comment
Open

Pasted screenshots show up twice as big (HiDPI Retina screenshot) #333

gth001 opened this issue Jan 9, 2024 · 1 comment

Comments

@gth001
Copy link

gth001 commented Jan 9, 2024

ok.mp4

In order to use jspaint, I must set the zoom to 50% every time, as shown in the video. Is there any way to keep a permanant 50% zoom every time I load the page, or perhaps default to 50% zoom on HiDPI displays?

@1j01
Copy link
Owner

1j01 commented Jan 15, 2024

There is a feature request for a persistent zoom setting.
That said, I think maybe the app is supposed to scale the canvas for HiDPI displays, I don't remember...
OK, looking at the code, it was left as a question mark in a comment:

render_canvas_view(thumbnail_canvas, 1, viewport_x, viewport_y, false); // devicePixelRatio?

Thinking about this some more...

  • The current approach favors consistency in the physical size of an image file viewed across devices, but at the clear detriment of the screenshot editing use case, as you've pointed out.
  • Changing it so the app scales the canvas by the device pixel ratio...
    • would make existing drawings appear smaller when reopened. This will cause some confusion for a time, but new images will naturally be created at the new default scale, or people will learn to zoom in if they prefer a lower resolution canvas. The MS Paint UI does at least make it easier to zoom in than zoom out, as you can use the Magnifier tool.
    • This new approach would make screenshots created on the same device appear at the correct size, although screenshots from other devices would have no such guarantee. In fact, the reverse problem could occur: a screenshot taken on a 1 DPI screen, when viewed on a 2 DPI screen, would appear half the size, whereas currently it would appear at a more reasonable size.
  • It's also possible these screenshots may embed some DPI information that could be queried, although this seems like a can of worms, especially since not all programs would preserve this information.

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

2 participants