baca icon indicating copy to clipboard operation
baca copied to clipboard

Fix glitchy mousewheel scrolling

Open xiota opened this issue 2 years ago • 8 comments

Closes #10

xiota avatar Jun 04 '23 05:06 xiota

@xiota I tested this, but this produce weird behaviour on my machine, one scroll mouse wheel will scroll 2 lines?

wustho avatar Jun 07 '23 00:06 wustho

one scroll mouse wheel will scroll 2 lines?

On my computer, as far as I can tell, this works properly. Only one line at a time. How does the Textual demo work on your computer? (On my computer, the demo runs with python -m textual.)

xiota avatar Jun 07 '23 02:06 xiota

one scroll mouse wheel will scroll 2 lines?

On my computer, as far as I can tell, this works properly. Only one line at a time. How does the Textual demo work on your computer? (On my computer, the demo runs with python -m textual.)

Tried it, indeed textual demo is also behaving weird. Seems like issue with my os setup or broken mouse/trackpad. Let me try it on other machine.

wustho avatar Jun 07 '23 02:06 wustho

I'm using Textual v0.27.0. Looks like baca reqs specify Textual v0.16.0. Glitchy scroll behavior seems to result from some change in Textual v0.17.0.

xiota avatar Jun 08 '23 03:06 xiota

@xiota maybe we should raise this glitchy issue to textual?

wustho avatar Jun 08 '23 04:06 wustho

maybe we should raise this glitchy issue to textual?

I agree. I'll check to make sure it isn't already reported. If it isn't, I'll open a new issue and @ you so you can add info about the 2-line scrolling.

xiota avatar Jun 08 '23 04:06 xiota

@xiota Thanks, mate. No worries about 2 line scroll tho, I think it has to do with signal being passed to parent widget, so the app and screen get scrolled then produces 2 line scroll. Might be also textual issue, but let me look at it for a while.

wustho avatar Jun 08 '23 04:06 wustho

Did not get around to opening an issue upstream, but this seems to be a definite API change in 0.17.0 (2023-03-29) because the upstream examples were modified. Force pushed to sync with main. Changed textual requirement to >=0.17.0 <1.0.0. Manually edited pyproject.toml. Is that the correct way?

Note: I'm adding the changes for contents.py to aur/baca-ereader-git because Arch Linux is definitely affected by this.

xiota avatar Nov 11 '23 20:11 xiota