Bug 378584

Summary: Zooming with CTRL+Two-finger-scrolling is too sensitive
Product: [Applications] gwenview Reporter: Thomas Mitterfellner <thomas>
Component: generalAssignee: Gwenview Bugs <gwenview-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: aacid, myriam, nate, simonandric5
Priority: NOR    
Version: Other (add details in bug description)   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Patch to fix ctrl-scroll behavior via touchpad

Description Thomas Mitterfellner 2017-04-09 11:54:36 UTC
When I zoom in and out of an image using CTRL+Two-finger-scrolling on the touchpad, this goes way too fast/much too sensitive, so it is almost impossible to get to a desired magnification.

Please have a look at https://bugs.kde.org/show_bug.cgi?id=377128 as this one seems to be almost the same problem.
Comment 1 Thomas Mitterfellner 2017-04-09 11:56:43 UTC
I forgot: this is for version 16.08.2, KDE Frameworks 5.32.0, Qt 5.8.0 (built against 5.8.0), the xcb windowing system
Comment 2 Nate Graham 2017-09-08 18:10:13 UTC
Confirmed.
Comment 3 Nate Graham 2017-09-08 20:07:03 UTC
Actually, since the touchpad emulated a scroll wheel, this is a duplicate of https://bugs.kde.org/show_bug.cgi?id=307637#add_comment

*** This bug has been marked as a duplicate of bug 307637 ***
Comment 4 Thomas Mitterfellner 2017-09-08 20:24:01 UTC
Well, only kind of. Did you have a look at the bug report I linked? The problem is not really the increment. It is that it is almost impossible to select a particular increment. Zooming in 100% steps is not optimum, but I'd be ok, if I could reliably CRTL-Zoom there using the touchpad. That is not possible. The increment would probably have to be 0.1%-1% to be somewhat usable.

So I beg you: please have a look at the linked okular bug report and check the solution presented there. Or, alternatively, compare the krita bug report at https://bugs.kde.org/show_bug.cgi?id=378586 - they also fixed it already.
Comment 5 Nate Graham 2017-09-08 20:27:04 UTC
Ooooh lookie at that. Thanks for the additional info, Thomas. Not a duplicate.

Though fixing https://bugs.kde.org/show_bug.cgi?id=307637 will make this a little better until we can fix this.
Comment 6 Nate Graham 2017-09-08 20:33:21 UTC
I'm afraid my own C++ skills aren't yet sufficient to adapt either of those fixes to Gwenview, but maybe in the future... or maybe a charitable soul will stop by before then and do it first!
Comment 7 Thomas Mitterfellner 2017-09-08 21:33:34 UTC
Created attachment 107764 [details]
Patch to fix ctrl-scroll behavior via touchpad
Comment 8 Thomas Mitterfellner 2017-09-08 21:34:37 UTC
I've adapted the okular solution and it seems to work as expected. Please review/test the attached patch. I'd be happy to see the fix in the next gwenview version.
Comment 9 Nate Graham 2017-09-08 21:37:27 UTC
Fantastic!!!

Did you make sure that the patch didn't break scroll wheel behavior? If so, can you upload the patch to Phabricator (http://phabricator.kde.org/) with the details of your testing? Use the Gwenview repo and as reviewers, add "KDE Applications", Albert Astral Cid, Kai Uwe Broulik, and Christoph Feck.
Comment 10 Thomas Mitterfellner 2017-09-08 21:55:26 UTC
Tested with mouse wheel. Works as expected as far as I can tell. I'll try to submit it.
Comment 11 Thomas Mitterfellner 2017-09-08 22:24:51 UTC
No chance. I cannot log in to phabricator. Could you (or someone who has access) please submit it? (KDE identity doesn't let me in, I cannot register as my address is already taken, I cannot reset my password)
Comment 12 Nate Graham 2017-09-08 23:12:15 UTC
Sure, I can do it. Patch URL is https://phabricator.kde.org/D7744

Long-term, it would be a good idea to sort out your Phabricator access, since this is now the central portal for contributing patches to KDE software.
Comment 13 Albert Astals Cid 2017-09-09 09:28:17 UTC
(In reply to Thomas Mitterfellner from comment #11)
> No chance. I cannot log in to phabricator. Could you (or someone who has
> access) please submit it? (KDE identity doesn't let me in, I cannot register
> as my address is already taken, I cannot reset my password)

Your username is mitterfellner with that, you should be able to reset your password in https://identity.kde.org/index.php?r=site/passwordReset
Comment 14 Albert Astals Cid 2017-09-09 09:39:30 UTC
Git commit c4a84dad6292b9c7918bec8d7ed33114d3758730 by Albert Astals Cid, on behalf of Thomas Mitterfellner.
Committed on 09/09/2017 at 09:39.
Pushed by aacid into branch 'Applications/17.08'.

Reduce hyper-sensitive touchpad scroll-zoom speed

Summary:

Reduce hyper-sensitive touchpad scroll-zoom speed in Gwenview

Test Plan: Submitting this on behalf of  Thomas Mitterfellner since he's having trouble with his Phabricator access. Patch is  modeled after Albert's similar patch for Okular in https://cgit.kde.org/okular.git/commit/?id=7a50ce0edfc9be8bd23441e52a4f3a0c60f7e60f. Thomas has tested locally with a touchpad and scroll wheel, and I have tested in a KDE Neon VM. Seems to work as expected.

Reviewers: #kde_applications, broulik, aacid

Reviewed By: #kde_applications, aacid

Differential Revision: https://phabricator.kde.org/D7744

M  +7    -2    lib/documentview/documentview.cpp

https://commits.kde.org/gwenview/c4a84dad6292b9c7918bec8d7ed33114d3758730
Comment 15 Thomas Mitterfellner 2017-09-09 11:18:03 UTC
> Your username is mitterfellner with that, you should be able to reset your
> password in https://identity.kde.org/index.php?r=site/passwordReset

Thanks! Never would I have guessed that username (really!). I was now able to log in to phabricator. Thanks also for pushing the commit to Applications!