Solved GNOME3: Weird scroll wheel behaviour

obsigna

Daemon

Reaction score: 779
Messages: 1,187

I got installed GNOME3 and FreeBSD 12.2-RELEASE-p2, and everything is up to date, with respect to the latest pkg repository.

For example, when I open these forums in Epiphany 3.38.2, then scrolling down using the scroll wheel of the mouse works as expected, but when I want to scroll up, the page is not scrolled, but instead the back button of the browser window is invoked and then I land on the page that I had visited before.

This issues was introduced by the update fom GNOME3 3.28 to GNOME3 3.36/3.38.

Is it possible to adjust the behaviour of the scroll wheel somewhere?
 

Mjölnir

Daemon

Reaction score: 1,103
Messages: 1,578

Does this only happen in the Epiphany browser? Check if that also happens with another browser. Tags to look for in the settings (browser & Gnome): mouse gestures, mouse wheel (or scroll wheel) behaviour. If you do not find anything related, submit a bug report. Besides that, be aware that Gnome3 is commonly considered broken, especially on FreeBSD (Gtk-based alternatives: XfCE & Mate).
 

Snurg

Daemon

Reaction score: 426
Messages: 1,054

My personal experience is that Wayland (respective its libinput library, which has been imported to FreeBSD with 12.2 afaik) breaks a lot of xinput() mappings.

My personal impression is that the Wayland developers' attitude seems "xinput mappings are obsolete stuff, we do not support, and not even care about. Either rewrite your software for Wayland or ditch it."

The more Wayland stuff creeps little step by little step into FreeBSD, the more issues like yours will appear and cause pressure on developers to adapt to Wayland, as most users will just ditch software that is "no longer working".

For my part, I would have been happier if the inclusion of Wayland stuff into FreeBSD could have been postponed until Wayland has matured to some degree.

Edit:
You can edit the xorg.conf so that it does use evdev instead of libinput, so you don't get these problems. But it is a real hassle to do!
 
OP
obsigna

obsigna

Daemon

Reaction score: 779
Messages: 1,187

Does this only happen in the Epiphany browser? Check if that also happens with another browser. Tags to look for in the settings (browser & Gnome): mouse gestures, mouse wheel (or scroll wheel) behaviour. If you do not find anything related, submit a bug report. Besides that, be aware that Gnome3 is commonly considered broken, especially on FreeBSD (Gtk-based alternatives: XfCE & Mate).
I just installed Firefox and I see the same scroll wheel behaviour with this as well.
 

Snurg

Daemon

Reaction score: 426
Messages: 1,054

So this clearly seems to be a mapping problem.
Normally xinput is used to correct or personalize mappings, but, as I said, libinput ignores the xinput settings.
If you get rid of libinput (difficult, as it sometimes is not only hooked via xorg.conf), my personal guess is this nuisance will be gone.
 

Emrion

Aspiring Daemon

Reaction score: 155
Messages: 544

I've had something similar on LXDE. I use xmodmap(1) to neutralize some "mouse buttons" that scrolling makes sometimes click (saw this on xev IIRC). I can find the exact syntax I used if needed.
 

Snurg

Daemon

Reaction score: 426
Messages: 1,054

[USER=54797]Emrion[/USER]
Yes that would be appreciated.
It would be wonderful if it turns out to be possible to fix/work around such issues arising with libinput :)
 
OP
obsigna

obsigna

Daemon

Reaction score: 779
Messages: 1,187

Thanks [USER=50369]Snurg[/USER] and [USER=54797]Emrion[/USER]. Later, I will have a closer look on xinput, libinput and xmodmap. Some more details would be great.
 

Emrion

Aspiring Daemon

Reaction score: 155
Messages: 544

For the moment, I can't access to the system in question. I recall that I used xev to determine what were the buttons that scrolling activated apart the normal ones (4 & 5).

Then, at the startup of LXDE I run: xmodmap -e "pointer = 1 2 3 4 5 0 0"
I assume that the buttons to be neutralized are 6 & 7.

You can also use a file as xmodmap argument to execute the "pointer" command.

I will verify these informations tonight.
 

Emrion

Aspiring Daemon

Reaction score: 155
Messages: 544

After verification, it's: "pointer = 1 2 3 4 5 6 7 0 0 10 11 12"
So that was the buttons 8 & 9 which caused problems in firefox.
 
OP
obsigna

obsigna

Daemon

Reaction score: 779
Messages: 1,187

After verification, it's: "pointer = 1 2 3 4 5 6 7 0 0 10 11 12"
So that was the buttons 8 & 9 which caused problems in firefox.
Yes, this resolved the issues. For testing, I entered that command into the user's terminal. I would like to hook it in the course of the startup process of GNOME3, and it would be best to have this activated for all users. Here GNOME3 is started by the following directive in rc.conf gdm_enable="YES". By chance, do yo have any idea, where this command would preferably be added?
 

Snurg

Daemon

Reaction score: 426
Messages: 1,054

Mine is in .xinitrc.

Edit: Respective my script using xinput, which got useless due to libinput...
Will test later whether this works for me too :) Thanks [USER=54797]Emrion[/USER]
 

Emrion

Aspiring Daemon

Reaction score: 155
Messages: 544

Sadly, I never used GNOME3. I don't know where to put this command in your case, but I'm sure you will find.
 
OP
obsigna

obsigna

Daemon

Reaction score: 779
Messages: 1,187

Sadly, I never used GNOME3. I don't know where to put this command in your case, but I'm sure you will find.
Yes, I found it. For the reference, I added to each user’s autostart directory the following file:
/home/rolf/.config/autostart/scrollwheelmodes.desktop
Code:
[Desktop Entry]
Type=Application
Name=Correct Scroll Wheel Modes
Exec=xmodmap -e "pointer = 1 2 3 4 5 6 7 0 0 10 11 12"
NoDisplay=true

The issue is resolved.

Thank you everybody!
 

Mjölnir

Daemon

Reaction score: 1,103
Messages: 1,578

Yes, I found it. For the reference, I added to each user’s autostart directory the following file:
/home/rolf/.config/autostart/scrollwheelmodes.desktop
Instead, the clean solution is to copy that into /usr/local/etc/xdg/autostart
Then the setting gets applied for all users added in the future as well. XDG is a framework for cross DE configuration, i.e. then this setting applies to all users on all DEs, not only Gnome3.
 
Top