Skip to main content
Glama
kde-desktop-mcp

kde-desktop-mcp

by marvin1099

kde_window_set_geometry

DestructiveIdempotent

Set a KWin window's frame rectangle in logical desktop pixels and verify its effective geometry. Use this for explicit window placement without simulating a mouse drag.

Instructions

Set an explicit KWin frame rectangle in logical desktop pixels and verify its effective geometry. This is window placement, not a simulated mouse drag.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "session": "<session>",
      "window_id": "<window_id>",
      "x": "<x>",
      "y": "<y>",
      "width": "<width>",
      "height": "<height>"
    },
    "name": "kde_window_set_geometry"
  }
}

Input Schema

NameRequiredDescriptionDefault
xYes
yYes
widthYes
heightYes
sessionYesRequired target selector: a managed private session ID, or the exact value 'user-desktop' to explicitly opt into the real user desktop.
window_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare idempotentHint=true, destructiveHint=true, and openWorldHint=true, so the safety profile is partially covered. The description usefully adds that coordinates are logical desktop pixels anchored to the frame rectangle (not client area) and that the effective geometry is verified — implying the window manager may adjust the request. It does not say what happens when the requested rectangle is rejected/clamped, whether off-screen placement is permitted, or what the verification result looks like, which matters for a destructive, open-world mutation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, both front-loaded and free of filler; the primary action comes first and the disambiguation second. Nothing is redundant, though the second sentence could carry more load if it stated a precondition or failure behavior instead of only ruling out drag.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a six-parameter, destructive, open-world geometry mutation with no output schema, the definition covers the essential coordinate semantics but omits prerequisites (locating window_id), the meaning of the geometry verification result, and failure/clamping behavior. Adequate to invoke, thin on what an agent should expect afterward.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 17% — only `session` is described in the schema — so the description must carry weight. It does clarify the four geometry parameters collectively: x/y/width/height define a frame rectangle in logical desktop pixels, which disambiguates frame-vs-content origin. `window_id` remains uncharacterized (accepted format, expected source) and the numeric ranges are left entirely to the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource: setting an explicit KWin frame rectangle, with the unit (logical desktop pixels) and a follow-up verification step. It also rules out one neighboring behavior (simulated mouse drag via the input tools), so an agent can tell this apart from drag-based placement, though no other placement-adjacent sibling is addressed.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The negative guidance is explicit ("not a simulated mouse drag"), which rules out one plausible wrong tool. However, there is no positive when-to-use guidance: no mention that a window_id must first be obtained (e.g., via kde_window_find/list), no discussion of when to prefer this over activating or minimizing, and no preconditions stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.