[Feature] Support legacy XEmbed system tray icons on Wayland via SNI bridge

Aperta
#58 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
45/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
go, linux

Direzione di ricerca

Inizia tracciando la gestione esistente di displayX11, il bootstrap di slirp4netns e il proxy D-Bus privato del desktop menzionato nell’issue. Determina quindi come la configurazione di trayProxy dovrebbe controllare l’avvio del bridge e l’elenco di autorizzazione di StatusNotifierItem/Watcher. Il lavoro è completato quando il bridge viene recuperato, verificato e supervisionato nella sessione X annidata e le icone legacy della tray sono visibili tramite il pannello Wayland dell’host.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Problem

Apps using Qt's QSystemTrayIcon / GTK StatusIcon rely on the XEmbed
protocol (_NET_SYSTEM_TRAY_S0). Under cpak's nested displayX11
(Xwayland/Xephyr), nothing claims that selection, so the tray icon
is created but never rendered anywhere — the app itself needs zero
changes, there's just no tray manager present in the nested display.

Example: fptn-client-gui (Qt), tray icon silently disappears when
packaged for a pure-Wayland session (Niri, Hyprland, Sway).

Proposed solution

Don't reimplement XEmbed↔SNI translation — tools like snixembed
already do exactly this (claim the tray selection, expose a
StatusNotifierItem on D-Bus, replay clicks back via XSendEvent).
This is the same pattern non-containerized Wayland users already
rely on today with unmodified Qt/GTK apps.

Concretely, when displayX11 is set and a new flag is enabled:

"override": {
  "displayX11": true,
  "trayProxy": "xembed"
}

cpak would:

  1. Fetch/verify a static snixembed-equivalent binary (same pattern
    as the slirp4netns bootstrap) and launch it inside the nested
    X session before the app starts.
  2. Widen the existing private desktop D-Bus proxy (currently used
    for org.freedesktop.appearance / notifications / openURI) to
    also forward org.kde.StatusNotifierItem and
    org.kde.StatusNotifierWatcher calls between the bridge and
    the host bus.

No pixmap capture or click-translation logic needs to be written —
the bridge already implements both directions; cpak only needs to
supervise its lifecycle and open the D-Bus interface allowlist.

Why this is low risk

Same components (Xwayland tray bridge → SNI → Wayland panel) are
already used unmodified outside containers. This is wiring, not
new protocol work.

Open question

Would you rather scope the D-Bus interface allowlist per-package
(declared permission) or make it a fixed part of trayProxy?

Lingua principale
Go
Stelle
218
Fork
5
Merge medio
45m
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Containerpak/cpak

Tutte le issue di Containerpak/cpak

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.