emulsion icon indicating copy to clipboard operation
emulsion copied to clipboard

Feature request: add a config option to open Emulsion sized to fit the image

Open rabirabirara opened this issue 3 years ago • 2 comments

I would love a configuration option that sized the Emulsion window to the size of the image on open. If the image resolution is too large to be sized around, then the viewer will size itself to the horizontal or vertical limits of the computer screen.

Here are some examples. I sometimes snip figures out of textbooks I'm studying, save them, and link to them in my notes, which I edit with Vim. So I open such a link in Emulsion:

image

..and the viewer takes up the whole page. This is what other image viewers typically do as well, but having the option for it to open sized like this instead:

image

...would allow me to quickly move the window around with keybinds, or just more efficiently with mouse, than if I had to resize it by carefully clicking the corners.

For an image with a large vertical dimension, it might open like this:

image

...and with a large horizontal dimension:

image

(Disclaimer: I do not intend to advertise any art with this issue; I used those images for demonstration purposes.)

rabirabirara avatar Apr 03 '21 04:04 rabirabirara

Hello there!

This totally sounds like something we could do. In the config file, we could add a boolean field under the [window] section with a name like start_with_img_size. This would be false by default, bu when it's true, emulsion sets the window dimensions when the "startup" image is loaded.

@Aloso would you be interested in tackling this?

ArturKovacs avatar Apr 05 '21 12:04 ArturKovacs

Please limit the sizes to fit in the screen... it's annoying on some linux WMs when such thing happens. idk if there is such feature in rust

raspher avatar May 19 '21 20:05 raspher