Bug 443604

Summary: Typing a custom zoom value is weird: can't set 1000%, but can type 16000000%
Product: [Applications] gwenview Reporter: Gabriel <gabriel>
Component: generalAssignee: Gwenview Bugs <gwenview-bugs-null>
Status: RESOLVED FIXED    
Severity: minor Keywords: usability
Priority: NOR    
Version: 21.08.2   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Trying some values: 999, 1000, 1100, 1600+
Typing '0' resets the value

Description Gabriel 2021-10-11 16:03:49 UTC
Created attachment 142337 [details]
Trying some values: 999, 1000, 1100, 1600+

SUMMARY
The zoom box in Gwenview allows for custom input, for which it tries to filter what you type in to ensure you don't set any weird values. However, the current way it does that leads to some odd behaviour: Typing a value between 1000-1009 is disallowed despite that being well in the range of what it can show. Typing a number that starts with 1600 does not have that same kind of control. (See screen recording.)

STEPS TO REPRODUCE
1. Open an image in Gwenview
2. Type to set the custom zoom value to 1000%

OBSERVED RESULT
The zoom gets set at the minimum value instead

EXPECTED RESULT
Zoom gets set at 1000%

SOFTWARE
OS: KDE neon Testing Edition
KDE Plasma Version: 5.23.0
KDE Frameworks Version: 5.88.0
Qt Version: 5.15.3

ADDITIONAL INFORMATION
It would be much nicer if you could freely type any number which only first gets checked and applied when hitting enter or clicking out of the zoom spinner.
Comment 1 Gabriel 2021-10-11 16:24:20 UTC
Created attachment 142338 [details]
Typing '0' resets the value

An additional note is that sometimes entering values with '0' such as 40% or 200% doesn't work because it resets when the '0' is typed. (See the second attachment.) I couldn't replicate the behaviour reliably, but it has happened a few times.
Comment 2 Gabriel 2021-10-15 12:30:11 UTC
Tested with Gwenview version 21.08.2 :^)
Comment 3 Gabriel 2022-01-17 10:12:45 UTC
This problem seems to now be resolved, with Gwenview being able to better interpret custom inputs. I can't pinpoint the exact merge request, but many thanks to whoever fixed this!