When the selection is no longer ours but still holds our text minus the tail something reformatted away, the type now comes from what we published instead of being guessed from the text.
On Linux with clipboard=unnamed the `*` register is backed by the system PRIMARY selection, which stores text only, so its type was re-guessed from the text on every read. The selection can come back with trailing whitespace stripped, so a line-wise "foo \n" reads back as "foo" and gets downgraded to character-wise. We now reuse the text and type we published while we still own the selection, and only read and guess once another app claims it.
When user typed / twice in a row there could be race condition between deactivate and activate panel requesting focus. so becouse of focus parent in deactivate is asnyc it could happen after requestFocusInWindow in activate
JBR's WLClipboard takes Wayland-side primary ownership and Mutter's
Wayland→X11 bridge is racy under rapid visual selection, so external
readers (xclip, middle-click-paste) see stale content. Route PRIMARY
writes through xclip (preferred) or wl-copy (fallback) on Wayland,
deferred past IntelliJ's CaretModelImpl.updateSystemSelection
post-yank clobber. AWT path unchanged on X11/macOS/Windows.