What happened?
On KDE Plasma Wayland, the scroll MCP tool scrolls vertically in the opposite direction from the requested direction:
direction: "down" scrolls upward.
direction: "up" scrolls downward.
This occurs when input is sent through the XDG RemoteDesktop portal.
Tracing v0.4.1 shows that computer-use-linux maps the directions in src/remote_desktop.rs as:
ScrollDirection::Up => (AXIS_VERTICAL, steps.max(1)),
ScrollDirection::Down => (AXIS_VERTICAL, -steps.max(1)),
The KDE portal passes this signed discrete value directly to the Wayland vertical-scroll axis:
m_fakeInput->axis(
WL_POINTER_AXIS_VERTICAL_SCROLL,
wl_fixed_from_double(delta)
);
KDE's continuous-axis implementation, however, explicitly negates the vertical value:
m_fakeInput->axis(
WL_POINTER_AXIS_VERTICAL_SCROLL,
wl_fixed_from_double(-y)
);
The observed reversal therefore appears to be a polarity mismatch in the discrete portal path.
The ydotool fallback uses Linux REL_WHEEL semantics and should be handled separately. An unconditional global sign flip could break that backend.
Environment:
computer-use-linux: 0.4.1
Installation: prebuilt x86_64 release packaged through Nix
NixOS: 26.11.20260719.241313f (Zokor)
KDE Plasma: 6.7.3
xdg-desktop-portal: 1.20.4
xdg-desktop-portal-kde: 6.7.3
Session: Wayland
Portal pointer forced: COMPUTER_USE_LINUX_FORCE_PORTAL_POINTER=1
Steps to reproduce
-
Run KDE Plasma on Wayland with computer-use-linux configured to use the portal pointer backend:
COMPUTER_USE_LINUX_FORCE_PORTAL_POINTER=1
-
Start the MCP server:
-
Open an application containing enough content to scroll vertically.
-
Place the pointer over its scrollable area, or target the window through the scroll tool.
-
Call:
{
"direction": "down",
"pages": 1
}
-
Observe that the application scrolls upward.
-
Call:
{
"direction": "up",
"pages": 1
}
-
Observe that the application scrolls downward.
The tool reports success through the RemoteDesktop portal in both cases.
Expected behavior
The direction names should describe the resulting viewport movement consistently across input backends:
direction: "down" should move the viewport downward through the document.
direction: "up" should move the viewport upward through the document.
Portal and ydotool backends should normalize their native axis conventions internally so callers do not need backend-specific reversed directions.
Version
agentsys and agnix are not installed because computer-use-linux is installed directly as a NixOS package.
Platform
Codex CLI
OS
NixOS 26.11 (Unstable)
What happened?
On KDE Plasma Wayland, the
scrollMCP tool scrolls vertically in the opposite direction from the requesteddirection:direction: "down"scrolls upward.direction: "up"scrolls downward.This occurs when input is sent through the XDG RemoteDesktop portal.
Tracing v0.4.1 shows that
computer-use-linuxmaps the directions insrc/remote_desktop.rsas:The KDE portal passes this signed discrete value directly to the Wayland vertical-scroll axis:
KDE's continuous-axis implementation, however, explicitly negates the vertical value:
The observed reversal therefore appears to be a polarity mismatch in the discrete portal path.
The ydotool fallback uses Linux
REL_WHEELsemantics and should be handled separately. An unconditional global sign flip could break that backend.Environment:
Steps to reproduce
Run KDE Plasma on Wayland with
computer-use-linuxconfigured to use the portal pointer backend:Start the MCP server:
computer-use-linux mcpOpen an application containing enough content to scroll vertically.
Place the pointer over its scrollable area, or target the window through the
scrolltool.Call:
{ "direction": "down", "pages": 1 }Observe that the application scrolls upward.
Call:
{ "direction": "up", "pages": 1 }Observe that the application scrolls downward.
The tool reports success through the RemoteDesktop portal in both cases.
Expected behavior
The direction names should describe the resulting viewport movement consistently across input backends:
direction: "down"should move the viewport downward through the document.direction: "up"should move the viewport upward through the document.Portal and ydotool backends should normalize their native axis conventions internally so callers do not need backend-specific reversed directions.
Version
agentsysandagnixare not installed becausecomputer-use-linuxis installed directly as a NixOS package.Platform
Codex CLI
OS
NixOS 26.11 (Unstable)