The emacs-mac port of emacs (https://bitbucket.org/mituharu/emacs-mac)
returns a different value for the window system ("mac" instead of
"ns") and its system color specifications have a "mac:" prefix. This
change makes the use of macOS system colors for the lin-highlighting
work in both major kinds of emacs versions on macOS.
---
lin.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/lin.el b/lin.el
index a514796..cf9a391 100644
--- a/lin.el+++ b/lin.el
@@ -268,12 +268,15 @@ updates the face. Users who prefer to use `setq' must run
'((((type ns))
;; <https://developer.apple.com/design/human-interface-guidelines/macos/visual-design/color/> .
:background "selectedContentBackgroundColor" :extend t)
+ (((type mac))+ :background "mac:selectedContentBackgroundColor" :extend t) (t :inherit lin-blue))
"Alternative macOS-style face for `lin-face'."
:group 'lin-faces)
(defface lin-mac-override-fg
- '((t :inherit lin-mac :foreground "alternateSelectedControlTextColor"))+ '((((type ns)) :inherit lin-mac :foreground "alternateSelectedControlTextColor")+ (((type mac)) :inherit lin-mac :foreground "mac:alternateSelectedControlTextColor")) "Like `lin-mac' but also sets a foreground."
:group 'lin-faces)
--
2.32.0 (Apple Git-132)
> From: Kai von Fintel <fintel@mit.edu>> Date: Mon, 18 Apr 2022 19:24:06 -0400>> The emacs-mac port of emacs (https://bitbucket.org/mituharu/emacs-mac)> returns a different value for the window system ("mac" instead of> "ns") and its system color specifications have a "mac:" prefix. This> change makes the use of macOS system colors for the lin-highlighting> work in both major kinds of emacs versions on macOS.
Thank you, Kai! I installed the patch and also updated the manual's
"Acknowledgements" section to include your name.
--
Protesilaos Stavrou
https://protesilaos.com