Skip to content

viewer: paste on Wayland compositors without data-control, such as GNOME #426

Closed

Description

@ElbertePlinio

Paste in the native viewer (#366) reads the host clipboard on Wayland through the data-control protocol. Hyprland, Sway, KDE and river offer it. GNOME's Mutter does not, so Paste there shows "Paste unavailable".

The viewer window has keyboard focus when the human clicks Paste, so a reader through the window's own wl_data_device could read the clipboard on compositors without data-control. It must keep the rules Paste has today: read only after the click under a live lease, UTF-8 text only, 16 KiB and one second at most, the stop check, and no text in logs, errors or events.

  • Read the clipboard through the viewer window's wl_data_device when data-control is missing
  • Test on a compositor without data-control, in an isolated session
  • Update PROTOCOL.md and SECURITY.md

Activity

  1. ElbertePlinio commented on Oct 28, 2026

    @ElbertePlinio
    MemberAuthor

    Found while building #366 in #427. On a compositor without data-control, the Paste button shows "Paste unavailable".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions