From f452677c555693e354f69ebd4b8b3f074f0e616e Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 12 Sep 2024 23:18:30 -0400 Subject: [PATCH] docs(ligatures): revise docstrings --- modules/ui/ligatures/autoload/ligatures.el | 10 ++++++---- modules/ui/ligatures/config.el | 8 ++++++-- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/modules/ui/ligatures/autoload/ligatures.el b/modules/ui/ligatures/autoload/ligatures.el index f23317a95..eb3bb263d 100644 --- a/modules/ui/ligatures/autoload/ligatures.el +++ b/modules/ui/ligatures/autoload/ligatures.el @@ -18,15 +18,17 @@ pretty symbols and ligatures previously defined for MODES. For example, the rule for emacs-lisp-mode is very simple: - (set-ligatures! \\='emacs-lisp-mode - :lambda \"lambda\") + (after! elisp-mode + (set-ligatures! \\='emacs-lisp-mode + :lambda \"lambda\")) This will replace any instances of \"lambda\" in emacs-lisp-mode with the symbol associated with :lambda in `+ligatures-extra-symbols'. -Pretty symbols can be unset for emacs-lisp-mode with: +Pretty symbols can be unset by passing `nil': - (set-ligatures! \\='emacs-lisp-mode nil) + (after! rustic + (set-ligatures! \\='rustic-mode nil)) Note that this will keep all ligatures in `+ligatures-prog-mode-list' active, as `emacs-lisp-mode' is derived from `prog-mode'." diff --git a/modules/ui/ligatures/config.el b/modules/ui/ligatures/config.el index 1de06f345..57dc8d7c1 100644 --- a/modules/ui/ligatures/config.el +++ b/modules/ui/ligatures/config.el @@ -59,7 +59,9 @@ font.") "?=" "?." "??" ";;" "/*" "/=" "/>" "//" "__" "~~" "(*" "*)" "\\\\" "://") (t)) - "A alist of ligatures to enable in specific modes.") + "A alist of ligatures to enable in specific modes. + +To configure this variable, use `set-ligatures!'.") (defvar +ligatures-in-modes nil "List of major modes where ligatures should be enabled.") @@ -74,7 +76,9 @@ font.") (make-obsolete-variable '+ligatures-all-modes-list "Use `+ligatures-alist' instead" "24.09.0") (defvar +ligatures-extra-alist '((t)) - "A map of major modes to symbol lists (for `prettify-symbols-alist').") + "A map of major modes to symbol lists (for `prettify-symbols-alist'). + +To configure this variable, use `set-ligatures!'.") (defvar +ligatures-extras-in-modes t "List of major modes where extra ligatures should be enabled.