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

EOM window overflows past the screen for certain image resolutions #349

Open
Botspot opened this issue Feb 23, 2024 · 4 comments
Open

EOM window overflows past the screen for certain image resolutions #349

Botspot opened this issue Feb 23, 2024 · 4 comments

Comments

@Botspot
Copy link

Botspot commented Feb 23, 2024

Expected behaviour

For images that are too large to display at 100% zoom level on this display, eom should display the image at a smaller size and scale the window appropriately.

Actual behaviour

For certain image resolutions, eom fails to scale down the image and instead covers the entire screen with a window larger than the physical screen size.

Steps to reproduce the behaviour

Open an image with the following dimensional characteristics:

  • Width of image is greater than the height of the screen.
  • Height must be less than or equal to width, but also greater than the height of the screen.

Here is an image with those characteristics: 2263x2262.jpg

On my 1080p screen, opening the image looks like this:
300643870-70889401-a7e7-44d8-b480-e05e7b61ba74
You can see that eom's interface and the window border is beyond the top and bottom edges of the screen. The only way to close it was with Alt+F4.

This may seem like an extreme edge case, but I have a number of manually cropped images with an odd X-dimension and an even Y-dimension, thanks to Shotwell's not-quite-perfect job at cropping pictures to a square.

MATE general version

Mate is not installed on this distro.

Package version

eom 1.26.0-2
Maintainer: Debian+Ubuntu MATE Packaging Team <[email protected]>

Linux Distribution

Raspberry Pi OS Bookworm 64-bit (wayfire window manager)

Link to bugreport of your Distribution (requirement)

RPi-Distro/repo#366

@Botspot
Copy link
Author

Botspot commented Mar 27, 2024

This should be really easy to reproduce and an easy fix. Someone please respond. Nobody has responded in over a month.
@raveit65
Pinging @whs @mbkma @rbuj next if @raveit65 does not respond

@lukefromdc
Copy link
Member

lukefromdc commented Mar 27, 2024

I can confirm that larger images than the screen height overflow and that this is not limited to the Pi or even to x11. I just opened a 4048x3048 image on a 4K monitor, and the window overflowed both top and bottom. This on Debian unstable-and in the MATE-wayland session. Thus this probably will always happen with EOM from the 1.28.0 release (or 1.26, or current git master) and an oversize image: any distro, any WM, etc.

Note that in compiz you can grab the window from the "expo" view and in wayfire (wayland) it's even simpler: for that case right mouse button will drag any window from anywhere on it. In Marco I can see you would be stuck.

Obviously we need to check the monitor dimensions before opening an image. GdkScreen should NOT be used, as two monitors set up one partially above and left or right of another will yield the smallest "screen" containing both monitors

@Botspot
Copy link
Author

Botspot commented Mar 27, 2024

Can confirm the overflow on my 1080p screen with a 4048x3048 image. It appears that my odd/even hypothesis stated above was incorrect. Though it is interesting to note that EOM does display at a more rational size after resizing the image to either 4048x4048 or 3048x3048.

@lukefromdc
Copy link
Member

If ANY image larger than the monitor stays contained within the monitor, that implies we have monitor size checking code that works some of the time, but not all of the time. I haven't done much of the work on EOM so I don't know offhand where it would be. Fixing this will still need attention from others on the team

@Botspot Botspot changed the title eom window covers the screen for certain resolutions EOM window covers the screen for certain image resolutions Mar 27, 2024
@Botspot Botspot changed the title EOM window covers the screen for certain image resolutions EOM window overflows past the screen for certain image resolutions Mar 27, 2024
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