dot/emacs: Only force primary selection rather than clipboard on X11.
authorMark Wooding <mdw@distorted.org.uk>
Wed, 6 Dec 2023 14:28:32 +0000 (14:28 +0000)
committerMark Wooding <mdw@distorted.org.uk>
Wed, 6 Dec 2023 14:29:11 +0000 (14:29 +0000)
It makes working on Windows rather annoying.

dot/emacs

index 3c213b9..31f612e 100644 (file)
--- a/dot/emacs
+++ b/dot/emacs
 (require 'paren)
 (trap (show-paren-mode t))
 (or window-system (mdw-emacs-version-p 22) (menu-bar-mode -1))
-(setq x-select-enable-clipboard nil
-      x-select-enable-primary t
-      mouse-drag-copy-region t)
+(if (eq window-system 'x)
+    (setq x-select-enable-clipboard nil
+         x-select-enable-primary t))
+(setq mouse-drag-copy-region t)
 
 ;; Multiple cursors.