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

[fix] Gesture manager: check multiswipe defaults #4623

Merged
merged 3 commits into from Feb 20, 2019

Conversation

Projects
None yet
3 participants
@Frenzie
Copy link
Member

Frenzie commented Feb 19, 2019

Pointed out by @poire-z

Also add default previous location action for left, down.

[fix] Gesture manager: check multiswipe defaults
Pointed out by @poire-z

Also add default previous location action for left, down.

@Frenzie Frenzie added the bug label Feb 19, 2019

@poire-z

This comment has been minimized.

Copy link
Contributor

poire-z commented Feb 19, 2019

We had some tricky discussion in the past about how to understand swipe west/left/to the left and stuff like that, so I'm still not sure how to reference the gesture.
But in readerlink, it's swipe "east" that goes back.

function ReaderLink:onSwipe(arg, ges)
if ges.direction == "east" then
if isSwipeToGoBackEnabled() then
if #self.location_stack > 0 then
-- Remember if location stack is going to be empty, so we
-- can stop the propagation of next swipe back: so the user
-- knows it is empty and that next swipe back will get him
-- to previous page (and not to previous location)
self.swipe_back_resist = #self.location_stack == 1
return self:onGoBackLink()

So, I guess that if you're adding an alternate gesture for people who would disable "Swipe to go back" to avoid conflict with swipe to turn page, your multiswipe gesture should have "east", instead of "west" in "multiswipe_west_south".

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 19, 2019

But in readerlink, it's swipe "east" that goes back.

Which imo is a odd and counter-intuitive (because right is forward). Sure, it depends on whether you think of it as dragging the page or as gesturing, but I find it a very confusing gesture when enabled.

Also, the rewind gesture as popularly implemented in Opera over 15 years ago, now in Otter and Vivaldi, goes the same way. It feels very natural, with years of muscle memory.

https://help.opera.com/en/presto/fast-browsing/#gestures

Here's Vivaldi's excellent visualization. ;-)

ezgif-4-28511d105273

(As a compromise we could add it as a default for both… or just work on making those other gestures configurable sooner rather than later.)

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 19, 2019

Speaking of which, I was thinking of doing something not unlike Vivaldi's record a gesture function. Just with simple arrows instead of the cute snake thing.

And look at this, they also have a configurable minimum stroke threshold:
screenshot_2019-02-19_21-31-58

(I don't think classic Opera did.)

@poire-z

This comment has been minimized.

Copy link
Contributor

poire-z commented Feb 19, 2019

Which imo is a odd and counter-intuitive (because right is forward). Sure, it depends on whether you think of it as dragging the page or as gesturing, but I find it a very confusing gesture when enabled.

I get what you say, and you might have been gesturing with a mouse too much :) (I really never did...)
But it's just that in KOReader, and for people who have been using it for years, we're more into the dragging page mindset (as in most "touch" things like phones, and tablets). Not only when following a link and getting back: even just with swipe to turn pages: we drag the current page out.

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 19, 2019

Sorry, I mostly just got confused. I'd swear there was at least one incredibly counter-intuitive one among those settings and for some reason I thought it was that one. I guess my only real issue with them is that they override normal left/right navigation.

What about left, right instead?

@poire-z

This comment has been minimized.

Copy link
Contributor

poire-z commented Feb 19, 2019

What about left, right instead?

For getting back from link? Why not, feels like "shake" to go back :)

Personally, (*) I may just set east+south to show TOC and west+south to show Bookmarks, similar to the existing 2 fingers swipes that show them in these directions, just to be able to do them one handed (for 2 fingers, you need the other hand to hold the device). And I'll probably set all the other ones to "nothing" - just because I sometimes break a swipe with an angle to just cancel the one I was making if I changed my mind).
And north-south or south-north - dunno which fells more logical - to show History - that you can then make disappear with a swipe down.

I'm a bit uncertain about if we should set defaults for multi gestures. We don't have much actions, they are all mostly one or two tap away. It comes down to personal usage. Having multi gestures set to something by default may surprise some people, who will have to go disabling them. But it's also one way to advertise that new feature :)

(*: when you'll have solved that distance/direction bug :)

@KenMaltby

This comment has been minimized.

Copy link

KenMaltby commented Feb 20, 2019

I guess I am getting out of date, to me gestures are not the first option but there to provide more options when there would otherwise be a conflict with the normal tap on the screen. The new proposed gesture management and added gesture capability sounds great, as a means to implement new or alternative controls. The original tap controls should remain defaults, for consistency. Just an opinion, of course.

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 20, 2019

@KenMaltby
Yes, alternative is all they are. :-)

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 20, 2019

@poire-z

Having multi gestures set to something by default may surprise some people, who will have to go disabling them. But it's also one way to advertise that new feature :)

Well, don't forget that the first time you accidentally make one there's the introductory message. I think having a defined set of defaults makes it much easier to play around with on the first encounter.

  • I wonder what that is.
  • Left, down opens bookmarks, let's try that.
  • Cool/I don't like it.

This could be presented slightly more elegantly once there actually is a set of defaults.

By doing so, only people who don't like the defaults have to go through the additional effort of changing them.

And I'll probably set all the other ones to "nothing" - just because I sometimes break a swipe with an angle to just cancel the one I was making if I changed my mind).

Funny, I do my "crossing out" a bit wilder, which works out just fine. :-)

02/20/19-09:33:03 DEBUG multiswipe west east north south east west

@Frenzie Frenzie merged commit 13d4ead into koreader:master Feb 20, 2019

1 check passed

ci/circleci Your tests passed on CircleCI!
Details

@Frenzie Frenzie deleted the Frenzie:check-multiswipe-defaults branch Feb 20, 2019

Frenzie added a commit to Frenzie/koreader that referenced this pull request Feb 22, 2019

Frenzie added a commit that referenced this pull request Feb 22, 2019

@poire-z

This comment has been minimized.

Copy link
Contributor

poire-z commented Feb 24, 2019

Revising my judgment about not needing to set defaults :)

I think this multiswipe thingy is wonderful, and makes many things easier. And no other reader must have it, so we might as well set defaults so they are the de-facto standard for the future of e-readers ! :)

So, sharing what I have set and found useful, and the why (for me) of the gestures chosen - so that we can decide quickly which to set so I don't become too accustomed to mine if we decide for others :)

↧ ↥ : Skim to: go towards the bottom screen, bring up that footer progress bar aka Skim.
↧ ↦ : TOC, quick & easy, same horizontal direction as the 2-fingers swipe
↧ ↤ : Bookmarks, quick & easy, same horizontal direction as the 2-fingers swipe
These all first go down towards the footer, so indicating some stuff related to in-document navigation

And north-south or south-north - dunno which fells more logical - to show History

These all first go up towards the top menu, so indicating some stuff related to other books list or switch.
↥ ↧ : History: first go up like you would go to tap for top menu, then bring down the History. (I reckon that for people who swipe down for top menu, the revert may make more sense: bring down the top menu, and up to discard it and bring History.)
↥ ↤ or ↥ ↦ : Open previous document. Not sure about the 2nd swipe direction. 2nd one follows the drag to go back spirit, so it could make sense. But 1st one is a bit harder to do than the 2nd one, so less easy to trigger - and opening another document can be a bit time consuming, so harder might be good in that case.
No idea what to set to the other of the two not chosen for Open previous document.

(In any case, please add ↥ ↤ or ↥ ↦ to the list of preset multiswipe gestures - so we don't need to record them :)

No real opinion (yet) about:
↤ ↦
↦ ↤ (one of these two already decided for Back to previous location I think)
↤ ↥
↦ ↥
↤ ↧
↦ ↧
(just because it's less natural for me to start with a horizontal swipe).

@poire-z

This comment has been minimized.

Copy link
Contributor

poire-z commented Feb 24, 2019

(I reckon that for people who swipe down for top menu, the revert may make more sense: bring down the top menu, and up to discard it and bring History.)

I have set my multiswipe as described above. But after a few hours of using them, and still not having the reflexes, so having to think about them... I feel it is more natural the other way around :| :

↧ ↥ : First swipe brings down the top menu, 2nd swipe releases it and brings some default: History.
↥ ↧ : First swipe brings up stuff from the bottom, 2nd swipe releases it (instead of go towards the bottom screen, bring up that footer progress bar aka Skim).

So, it would feel right for all the others to be inverted too,..
ex: ↥ ↦ : TOC (even if it less easy to do than ↧ ↦)
Althoug people may prefer ↥ ↦ to be go back 10 pages, as it feels related to Skim as it is about browsing pages (may be more related to Skim than my TOC...)

Well, not easy to decide for defaults if I'm not even sure about my own preferences :)

@KenMaltby

This comment has been minimized.

Copy link

KenMaltby commented Feb 24, 2019

In terms of the Gesture Management, the listing of functions/actions that are available for mapping to a gesture would be interesting, at least the "roll out" list. Most would be like "Full Screen Refresh" and present no problems, even if accidently activated. Something like "Factory Reset" would be a different story. Some gestures might best be toggles or have the reverse gestures be a "cancel" of the action.

@Frenzie

This comment has been minimized.

Copy link
Member Author

Frenzie commented Feb 24, 2019

↦ ↤ should be jump to latest bookmark as the companion to back to previous location. (Still to be added to the arsenal.)

I think swipe to follow nearest link could also work as a multiswipe. Fwiw, the traditional Opera/Otter/Vivaldi link gestures are down (open link in new tab) and down up (open link in background tab).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.