Bug 483155

Summary: [wayland] Spectacle Rectangle Select has Inaccurate Sizing on Multi-Screen Multi-Scale Configurations
Product: [Applications] Spectacle Reporter: Eamonn Rea <eamonnrea>
Component: GeneralAssignee: Noah Davis <noahadvs>
Status: RESOLVED FIXED    
Severity: normal CC: cj61947, kde, nate
Priority: NOR Keywords: qt6
Version: 24.02.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 24.05
Sentry Crash Report:

Description Eamonn Rea 2024-03-10 18:45:58 UTC
SUMMARY
When Spectacle's Rectangle Select is activated, selecting a region will show the sizing in a box above or below the region select. However, this sizing is very inaccurate. Selecting a window on a 1080p screen will show it as being larger than the actual resolution of the screen. Selecting close to the whole 1080p screen will actually display a value approaching 3840x2160 (give or take 10-15 pixels), which is the resolution of my scaled display.

On the scaled display, single, small windows can exceed measurements of 5,000 pixels in width and 3,000 pixels in height, which is of course not correct.

Even if the displayed resolution is incorrect, screenshots saved on the scaled display are actually correct (i.e. instead of displaying 5,000 pixels, it will only be 2,000 pixels when saved).

However this is NOT the case for screenshots on the non-scaled displays; the incorrect value Spectacle shows is the actual resolution the files are saved as - This issue is probably the same as Bug 478426.

STEPS TO REPRODUCE
1. Activate region select with Spectacle
2. Select a region
3. Size is not accurate


OBSERVED RESULT
The resolution preview for Spectacle Rectangle Select is inaccurate.


EXPECTED RESULT
The resolution preview for Spectacle Rectangle Select should be accurate, reflecting the actual window sizes.


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 6.7.8 Linux Zen
KDE Plasma Version: 6.0.1
KDE Frameworks Version:  6.0.0
Qt Version: 6.6.2 

ADDITIONAL INFORMATION
Possibly related to Bug 478426.
Comment 1 Christopher Smith 2024-03-12 00:40:26 UTC
I've had the same issue using single displays, and it only seems to be happening on fractional scale factors. On a single 1080p display at 125% scale, Spectacle reports a full-display resolution of 3071x1727, but correctly saves a 1920x1080 screenshot. On 200% scale, however, the reported resolution is near 1920x1080 (reported as 1919x1079).
Comment 2 Nate Graham 2024-04-19 07:02:54 UTC
This should be substantially improved if not fixed with the upcoming 24.05 release. Please do feel free to re-open the bug report if you find that it's not fixed for you though, and we'll do more investigation.
Comment 3 Eamonn Rea 2024-05-26 22:41:26 UTC
This is sadly not quite fixed. The screenshots don't look as blurry, they look overly-crisp now, and they are the wrong size. A screenshot of my full 1920x1080 display is coming out at just shy of 3840x2160 (if I got it more precise, it could probably be 3840x2160). This is the native resolution of my only scaled display.

My region screenshots are not spanning multiple displays or anything, I just want to take a region screenshot of a single area on my non-scaled display and have it look the same as it did in Plasma 5.27.
Comment 4 Eamonn Rea 2024-05-27 20:19:13 UTC
I noticed today the situation is actually worse as of Spectacle 24.05.0.

When taking region screenshots on a scaled display, the size is now actually saved as the resolution displayed by Spectacle, which is wrong (as noted, approx 5,000x3,000).
Comment 5 Noah Davis 2024-05-30 04:27:15 UTC
If you are experiencing a new issue, can you post a new bug report so that we can track it properly?
Comment 6 Eamonn Rea 2024-06-03 23:12:13 UTC
I think my described issue is separate in my comment. I think I got mixed up and commented on the wrong bug report.

However, the Spectacle Rectangular Region resolution preview is still incorrect. That's what this issue is about, the box when you take a rectangular region screenshot is incorrect. The saved screenshot resolution is also incorrect but I think this is tracked elsewhere.

This bug is not fixed sadly. The resolution preview box displayed when selecting a Rectangular Region for a screenshot is still widely incorrect. It may possibly be related to the issues with rectangular region screenshots saving screenshots as the wrong resolution, as the resolution displayed by the Rectangular Region box, while incorrect (shows 3795x2119 for a region on a 1920x1080 display) *is actually the resolution the screenshot saves as*. It is just that this resolution is wrong, it should be closer to some three-figure width and height value each.
Comment 7 Eamonn Rea 2024-06-17 22:19:39 UTC
This issue is not fixed in Spectacle 24.05.1, the resolution displayed in the box is still incorrect. This also affects another device I have running Plasma 6.0.5 and Spectacle 24.05.1.
Comment 8 Eamonn Rea 2024-07-06 01:06:32 UTC
This is still not fixed in Spectacle 24.05.2 despite being marked as fixed in 24.05. It was never fixed for me, the displayed resolution is always incorrect so long as there is a scaled display anywhere in the setup, even just a single scaled display on a laptop.