Function: ghostel--osc52-handle
ghostel--osc52-handle is a natively compiled function defined in
ghostel.el.
Signature
(ghostel--osc52-handle SELECTION BASE64-DATA)
Documentation
Handle an OSC 52 clipboard set request.
SELECTION is the target (e.g. "c" for clipboard).
BASE64-DATA is the base64-encoded text.
Only acts when ghostel-enable-osc52 is non-nil.
Source Code
;; Defined in /nix/store/1252krff0gb2kisjcpp45m50cpdskfrl-emacs-packages-deps/share/emacs/site-lisp/ghostel.el
(defun ghostel--osc52-handle (_selection base64-data)
"Handle an OSC 52 clipboard set request.
SELECTION is the target (e.g. \"c\" for clipboard).
BASE64-DATA is the base64-encoded text.
Only acts when `ghostel-enable-osc52' is non-nil."
(when ghostel-enable-osc52
(let ((text (ignore-errors (base64-decode-string base64-data))))
(when (and text (> (length text) 0))
(kill-new text)
(when (fboundp 'gui-set-selection)
(gui-set-selection 'CLIPBOARD text))))))