hyprwm / Hyprland

Hyprland is an independent, highly customizable, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
https://hyprland.org
BSD 3-Clause "New" or "Revised" License
19.71k stars 837 forks source link

Mouse doesn't scroll the right amount #6278

Closed kamack38 closed 3 months ago

kamack38 commented 3 months ago

System Info and Version

System/Version info ```sh Hyprland, built from branch main at commit a60c7283e677ed81a466d1c0c864c8a05e192cac (xwayland: verify new xsurf is valid in prop reads). Date: Wed May 29 09:34:25 2024 Tag: v0.40.0-144-ga60c7283, commits: 4750 flags: (if any) System Information: System name: Linux Node name: kamack38-rogstrixg533qs Release: 6.9.2-arch1-1.1-g14 Version: #1 SMP PREEMPT_DYNAMIC Mon, 27 May 2024 06:10:00 +0000 GPU information: 01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GA104M [GeForce RTX 3080 Mobile / Max-Q 8GB/16GB] [10de:249c] (rev a1) (prog-if 00 [VGA controller]) 05:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Cezanne [Radeon Vega Series / Radeon Vega Mobile Series] [1002:1638] (rev c5) (prog-if 00 [VGA controller]) os-release: NAME="Garuda Linux" PRETTY_NAME="Garuda Linux" ID=garuda ID_LIKE=arch BUILD_ID=rolling ANSI_COLOR="38;2;23;147;209" HOME_URL="https://garudalinux.org/" DOCUMENTATION_URL="https://wiki.garudalinux.org/" SUPPORT_URL="https://forum.garudalinux.org/" BUG_REPORT_URL="https://gitlab.com/groups/garuda-linux/" PRIVACY_POLICY_URL="https://terms.archlinux.org/docs/privacy-policy/" LOGO=garudalinux plugins: ======Config-Start====== Config File: /home/kamack38/.config/hypr/hyprland.conf: Read Succeeded # #### Monitor # See https://wiki.hyprland.org/Configuring/Monitors/ monitor=,highrr,auto,1 # monitor=DP-1,disable # Rotate 90deg # monitor=DP-1,highrr,auto,1,transform,1 # Enable vrr # monitor=DP-1,highrr,auto,1,vrr,1 # #### Autostart exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP exec-once = $HOME/.config/hypr/portals.sh exec-once = /usr/lib/polkit-kde-authentication-agent-1 exec-once = hyprpaper exec-once = $HOME/.config/hypr/bar.sh exec-once = dunst exec-once = wl-paste --type text --watch cliphist store # Stores only text data exec-once = wl-paste --type image --watch cliphist store # Stores only image data exec-once = swayidle -w timeout 300 'lock' timeout 600 'hyprctl dispatch dpms off' resume 'hyprctl dispatch dpms on' exec-once = wl-mpris-idle-inhibit # #### Variables # For all categories, see https://wiki.hyprland.org/Configuring/Variables/ input { kb_layout = pl kb_variant = kb_model = kb_options = kb_rules = follow_mouse = 1 accel_profile = flat touchpad { natural_scroll = yes } sensitivity = 0 # -1.0 - 1.0, 0 means no modification. } general { # See https://wiki.hyprland.org/Configuring/Variables/ for more gaps_in = 5 gaps_out = 10 border_size = 2 col.active_border = rgba(38a3a5ff) rgba(57cc99ff) 0deg col.inactive_border = rgba(595959aa) layout = dwindle allow_tearing = false } decoration { # See https://wiki.hyprland.org/Configuring/Variables/ for more rounding = 10 drop_shadow = false shadow_range = 4 shadow_render_power = 3 col.shadow = rgba(1a1a1aee) blur { enabled = true size = 3 passes = 1 new_optimizations = true } } animations { enabled = yes # Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more bezier = myBezier, 0.05, 0.9, 0.1, 1.05 animation = windows, 1, 7, myBezier animation = windowsOut, 1, 7, default, popin 80% animation = border, 1, 10, default animation = fade, 1, 7, default animation = workspaces, 1, 6, default } dwindle { # See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below preserve_split = yes # you probably want this no_gaps_when_only = 2 } master { # See https://wiki.hyprland.org/Configuring/Master-Layout/ for more new_is_master = true no_gaps_when_only = 2 } gestures { # See https://wiki.hyprland.org/Configuring/Variables/ for more workspace_swipe = on workspace_swipe_distance = 300 } misc { vfr = no disable_hyprland_logo = true } # ### Environment variables # #### Nvidia # env LIBVA_DRIVER_NAME,nvidia # env = GBM_BACKEND,nvidia-drm env = __GLX_VENDOR_LIBRARY_NAME,nvidia env = WLR_NO_HARDWARE_CURSORS,1 # export WLR_DRM_DEVICES=/dev/dri/card0 # set to card1 to use nvidia # #### Apps env = QT_QPA_PLATFORM,wayland env = XDG_SESSION_TYPE,wayland env = MOZ_ENABLE_WAYLAND,1 # #### Windowrules # See https://wiki.hyprland.org/Configuring/Window-Rules/ for more windowrulev2 = workspace 4 silent, class:^(discord)$ # Tile rules windowrule = tile, neovide windowrulev2 = tile, class:^(Spotify)$ # Float rules windowrule = float,org.kde.polkit-kde-authentication-agent-1 windowrulev2 = float,class:^(firefoxdeveloperedition)$,title:^(Picture-in-Picture)$ # Firefox PIP fix windowrulev2 = float,title:^(Send File — Dolphin)$ windowrulev2 = float,class:^(org.kde.bluedevilsendfile)$ # Btop - system monitor windowrule = float,system_monitor windowrule = center,system_monitor windowrule = animation slide,system_monitor windowrule = size 1000 760,system_monitor # Waybar - package update windowrule = float,package_update windowrule = center,package_update windowrule = animation slide,package_update # Firefox - passwrod prompt windowrule = float,title:^Password Required windowrule = stayfocused,title:^Password Required windowrule = size 400 150,title:^Password Required windowrule = center,title:^Password Required # Dolphin - new folder windowrule = stayfocused,title:^New Folder — Dolphin # wlogout windowrule = float,wlogout windowrule = fullscreen,wlogout windowrule = noanim,wlogout windowrule = stayfocused,wlogout # Rofi windowrule = float,Rofi windowrule = center,Rofi windowrule = animation none,Rofi windowrule = stayfocused,Rofi # XWayland video bridge windowrulev2 = opacity 0.0 override 0.0 override,class:^(xwaylandvideobridge)$ windowrulev2 = noanim,class:^(xwaylandvideobridge)$ windowrulev2 = nofocus,class:^(xwaylandvideobridge)$ windowrulev2 = noinitialfocus,class:^(xwaylandvideobridge)$ # #### Layerrules bezier = easeOut,0.33, 1, 0.68, 1 animation = layers,1,2,easeOut # Dunst (notifications) layerrule = animation slide,notifications # Rofi (app launcher) layerrule = animation popin,rofi # ##### Vars # See https://wiki.hyprland.org/Configuring/Keywords/ for more $mainMod = SUPER $browser = firefox-developer-edition $private_browser = firefox-developer-edition --private-window $powermenu = wlogout $term = kitty $file_browser = dolphin $system_monitor = $term --class system_monitor -e btop # ## Volume # $raiseVolume = pamixer -i 2 # $lowerVolume = pamixer -d 2 # $muteAudio = pamixer -t $raiseVolume = volume -i 2 $lowerVolume = volume -d 2 $muteAudio = volume -t # $toggleMicMute = pactl list sources | grep -oP "Name: \S+" | grep "input" | cut -d' ' -f2 | xargs -I{} pactl set-source-mute {} toggle $toggleMicMute = microphone -t $raiseMicVolume = microphone -i 2 $lowerMicVolume = microphone -d 2 # ## Brightness # $increaseBrightness = brightnessctl set 5%+ -q # $decreaseBrightness = brightnessctl set 5%- -q $increaseBrightness = brightness set 5%+ -q $decreaseBrightness = brightness set 5%- -q # ##### Binds # Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more bind = $mainMod SHIFT, Q, exit, bind = $mainMod, F1, exec, ~/.config/hypr/gamemode.sh bind = $mainMod SHIFT, Z, exec, toggle_zoom # ## Apps bind = $mainMod, grave, exec, $term bind = $mainMod, E, exec, $file_browser bind = $mainMod, B, exec, $browser bind = $mainMod SHIFT, B, exec, $private_browser bind = $mainMod SHIFT, M, exec, $system_monitor bind = $mainMod, Escape, exec, $powermenu bind = ALT, Space, exec, killall rofi || rofi -show drun -no-default-config -config ~/.config/rofi/main.rasi bind = $mainMod, period, exec, killall rofi || rofi -show emoji -emoji-format "{emoji}" -modi emoji -theme ~/.config/rofi/global/emoji bind = $mainMod, V, exec, cliphist list | rofi -dmenu | cliphist decode | wl-copy # #### Screenshot bind = , Print, exec, grimblast --notify --cursor copysave output $screenshotarea = hyprctl keyword animation "fadeOut,0,0,default"; grimblast --notify copysave area; hyprctl keyword animation "fadeOut,1,4,default" bind = SUPER SHIFT, S, exec, $screenshotarea # ## Window state bind = $mainMod, X, killactive, bind = $mainMod, SPACE, togglefloating, bind = $mainMod, F, fullscreen, 0 bind = $mainMod, M, fullscreen, 1 bind = $mainMod, T, pin, bind = $mainMod, P, pseudo, # dwindle # bind = $mainMod, J, togglesplit, # dwindle # ## Cycling through windows bind = ALT, TAB, cyclenext, bind = ALT SHIFT, TAB, cyclenext, prev # ## Moving window bind = $mainMod MOD5, H, movewindow, l # MOD5 is actually right ALT bind = $mainMod MOD5, left, movewindow, l bind = $mainMod MOD5, J, movewindow, d bind = $mainMod MOD5, down, movewindow, d bind = $mainMod MOD5, K, movewindow, u bind = $mainMod MOD5, up, movewindow, u bind = $mainMod MOD5, L, movewindow, r bind = $mainMod MOD5, right, movewindow, r # ## Moving window through monitors bind = $mainMod SHIFT, H, movewindow, mon:-1 bind = $mainMod SHIFT, L, movewindow, mon:+1 bind = $mainMod SHIFT, left, movewindow, mon:-1 bind = $mainMod SHIFT, rifght, movewindow, mon:+1 # ## Focus bind = $mainMod, Tab, cyclenext, bind = $mainMod, left, movefocus, l bind = $mainMod, H, movefocus, l bind = $mainMod, right, movefocus, r bind = $mainMod, L, movefocus, r bind = $mainMod, up, movefocus, u bind = $mainMod, K, movefocus, u bind = $mainMod, down, movefocus, d bind = $mainMod, J, movefocus, d # ## Focusing monitors bind = $mainMod SHIFT, K, focusmonitor, +1 bind = $mainMod SHIFT, J, focusmonitor, -1 # ## Workspaces bind = $mainMod, 1, workspace, 1 bind = $mainMod, 2, workspace, 2 bind = $mainMod, 3, workspace, 3 bind = $mainMod, 4, workspace, 4 bind = $mainMod, 5, workspace, 5 bind = $mainMod, 6, workspace, 6 bind = $mainMod, 7, workspace, 7 bind = $mainMod, 8, workspace, 8 bind = $mainMod, 9, workspace, 9 bind = $mainMod, 0, workspace, 10 # ## Moving window throughout workspaces bind = $mainMod SHIFT, 1, movetoworkspace, 1 bind = $mainMod SHIFT, 2, movetoworkspace, 2 bind = $mainMod SHIFT, 3, movetoworkspace, 3 bind = $mainMod SHIFT, 4, movetoworkspace, 4 bind = $mainMod SHIFT, 5, movetoworkspace, 5 bind = $mainMod SHIFT, 6, movetoworkspace, 6 bind = $mainMod SHIFT, 7, movetoworkspace, 7 bind = $mainMod SHIFT, 8, movetoworkspace, 8 bind = $mainMod SHIFT, 9, movetoworkspace, 9 bind = $mainMod SHIFT, 0, movetoworkspace, 10 # ## Cycling through workspaces bind = $mainMod, mouse_down, workspace, e+1 bind = $mainMod, TAB, workspace, e+1 bind = $mainMod, mouse_up, workspace, e-1 bind = $mainMod SHIFT, TAB, workspace, e-1 # ## Resizing window bindm = $mainMod, mouse:272, movewindow bindm = $mainMod, mouse:273, resizewindow # ## Window groups bind = $mainMod, G, togglegroup bind = $mainMod, N, changegroupactive, f bind = $mainMod SHIFT, N, changegroupactive, b bind = $mainMod SHIFT, Escape, moveoutofgroup # ## Brightness control binde = , XF86MonBrightnessUp, exec, $increaseBrightness binde = , XF86MonBrightnessDown, exec, $decreaseBrightness # ## Audio keybindings bind = , XF86AudioPlay, exec, playerctl play-pause && mpris-noti bind = , XF86AudioPause, exec, playerctl pause && mpris-noti bind = , XF86AudioStop, exec, playerctl stop && mpris-noti bind = SHIFT, XF86AudioPlay, exec, mpris-noti # Show currently playing song bind = , XF86AudioNext, exec, playerctl next && mpris-noti bind = , XF86AudioPrev, exec, playerctl previous && mpris-noti binde = SHIFT, XF86AudioNext, exec, playerctl position 5+ && mpris-noti binde = SHIFT, XF86AudioPrev, exec, playerctl position 5- && mpris-noti bind = , XF86AudioMute, exec, $muteAudio binde = , XF86AudioRaiseVolume, exec, $raiseVolume binde = , XF86AudioLowerVolume, exec, $lowerVolume binde = SHIFT, XF86AudioRaiseVolume, exec, playerctl volume 0.02+ && mpris-noti binde = SHIFT, XF86AudioLowerVolume, exec, playerctl volume 0.02- && mpris-noti # ## Microphone binde = CTRL, XF86AudioRaiseVolume, exec, $raiseMicVolume binde = CTRL, XF86AudioLowerVolume, exec, $lowerMicVolume bind = , XF86AudioMicMute, exec, $toggleMicMute # Toggle mute on all bind = SHIFT, XF86AudioMicMute, exec, pactl list sources | grep -oP "Name: \S+" | grep "input" | cut -d' ' -f2 | xargs -I{} pactl set-source-mute {} false # Unmute all # ## Launch keybindings bind = , XF86Launch4, exec, asusctl profile -n && notify-send "$(asusctl profile -p)" -r 68 ======Config-End======== ```

Bug or Regression?

Regression

Description

I've noticed that the mouse scroll doesn't scroll the right amount or doesn't work at all. For example scrolling on the waybar changes the volume by 8-10 instead of 2. Additionally, scrolling in kitty doesn't work (scrolls two or three lines and then stops) and in pagers in it.

How to reproduce

I noticed that scrolling by one produces this in wev:

[04:         wl_seat] name: Hyprland
[04:         wl_seat] capabilities: pointer keyboard 
[10:    xdg_toplevel] configure: width: 1280; height: 1404
                      tiled-left tiled-right tiled-top tiled-bottom 
[09:     xdg_surface] configure: serial: 114
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 66475
[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[10:    xdg_toplevel] configure: width: 1280; height: 1404
                      tiled-left tiled-right tiled-top tiled-bottom maximized 
[10:    xdg_toplevel] configure: width: 1265; height: 1384
                      tiled-left tiled-right tiled-top tiled-bottom maximized 
[14:     wl_keyboard] enter: serial: 118; surface: 3
[14:     wl_keyboard] modifiers: serial: 0; group: 0
                      depressed: 00000000
                      latched: 00000000
                      locked: 00000000
[11:  wl_data_device] selection: (cleared)
[10:    xdg_toplevel] configure: width: 1265; height: 1384
                      tiled-left tiled-right tiled-top tiled-bottom maximized activated 
[10:    xdg_toplevel] configure: width: 1261; height: 1380
                      tiled-left tiled-right tiled-top tiled-bottom maximized activated 
[13:      wl_pointer] enter: serial: 121; surface: 3, x, y: 1134.000000, 742.000000
[13:      wl_pointer] frame
[09:     xdg_surface] configure: serial: 115
[14:     wl_keyboard] key: serial: 122; time: 713344; key: 36; state: 0 (released)
                      sym: Return       (65293), utf8: ''
[13:      wl_pointer] axis: time: 716798; axis: 0 (vertical), value: 7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 716804; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 0
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 716807; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 0
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 716811; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 0
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 716814; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 0
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 716820; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 0
[13:      wl_pointer] frame

Everything works on v0.40. Here's the output of doing the same thing:

[08:         wl_seat] name: seat0
[08:         wl_seat] capabilities: pointer keyboard 
[10:    xdg_toplevel] configure: width: 1280; height: 1404
[09:     xdg_surface] configure: serial: 140
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 66475
[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[14:     wl_keyboard] enter: serial: 144; surface: 3
[14:     wl_keyboard] modifiers: serial: 0; group: 0
                      depressed: 00000000
                      latched: 00000000
                      locked: 00000000
[11:  wl_data_device] selection: (cleared)
[13:      wl_pointer] enter: serial: 147; surface: 3, x, y: 1155.000000, 436.000000
[13:      wl_pointer] frame
[10:    xdg_toplevel] configure: width: 1261; height: 1380
                      maximized activated tiled-left tiled-right tiled-top tiled-bottom 
[09:     xdg_surface] configure: serial: 141
[14:     wl_keyboard] key: serial: 148; time: 816931; key: 36; state: 0 (released)
                      sym: Return       (65293), utf8: ''
[13:      wl_pointer] frame
[13:      wl_pointer] frame
[13:      wl_pointer] frame
[13:      wl_pointer] frame
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] axis: time: 818486; axis: 0 (vertical), value: 15.000000
[13:      wl_pointer] frame

Crash reports, logs, images, videos

No response

Agent00Ming commented 3 months ago
[13:      wl_pointer] axis: time: 9355190; axis: 0 (vertical), value: 15.000000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 9356660; axis: 0 (vertical), value: -15.000000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1

what ? version: a60c7283e677ed81a466d1c0c864c8a05e192cac

kamack38 commented 3 months ago
[13:      wl_pointer] axis: time: 9355190; axis: 0 (vertical), value: 15.000000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 9356660; axis: 0 (vertical), value: -15.000000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1

what ? version: a60c728

Yes, as mentioned in the system info section.

Agent00Ming commented 3 months ago

what kind of device do you scroll with because touchpad and mouse scroll wheel events are reported and handled properly on that version (as outlined in https://github.com/hyprwm/Hyprland/issues/6278#issuecomment-2139518756 )

kamack38 commented 3 months ago

I'm using my mouse - Logitech G604.

Agent00Ming commented 3 months ago

Are you sure your mouse's scroll wheel is on the right mode? (advertised as a feature on their website) Because I can't replicate the issue with my hardware.

kamack38 commented 3 months ago

I think it is, because the scroll wheel clearly stutters (by that I mean it's not using the smooth mode) and everything works on the v0.40 version.

Agent00Ming commented 3 months ago

Then good luck with bisecting the commit that broke it for you. https://wiki.hyprland.org/Crashes-and-Bugs/#bisecting-an-issue

kamack38 commented 3 months ago

Using binary-search it should take no more than 8 builds.

kamack38 commented 3 months ago

I traced the first bad commit to be 121d3a72. Except here scrolling on waybar doesn't work at all and scrolling inside kitty scrolls by one line.

Agent00Ming commented 3 months ago

how does the behaviour change after 3ac0e7ead1434c172f276a12f81da1eeb0dc4491?

Ciel-MC commented 3 months ago

how does the behaviour change after 3ac0e7e?

I just tested the commit before this, and it seems like xwayland apps work properly, and kitty scrolls line by line, I will test the commit now

Edit: Yep this commit is part of the issue, after the commit, scrolling on both Kitty and xwayland apps only works on the initial burst. But it seems like Kitty was already a little broken before this(scrolls only one line)

Agent00Ming commented 3 months ago

that's strange because 3ac0e7ead1434c172f276a12f81da1eeb0dc4491 was added because some wayland clients could not see a difference between touchpad scrolling and scroll wheel scrolling (namely blender which behaved weird without that)

Ciel-MC commented 3 months ago

that's strange because 3ac0e7e was added because some wayland clients could not see a difference between touchpad scrolling and scroll wheel scrolling (namely blender which behaved weird without that)

Blender behaves weirdly even with that. The first scroll both zooms and moves camera whilst continuous scrolling only moves camera(like trackpad would I suppose)

Edit: Video :3 https://github.com/hyprwm/Hyprland/assets/47144701/cd1c0bac-923a-44a6-82fa-c309e69168f5

Agent00Ming commented 3 months ago

I can't repro either of those lol, must be some strange hardware then. Can you get a WAYLAND_DEBUG=1 blender > sway_blender_wheel_scrolling.log 2>&1 in sway/hyprland and wheel/touchpad variations so I can see what's up?

Ciel-MC commented 3 months ago

I can't repro either of those lol, must be some strange hardware then. Can you get a WAYLAND_DEBUG=1 blender > sway_blender_wheel_scrolling.log 2>&1 in sway/hyprland and wheel/touchpad variations so I can see what's up?

I don't have touchpad D: but sure, with the patch right? (See video of blender in prev. comment)

Ciel-MC commented 3 months ago

sway_blender_wheel_scrolling.log Here, scrolled up for bit, scrolled down for a bit, scrolled a few steps(start and stop), and lastly up and down

Agent00Ming commented 3 months ago

might be easier if you test wev 2>&1 | grep axis > hyprland_wev_scroll.log in both hyprland and sway

Ciel-MC commented 3 months ago

might be easier if you test wev 2>&1 | grep axis > hyprland_wev_scroll.log in both hyprland and sway

But I don't have sway ): at least I think I uninstalled it since I last used it like a year ago?

Agent00Ming commented 3 months ago
well I can't repro the issue at all :P ``` [ming@wrangler ~]$ wev 2>&1 | grep axis [13: wl_pointer] axis: time: 15260343; axis: 0 (vertical), value: 1.343750 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260350; axis: 0 (vertical), value: 0.976562 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260357; axis: 0 (vertical), value: 0.855469 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260364; axis: 0 (vertical), value: 0.976562 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260372; axis: 0 (vertical), value: 0.730469 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260379; axis: 0 (vertical), value: 0.609375 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260386; axis: 0 (vertical), value: 0.609375 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260393; axis: 0 (vertical), value: 0.488281 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260400; axis: 0 (vertical), value: 0.609375 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260407; axis: 0 (vertical), value: 0.367188 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260414; axis: 0 (vertical), value: 0.242188 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260436; axis: 0 (vertical), value: -0.121094 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15260455; axis: 0 (vertical), value: 0.000000 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis_stop: time: 15260455; axis: 0 (vertical) [13: wl_pointer] axis: time: 15260455; axis: 1 (horizontal), value: 0.000000 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis_stop: time: 15260455; axis: 1 (horizontal) [13: wl_pointer] axis: time: 15261291; axis: 0 (vertical), value: -1.464844 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261298; axis: 0 (vertical), value: -1.343750 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261306; axis: 0 (vertical), value: -1.343750 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261313; axis: 0 (vertical), value: -0.855469 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261320; axis: 0 (vertical), value: -1.343750 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261327; axis: 0 (vertical), value: -0.855469 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261334; axis: 0 (vertical), value: -0.855469 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261341; axis: 0 (vertical), value: -0.367188 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261348; axis: 0 (vertical), value: -0.242188 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis: time: 15261361; axis: 0 (vertical), value: 0.000000 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis_stop: time: 15261361; axis: 0 (vertical) [13: wl_pointer] axis: time: 15261361; axis: 1 (horizontal), value: 0.000000 [13: wl_pointer] axis_source: 1 (finger) [13: wl_pointer] axis_stop: time: 15261361; axis: 1 (horizontal) [13: wl_pointer] axis: time: 15264319; axis: 0 (vertical), value: 15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1 [13: wl_pointer] axis: time: 15264341; axis: 0 (vertical), value: 15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1 [13: wl_pointer] axis: time: 15264359; axis: 0 (vertical), value: 15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1 [13: wl_pointer] axis: time: 15264383; axis: 0 (vertical), value: 15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1 [13: wl_pointer] axis: time: 15264405; axis: 0 (vertical), value: 15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1 [13: wl_pointer] axis: time: 15265158; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265166; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265177; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265186; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265201; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265219; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 [13: wl_pointer] axis: time: 15265260; axis: 0 (vertical), value: -15.000000 [13: wl_pointer] axis_source: 0 (wheel) [13: wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1 ```
Ciel-MC commented 3 months ago

hyprland_wev_scroll.log Corresponding with my actions, it seems like discrete is 1 the moment I scroll down, and -1 the moment I scroll up, but 0 all the when during the scroll

Agent00Ming commented 3 months ago

my bet is that it's high-res scrolling of some kind not being handled in the way that normal wheel scrolling is handled

Ciel-MC commented 3 months ago

my bet is that it's high-res scrolling of some kind not being handled in the way that normal wheel scrolling is handled

Just tried out KDE because I had that installed :p. It seems like it's just 1 every time downwards scroll, start or continuous, and -1 for downwards. Not sure what hi-res scrolling is(does it allow for "smooth" scrollwheel when the hardware supports it? I wish there's a mouse like that)

Ciel-MC commented 3 months ago

Just got sway, exactly the same as KDE(doesn't seem to use hi-res scrolling, whatever that is?) sway_wev_scroll.log

Agent00Ming commented 3 months ago

wev 2>&1 | grep wl_pointer > hyprland_wev.log and avoid moving your mouse when scrolling

Ciel-MC commented 3 months ago

wev 2>&1 | grep wl_pointer > hyprland_wev.log and avoid moving your mouse when scrolling

Meow Seems like the only difference is frame sway_wev_scroll.log

Agent00Ming commented 3 months ago

and doing the same on hyprland?

Ciel-MC commented 3 months ago

and doing the same on hyprland?

Looks like it sends a lot of 0s(or less frames?), which should've been 1/-1 hyprland_wev_scroll.log

darkiox commented 3 months ago

Don't know if this can help: I have a Logitech G502 Lightspeed and when it is using the wireless dongle, this issue occurs in XWayland apps (only scrolls once, have to stop scrolling and then scroll again, and scrolls a single time again). But if I plug in the mouse directly to cable, the problem is gone and scrolling works again. (i'm on 6868a39)

Ciel-MC commented 3 months ago

Don't know if this can help: I have a Logitech G502 Lightspeed and when it is using the wireless dongle, this issue occurs in XWayland apps (only scrolls once, have to stop scrolling and then scroll again, and scrolls a single time again). But if I plug in the mouse directly to cable, the problem is gone and scrolling works again. (i'm on 6868a39)

Im not dev but I can probably guess that they want the logs as I had above in wireless dongle vs plugged in directly for comparison.

Also Im using powerplay so I suppose its also a dongle, which would make sense

Agent00Ming commented 3 months ago

wireless mice? might be onto something

thomab commented 3 months ago

I have the same mouse model as darkiox and can confirm plugging it in works around the issue for me too.

darkiox commented 3 months ago

Alrighty, got the wev logs. On the dongle I did a full scroll up and then a full scroll down, only the first event shows of each shows 1 or -1 on discrete. On wired it works normally.

hyprland_wev_scroll_wired.log hyprland_wev_scroll_dongle.log

Agent00Ming commented 3 months ago

managed to repro with an old wireless mouse I didn't use for a long time and I might have an idea where the issue stems from

Agent00Ming commented 3 months ago

test out the PR, works for me but the scrolling sensitivity might be a little high

darkiox commented 3 months ago

PR also works for me.

kamack38 commented 3 months ago

This didn't fix all the issues for me. Scrolling on the waybar PulseAudio module still doesn't work (scrolling once changes the volume multiple times) and the scroll itself is not consistent, i.e. scrolling up and down sometimes differs from the original position (one event more is emitted). The results below are the events caught by wev when scrolling "by one". As you can see, even though I scrolled the same amount, the events emitted are different.


[13:      wl_pointer] axis: time: 1261739; axis: 0 (vertical), value: -7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1261746; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1261749; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1261753; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1261755; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1261758; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264698; axis: 0 (vertical), value: 7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264710; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264717; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264721; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264726; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1264731; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267535; axis: 0 (vertical), value: -7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267541; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267545; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267549; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267551; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1267554; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270170; axis: 0 (vertical), value: 7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270180; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270187; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270190; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270195; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1270199; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1271018; axis: 0 (vertical), value: -7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1271030; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1271036; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1271043; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1271046; axis: 0 (vertical), value: -1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: -1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1274574; axis: 0 (vertical), value: 7.500000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1274581; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1274585; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1274589; axis: 0 (vertical), value: 1.875000
[13:      wl_pointer] axis_source: 0 (wheel)
[13:      wl_pointer] axis_stop: axis: 0 (vertical), discrete: 1
[13:      wl_pointer] frame
[13:      wl_pointer] axis: time: 1274593; axis: 0 (vertical), value: 1.875000
Agent00Ming commented 3 months ago

that's just how often scroll events are reported by your mouse, not much we can do here except pass it to the client... sway does who knows what with the scroll inputs and sending empty frames. kde just doesn't handle discrete scrolling at all. Read more on the topic of high resolution scrolling here

Ciel-MC commented 3 months ago

Sens is definitely too high, in Okular I basically zoom from smol to huge in one step, something needs to change lol. Why did it work well before?

darkiox commented 3 months ago

Decided to take a look using xev. I also commented on the PR that each scroll was sending 5/6 events, and can replicate this when scrolling on a xev window (this was only 1 scroll of the wheel)

ButtonPress event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736533, (546,690), root:(4192,733),
    state 0x10, button 5, same_screen YES

ButtonRelease event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736533, (546,690), root:(4192,733),
    state 0x1010, button 5, same_screen YES

ButtonPress event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736539, (546,690), root:(4192,733),
    state 0x10, button 5, same_screen YES

ButtonRelease event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736539, (546,690), root:(4192,733),
    state 0x1010, button 5, same_screen YES

ButtonPress event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736542, (546,690), root:(4192,733),
    state 0x10, button 5, same_screen YES

ButtonRelease event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736542, (546,690), root:(4192,733),
    state 0x1010, button 5, same_screen YES

ButtonPress event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736546, (546,690), root:(4192,733),
    state 0x10, button 5, same_screen YES

ButtonRelease event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736546, (546,690), root:(4192,733),
    state 0x1010, button 5, same_screen YES

ButtonPress event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736548, (546,690), root:(4192,733),
    state 0x10, button 5, same_screen YES

ButtonRelease event, serial 31, synthetic NO, window 0x1e00001,
    root 0x3b7, subw 0x0, time 35736548, (546,690), root:(4192,733),
    state 0x1010, button 5, same_screen YES
kamack38 commented 2 months ago

This issue still persists on the master. Can the high-res scrolling be disabled?