feat: Option to disable touch scrolling
This is a merge request closing #1246
This adds a small button to quickly activate/deactivate the touch scrolling on the canvas. For many situations, this is a very good workaround to inconsistent palm rejection.
Remaining to do:
- [ ] the corresponding icon is black regardless of the theme. I couldn't figure out what takes care of the color of icons
- [ ] activating inertial scrolling make mostly useless
Outside those two points, it has been working flawlessly on my (admittedly outdated) fork for the last 6 months.
For the first point, maybe check https://wiki.gnome.org/HowDoI(2f)CreateSymbolicIconsThatChangeColorAccordingToTheme.html (it's for gtk3 but I think it should suffice).
I think that's the absence of fill color that play a role in the theme working.
For example, there is a fill="#2e3436" in https://github.com/flxzt/rnote/blob/33fdab032faaf3bee41e9ed65e286f04988a00b0/crates/rnote-ui/data/icons/scalable/actions/add-page-symbolic.svg?short_path=1fc3354
I'm not sure I understand the second point. Can you explain in more detail ?
think that's the absence of fill color that play a role in the theme working. For example, there is a fill="#2e3436" in https://github.com/flxzt/rnote/blob/33fdab032faaf3bee41e9ed65e286f04988a00b0/crates/rnote-ui/data/icons/scalable/actions/add-page-symbolic.svg?short_path=1fc3354
That was my understanding as well. But it didn't look good without the gray part. It seems to be possible to have some styling because some icons do it anyway... I'll look at the gnome documentation you linked because it seems to hold the answer I'm looking for.
I'm not sure I understand the second point. Can you explain in more detail ?
From what I understand, around here I'm "blocking" all events linked to drag motions. But apparently if it comes from the intertial/kinetic scrolling, it goes somewhere else (I'm not sure where). In practice this means that gtk still recognize the touch input and generate inertial scrolling for them which is then not ignored. So with inertial scrolling activated, when the palm rejection fails it still move the canvas (even though you can't really move it "willingly").
A month later, I finally had time to work on this again ^^'
As far as I can tell, all the problems I listed above are fixed. I ended up changing the icon to another one straight from the gtk repository because I couldn't make it follow the theme...
Could this maybe be looked at again? It would be practical to have this feature.
Well, I far as I can tell, my branch works (I've been using it since my last comment, and it hasn't crashed on me).
I need to rebase anyway because this is the version of rnote that I use, and an update is long overdue. I'll try to do that this weekend if I get the time.
just so you know everything has been rebased and is apparently working.