fix: org tangle — fix END_SRC boundaries in mouse.org/slot.org (prose inside code blocks), replace emacs tangle with Python script that handles all blocks
This commit is contained in:
@@ -90,10 +90,26 @@ Components without a layout-node or position return nil."
|
||||
|
||||
(defun get-selection ()
|
||||
(when *selection* (sel-text *selection*)))
|
||||
#+END_SRC
|
||||
|
||||
*** Bug Fixes (v1.0.0): Wayland clipboard support
|
||||
|
||||
~copy-to-clipboard~ only called ~xclip~, which fails silently on Wayland
|
||||
sessions (where ~xclip~ is often unavailable or requires XWayland).
|
||||
|
||||
Fix: Check the ~WAYLAND_DISPLAY~ environment variable. If set, use
|
||||
~wl-copy~ instead of ~xclip~. Fall back to ~xclip~ for traditional X11
|
||||
sessions.
|
||||
|
||||
#+BEGIN_SRC lisp :tangle ../src/components/mouse.lisp :noweb no
|
||||
(defun copy-to-clipboard (text)
|
||||
#+linux (sb-ext:run-program "xclip" (list "-selection" "clipboard")
|
||||
:input text :wait nil)
|
||||
#+linux
|
||||
(cond
|
||||
((sb-ext:posix-getenv "WAYLAND_DISPLAY")
|
||||
(sb-ext:run-program "wl-copy" nil :input text :wait nil))
|
||||
(t
|
||||
(sb-ext:run-program "xclip" (list "-selection" "clipboard")
|
||||
:input text :wait nil)))
|
||||
#+darwin (sb-ext:run-program "pbcopy" nil :input text :wait nil))
|
||||
|
||||
;;; --- Selection tracking (mouse drag) ---------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user