Files
gentoo-zh/.agents/rules/desktop-integration.md
Zakk a55f0925b0 AGENTS.md, .agents/rules: rewrite as target states, add QA lessons
AGENTS.md is read on every task, so it keeps routing, the hard stops,
the install and keyword gates and the completion report, and drops to
514 words; all rule files together drop from 7546 to 5783 words. Rules
state the result to reach, and keep a prohibition only where a mistake
is hard to undo or a reviewer has caught it before.

Lessons from reviewed PRs: PATCHES carried over a bump, Go -ldflags
without -s or -w, RUST_MIN_VER from the highest rust-version, cargo
QA_FLAGS_IGNORED, ISA gating through cpu_flags, Python Requires-Dist,
draft PRs for eclass provider slots missing from ::gentoo, skel.ebuild
variable order, DependencyMissingKeywords, and the Go vendor layout.

The PR template asks for the reason, a Tested: line and two checks, and
names the merge-base scan range so it is not read as a bare --commits.

Signed-off-by: Zakk <zakk@gentoozh.org>
2026-11-15 03:09:02 +11:00

928 B

Desktop Integration

Read with: prebuilt-binaries.md when the application ships prebuilt; dependencies.md for the revbump a changed desktop file or icon needs.

  • Match the installed desktop basename to the measured Wayland app_id or X11 WM_CLASS, or add StartupWMClass; an unmatched window gets a default icon. Measure a running instance, using KWin's workspace.windowList() where available.
  • GTK3 uses g_get_prgname() for this identity rather than the GApplication id: org.example.App.desktop can report app.
  • Before changing ozone flags, launch with both --ozone-platform-hint=auto and --ozone-platform=wayland and verify the selected platform; either can fail. Confirm every switch exists in the bundled Chromium version, which silently ignores newer switches.
  • Because desktop profiles enable wayland by default, a wayland? switch reaches X11 users too. Prefer runtime platform selection.