Chromium wayland mouse issues

garuda-inxi
System:
  Kernel: 5.19.8-269-tkg-bmq arch: x86_64 bits: 64 compiler: gcc v: 12.2.0
    parameters: intel_pstate=passive intel_pstate=passive
    BOOT_IMAGE=/@/boot/vmlinuz-linux-linux-tkg-bmq-generic_v3
    root=UUID=53e270ad-dfd5-4874-a125-69d21ada6b8d rw [email protected]
    rd.udev.log_priority=3 vt.global_cursor_default=0 loglevel=3
    sysrq_always_enabled=1 amdgpu.ppfeaturemask=0xffffffff nowatchdog
    nmi_watchdog=0 [email protected]\boot\initramfs-linux-tkg-bmq-generic_v3.img
  Desktop: KDE Plasma v: 5.25.5 tk: Qt v: 5.15.6 wm: kwin_wayland vt: 2
    dm: SDDM Distro: Garuda Linux base: Arch Linux
Machine:
  Type: Desktop Mobo: ASRock model: X470 Taichi serial: <superuser required>
    UEFI: American Megatrends v: P4.90 date: 05/18/2022
Battery:
  Device-1: hidpp_battery_0 model: Logitech Wireless Mouse MX Master 3
    serial: <filter> charge: 100% (should be ignored) rechargeable: yes
    status: discharging
CPU:
  Info: model: AMD Ryzen 5 5600X bits: 64 type: MT MCP arch: Zen 3 gen: 4
    built: 2021-22 process: TSMC n7 (7nm) family: 0x19 (25) model-id: 0x21 (33)
    stepping: 2 microcode: 0xA20120A
  Topology: cpus: 1x cores: 6 tpc: 2 threads: 12 smt: enabled cache:
    L1: 384 KiB desc: d-6x32 KiB; i-6x32 KiB L2: 3 MiB desc: 6x512 KiB
    L3: 32 MiB desc: 1x32 MiB
  Speed (MHz): avg: 3757 high: 4478 min/max: 2200/4650 boost: enabled
    scaling: driver: acpi-cpufreq governor: performance cores: 1: 3597 2: 4478
    3: 3715 4: 3717 5: 3599 6: 3712 7: 3700 8: 3845 9: 3628 10: 3700 11: 3700
    12: 3700 bogomips: 88898
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  Vulnerabilities:
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data status: Not affected
  Type: retbleed status: Not affected
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via
    prctl
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer
    sanitization
  Type: spectre_v2 mitigation: Retpolines, IBPB: conditional, IBRS_FW,
    STIBP: always-on, RSB filling, PBRSB-eIBRS: Not affected
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: AMD Navi 22 [Radeon RX 6700/6700 XT/6750 XT / 6800M]
    vendor: Gigabyte driver: amdgpu v: kernel arch: RDNA-2 code: Navi-2x
    process: TSMC n7 (7nm) built: 2020-22 pcie: gen: 4 speed: 16 GT/s
    lanes: 16 ports: active: DP-1,HDMI-A-1 empty: DP-2,HDMI-A-2
    bus-ID: 10:00.0 chip-ID: 1002:73df class-ID: 0300
  Display: wayland server: X.org v: 1.21.1.4 with: Xwayland v: 22.1.3
    compositor: kwin_wayland driver: X: loaded: amdgpu
    unloaded: modesetting,radeon alternate: fbdev,vesa gpu: amdgpu
    d-rect: 3584x864 display-ID: 0
  Monitor-1: DP-1 pos: primary,left res: 2048x864 size: N/A modes: N/A
  Monitor-2: HDMI-A-1 pos: right res: 1536x864 size: N/A modes: N/A
  OpenGL: renderer: AMD Radeon RX 6700 XT (navy_flounder LLVM 14.0.6 DRM
    3.47 5.19.8-269-tkg-bmq) v: 4.6 Mesa 22.1.7 direct render: Yes
Audio:
  Device-1: AMD Navi 21/23 HDMI/DP Audio driver: snd_hda_intel v: kernel
    pcie: gen: 4 speed: 16 GT/s lanes: 16 bus-ID: 10:00.1 chip-ID: 1002:ab28
    class-ID: 0403
  Device-2: AMD Starship/Matisse HD Audio vendor: ASRock
    driver: snd_hda_intel v: kernel pcie: gen: 4 speed: 16 GT/s lanes: 16
    bus-ID: 12:00.4 chip-ID: 1022:1487 class-ID: 0403
  Sound Server-1: ALSA v: k5.19.8-269-tkg-bmq running: yes
  Sound Server-2: sndio v: N/A running: no
  Sound Server-3: PulseAudio v: 16.1 running: no
  Sound Server-4: PipeWire v: 0.3.57 running: yes
Network:
  Device-1: Intel Dual Band Wireless-AC 3168NGW [Stone Peak] driver: iwlwifi
    v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 08:00.0
    chip-ID: 8086:24fb class-ID: 0280
  IF: wlp8s0 state: down mac: <filter>
  Device-2: Intel I211 Gigabit Network vendor: ASRock driver: igb v: kernel
    pcie: gen: 1 speed: 2.5 GT/s lanes: 1 port: d000 bus-ID: 0a:00.0
    chip-ID: 8086:1539 class-ID: 0200
  IF: enp10s0 state: up speed: 1000 Mbps duplex: full mac: <filter>
  IF-ID-1: anbox0 state: down mac: <filter>
Bluetooth:
  Device-1: Edimax Bluetooth Adapter type: USB driver: btusb v: 0.8
    bus-ID: 1-8:5 chip-ID: 7392:c611 class-ID: e001 serial: <filter>
  Report: bt-adapter ID: hci0 rfk-id: 1 state: up address: <filter>
Drives:
  Local Storage: total: 2.96 TiB used: 3.91 TiB (132.4%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:3 vendor: Samsung model: SSD 980 1TB
    size: 931.51 GiB block-size: physical: 512 B logical: 512 B
    speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter> rev: 1B4QFXO7
    temp: 37.9 C scheme: GPT
  ID-2: /dev/nvme1n1 maj-min: 259:0 vendor: Samsung model: SSD 970 EVO
    250GB size: 232.89 GiB block-size: physical: 512 B logical: 512 B
    speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter> rev: 2B2QEXE7
    temp: 35.9 C scheme: GPT
  ID-3: /dev/sda maj-min: 8:0 vendor: Seagate model: ST2000DX002-2DV164
    size: 1.82 TiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
    type: HDD rpm: 7200 serial: <filter> rev: CC41 scheme: GPT
Partition:
  ID-1: / raw-size: 931.22 GiB size: 931.22 GiB (100.00%) used: 823.49 GiB
    (88.4%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:5
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%) used: 51.9 MiB
    (17.3%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:4
  ID-3: /home raw-size: 931.22 GiB size: 931.22 GiB (100.00%) used: 823.49
    GiB (88.4%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:5
  ID-4: /var/log raw-size: 931.22 GiB size: 931.22 GiB (100.00%) used: 823.49
    GiB (88.4%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:5
  ID-5: /var/tmp raw-size: 931.22 GiB size: 931.22 GiB (100.00%) used: 823.49
    GiB (88.4%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:5
Swap:
  Kernel: swappiness: 133 (default 60) cache-pressure: 50 (default 100)
  ID-1: swap-1 type: zram size: 31.27 GiB used: 0 KiB (0.0%) priority: 100
    dev: /dev/zram0
Sensors:
  System Temperatures: cpu: 47.6 C mobo: 36.0 C gpu: amdgpu temp: 55.0 C
    mem: 58.0 C
  Fan Speeds (RPM): cpu: 0 fan-2: 1834 fan-3: 0 fan-4: 0 fan-5: 0
    gpu: amdgpu fan: 0
  Power: 12v: N/A 5v: N/A 3.3v: 3.18 vbat: 3.28 gpu: amdgpu watts: 27.00
Info:
  Processes: 440 Uptime: 12m wakeups: 2 Memory: 31.27 GiB used: 14.3 GiB
  (45.7%) Init: systemd v: 251 default: graphical tool: systemctl
  Compilers: gcc: 12.2.0 clang: 14.0.6 Packages: 2462 pacman: 2440 lib: 591
  flatpak: 22 Shell: fish v: 3.5.1 default: Bash v: 5.1.16
  running-in: alacritty inxi: 3.3.20
Garuda (2.6.7-1):
  System install date:     2022-05-22
  Last full system update: 2022-09-11
  Is partially upgraded:   No
  Relevant software:       NetworkManager
  Windows dual boot:       Probably (Run as root to verify)
  Snapshots:               Snapper
  Failed units:            systemd-networkd-wait-online.service

Any chromium-based browser( tried chromium and vivaldi) has broken mouse support where the mouse pointer does not correspond with whats actually being selected in the browser

for example, if you have a link in the middle of the page moving the cursor over the link and click while actually clicking somewhere else in the webpage (or browser interface so its not web page specific)

Interesting issue. In a VM I could argue it is well possible to get that type of behaviour but on a real machine it's quite weird I admit.

So if running Xorg you don't have the issue?
And if running non-Chrome based browsers under Wayland all is good?

1 Like

yeah on x it works fine haven't tried running any non-chrome browser with wayland need to see how that's done. but running any chrome-based browser without the ozone Wayland flag set (meaning it will run with xwayland) works fine also but it will be blurry on KDE due to xwayland scaling currently being broken on 5.25.

EDIT: firedragon seems to not be affected by this

This is cause Firedragon rocks. :smiley:
No seriously it does! But I understand totally you would prefer a Chrome-based browser, so assuming you want to pursue this problem do you use any scaling in native Wayland Chrome-based browsers?
Scaling is not perfect in Wayland, I have had issues with Firedragon (DOH! loll) when scaling it, although a lot more subtle than what you describe.

The problem (of one) with Wayland is there are a few quirks here and there... I experience a couple and sometimes there is no escape. I have not tried any other browser than Firedragon under Wayland, maybe I too have the same issue, in which case there is good chances this would be upstream.

I'm willing to install Chromium and take a look but it may take a couple of days. If you can wait that long...

2 Likes

Closest I found to a upstream issue is this 1350024 - chromium - An open-source project to help move the web forward. - Monorail

but yes this may be a scaling issues (haven't been able to confirm though) where If you have one displayed scaled differently in kde display settings.

That could be helpful I have asked around and as far as I can tell not many people are running into this which I find strange as most people use some form of a chromium based browser though the amount that use wayland and specficly set up there browser to run with wayland ( i think most if not all chromium browsers still defualt to Xwayland) might be low

anyway If you do try to reproduce this you can try running your chromium browser of choice with these flags `--enable-features=UseOzonePlatform --ozone-platform=wayland

Cool, I'll keep you posted shortly, man. I'm curious to see whether I can reproduce this or not!

Did you try both Wayland and XWayland?
https://wiki.archlinux.org/title/Chromium#Native_Wayland_support

Yeah that's what i was saying with chromium --enable-features=UseOzonePlatform --ozone-platform=wayland I have the mouse issues with chromium --enable-features=UseOzonePlatform --ozone-platform=x11 (Xwayland) mouse input works fine but everything is blurry due to KDE plasma poor Xwayland scaling

Sadly, when I run chromium --enable-features=UseOzonePlatform --ozone-platform=wayland all is fine. Mouse pointer behaves, clicks and renders 100% correct.

I have 1 monitor, using native 4K rez with default 96 DPI.
AMD 6500 XT.

Running chromium --enable-features=UseOzonePlatform --ozone-platform=x11 behaves exact same and nothing is blurry.

1 Like

well the blurriness only happens if you change the kde scaling and is a known kde issue that is being fixed in 5.26

EDIT: found a article on it but couldn't find the bug report This week in KDE: non-blurry XWayland apps! – Adventures in Linux and KDE

as for the mouse pointer issues im not completely sure if its related to scaling or not. I have tried setting 100% scaling on my primary monitor (normally use 125% on my monitor and 250% on my 4k tv) and I can still reproduce the issue on chromium 105.0.5195.102-2 from the arch repos.

I still need to test if setting scaling to 100% on both monitors make a difference and also if only running one monitor makes a difference.

1 Like

Yeah sorry about the blurriness, I did change scaling but not when using XWayland, only when launching chromium with Wayland.

I also tried zooming within the window (CTRL-MOUSE_WHEEL), still fine.

I do not have a 2nd monitor so if you succeed testing only one that would be good to compare. However now after these tests I also don't really think it is scaling related. I would also be surprised 1 monitor vs 2 would make a difference, it seems related to window rendering of some sort.

Maybe transparency, KDE blur, KVantum blur and that stuff?
I use defaults from Garuda on that.

3 Likes

good point something else to check when I get a chance is desktop effects or kwin scripts things like that

EDIT: FWIW

qdbus org.kde.KWin /KWin supportInformation
KWin Support Information:
The following information should be used when requesting support on e.g. https://forum.kde.org.
It provides information about the currently running instance, which options are used,
what OpenGL driver and which effects are running.
Please post the information provided underneath this introductory text to a paste bin service
like https://paste.kde.org instead of pasting into support threads.

==========================

Version
=======
KWin version: 5.25.5
Qt Version: 5.15.6
Qt compile version: 5.15.6
XCB compile version: 1.15

Operation Mode: Xwayland

Build Options
=============
KWIN_BUILD_DECORATIONS: yes
KWIN_BUILD_TABBOX: yes
KWIN_BUILD_ACTIVITIES: yes
HAVE_X11_XCB: yes
HAVE_EPOXY_GLX: yes
HAVE_WAYLAND_EGL: yes

X11
===
Vendor: The X.Org Foundation
Vendor Release: 12201003
Protocol Version/Revision: 11/0
SHAPE: yes; Version: 0x11
RANDR: yes; Version: 0x14
DAMAGE: yes; Version: 0x11
Composite: yes; Version: 0x4
RENDER: yes; Version: 0xb
XFIXES: yes; Version: 0x50
SYNC: yes; Version: 0x31
GLX: yes; Version: 0x0

Decoration
==========
Plugin: org.kde.bismuth.decoration
Theme:
Plugin recommends border size: Normal
onAllDesktopsAvailable: true
alphaChannelSupported: true
closeOnDoubleClickOnMenu: false
decorationButtonsLeft: 5, 4, 3
decorationButtonsRight:
borderSize: 3
gridUnit: 10
font: Fira Sans,11,-1,5,57,0,0,0,0,0,Medium
smallSpacing: 2
largeSpacing: 10

Platform
==========
Name: DRM
Active: true
Atomic Mode Setting on GPU 0: true

Cursor
======
themeName: material_light_cursors
themeSize: 32

Options
=======
focusPolicy: 1
xwaylandCrashPolicy:
xwaylandMaxCrashCount: 3
nextFocusPrefersMouse: false
clickRaise: true
autoRaise: true
autoRaiseInterval: 1450
delayFocusInterval: 900
shadeHover: false
shadeHoverInterval: 250
separateScreenFocus: true
activeMouseScreen: true
placement: 6
focusPolicyIsReasonable: true
borderSnapZone: 10
windowSnapZone: 10
centerSnapZone: 0
snapOnlyWhenOverlapping: false
rollOverDesktops: true
focusStealingPreventionLevel: 1
operationTitlebarDblClick: 5000
operationMaxButtonLeftClick: 5000
operationMaxButtonMiddleClick: 5015
operationMaxButtonRightClick: 5014
commandActiveTitlebar1: 0
commandActiveTitlebar2: 28
commandActiveTitlebar3: 2
commandInactiveTitlebar1: 4
commandInactiveTitlebar2: 28
commandInactiveTitlebar3: 2
commandWindow1: 7
commandWindow2: 8
commandWindow3: 8
commandWindowWheel: 28
commandAll1: 10
commandAll2: 3
commandAll3: 14
keyCmdAllModKey: 16777250
condensedTitle: false
electricBorderMaximize: true
electricBorderTiling: true
electricBorderCornerRatio: 0.25
borderlessMaximizedWindows: true
killPingTimeout: 5000
hideUtilityWindowsForInactive: false
compositingMode: 1
useCompositing: true
hiddenPreviews: 1
glSmoothScale: 2
glStrictBinding: false
glStrictBindingFollowsDriver: true
glPreferBufferSwap: 101
glPlatformInterface: 2
windowsBlockCompositing: true
latencyPolicy:
renderTimeEstimator:

Screen Edges
============
desktopSwitching: false
desktopSwitchingMovingClients: false
cursorPushBackDistance: 1x1
timeThreshold: 150
reActivateThreshold: 350
actionTopLeft: 0
actionTop: 0
actionTopRight: 0
actionRight: 0
actionBottomRight: 0
actionBottom: 0
actionBottomLeft: 4
actionLeft: 0

Screens
=======
Multi-Head: no
Active screen follows mouse:  yes
Number of Screens: 2

Screen 0:
---------
Name: DP-1
Geometry: 0,0,2048x864
Scale: 1.25
Refresh Rate: 74991
Adaptive Sync: incapable
Screen 1:
---------
Name: HDMI-A-1
Geometry: 2132,0,1536x864
Scale: 2.5
Refresh Rate: 60000
Adaptive Sync: incapable

Compositing
===========
Compositing is active
Compositing Type: OpenGL
OpenGL vendor string: AMD
OpenGL renderer string: AMD Radeon RX 6700 XT (navy_flounder, LLVM 14.0.6, DRM 3.47, 5.19.8-269-tkg-bmq)
OpenGL version string: 4.6 (Core Profile) Mesa 22.1.7
OpenGL platform interface: EGL
OpenGL shading language version string: 4.60
Driver: Unknown
GPU class: Unknown
OpenGL version: 4.6
GLSL version: 4.60
Mesa version: 22.1.7
Linux kernel version: 5.19.8
Direct rendering: Requires strict binding: no
GLSL shaders:  yes
Texture NPOT support:  yes
Virtual Machine:  no
OpenGL 2 Shaders are used

Loaded Effects:
---------------
kwin4_effect_tv
kwin4_effect_windowaperture
kwin4_effect_translucency
kwin4_effect_sessionquit
kwin4_effect_morphingpopups
kwin4_effect_maximize
kwin4_effect_logout
kwin4_effect_login
kwin4_effect_fullscreen
kwin4_effect_frozenapp
kwin4_effect_fadingpopups
kwin4_effect_dimscreen
kwin4_effect_dialogparent
colorpicker
blendchanges
screenshot
snaphelper
trackmouse
screenedge
zoom
slidingpopups
magiclamp
slide
slideback
sheet
desktopgrid
highlightwindow
overview
windowview
wobblywindows
blur
contrast
startupfeedback
kscreen
screentransform

Currently Active Effects:
-------------------------
blur
contrast

Effect Settings:
----------------
kwin4_effect_tv:
pluginId: kwin4_effect_tv
isActiveFullScreenEffect: false

kwin4_effect_windowaperture:
pluginId: kwin4_effect_windowaperture
isActiveFullScreenEffect: false

kwin4_effect_translucency:
pluginId: kwin4_effect_translucency
isActiveFullScreenEffect: false

kwin4_effect_sessionquit:
pluginId: kwin4_effect_sessionquit
isActiveFullScreenEffect: false

kwin4_effect_morphingpopups:
pluginId: kwin4_effect_morphingpopups
isActiveFullScreenEffect: false

kwin4_effect_maximize:
pluginId: kwin4_effect_maximize
isActiveFullScreenEffect: false

kwin4_effect_logout:
pluginId: kwin4_effect_logout
isActiveFullScreenEffect: false

kwin4_effect_login:
pluginId: kwin4_effect_login
isActiveFullScreenEffect: false

kwin4_effect_fullscreen:
pluginId: kwin4_effect_fullscreen
isActiveFullScreenEffect: false

kwin4_effect_frozenapp:
pluginId: kwin4_effect_frozenapp
isActiveFullScreenEffect: false

kwin4_effect_fadingpopups:
pluginId: kwin4_effect_fadingpopups
isActiveFullScreenEffect: false

kwin4_effect_dimscreen:
pluginId: kwin4_effect_dimscreen
isActiveFullScreenEffect: false

kwin4_effect_dialogparent:
pluginId: kwin4_effect_dialogparent
isActiveFullScreenEffect: false

colorpicker:

blendchanges:

screenshot:

snaphelper:

trackmouse:
modifiers: 335544320
mousePolling: true

screenedge:

zoom:
zoomFactor: 1.2
mousePointer: 0
mouseTracking: 0
focusTrackingEnabled: false
textCaretTrackingEnabled: false
focusDelay: 350
moveFactor: 20
targetZoom: 1

slidingpopups:
slideInDuration: 300
slideOutDuration: 500

magiclamp:

slide:
horizontalGap: 45
verticalGap: 20
slideDocks: false
slideBackground: true

slideback:

sheet:
duration: 600

desktopgrid:
gridRows: 1
gridColumns: 2
animationDuration: 400
layout: 1
partialActivationFactor: 0
gestureInProgress: false
showAddRemove: true
desktopNameAlignment: 0
desktopLayoutMode: 0
customLayoutRows: 2

highlightwindow:

overview:
animationDuration: 400
layout: 1
ignoreMinimized: false
blurBackground: true
partialActivationFactor: 0
gestureInProgress: false

windowview:
animationDuration: 400
layout: 1
ignoreMinimized: false
mode: 0
partialActivationFactor: 0
gestureInProgress: false
searchText:

wobblywindows:
stiffness: 0.1
drag: 0.85
moveFactor: 0.1
xTesselation: 20
yTesselation: 20
minVelocity: 0
maxVelocity: 1000
stopVelocity: 0.5
minAcceleration: 0
maxAcceleration: 1000
stopAcceleration: 0.5
moveWobble: true
resizeWobble: true

blur:

contrast:

startupfeedback:
type: 1

kscreen:

screentransform:


Loaded Plugins:
---------------
kwin5_plugin_colord
kwin5_plugin_krunner
kwin5_plugin_nightcolor
kwin5_plugin_screencast

Available Plugins:
------------------
kwin5_plugin_colord
kwin5_plugin_krunner
kwin5_plugin_nightcolor
kwin5_plugin_screencast

EDIT:

yeah only seems to happen when I have to screens with diffrent scaling.

if I only have one screen enabled or if I set both to the same scaling chromium browsers work fine. so maybe it's plasma/ chromium bug

1 Like

Glad you found it!
Still surprised 2 different screen scalings could cause such an issue, though. We learn every day.

What if you disable Compositor and still use 2 screens with different scaling?
Just in case the Compositor has anything to do in there...

Afaik you can't disable the competitor on Wayland as Wayland is the compositor

Guess i can try reporting it kde bugs

EDIT: Done 459121 – Chromium wayland mouse issues when using multiple monitors with different scaling

EDIT2:
Interestingly something I just found is that moving the window between my two screens fixes the misalignment of the Vivaldi window (and regular chromium) So that seems like a good temporary workaround for now

Damn, you're right, I'm new to Wayland for a few months now and have forgotten about that. :slight_smile:

Let's see where the bug goes, but yeah it's funny just by moving the window on your other screen!

Since this sounds like a good workaround and it's great you found it, maybe you could mark your post as a solution?

2 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.