elisp - Make Emacs prettify-symbols-mode work on non-whitespace separated words. -
the new prettify-symbols-mode in emacs works beautifully translating:
lambda -> λ i'd make:
lambda.something -> λsomething sadly, prettify-symbols-mode recognizes spaces word/symbol separators default.
any ideas on how use '.' token separator?
the code actual substitution prettify-symbols--compose-symbol in prog-mode.el. excludes matches if character before or after word has character type word or symbol. in many mode, example emacs-lisp-mode . character has symbol type.
you either change syntax code . in major mode, tell font-lock use different character code when highlighting (see variable font-lock-defaults details), or ju-jutsu on prettify-symbols--compose-symbol mode modifying using defadvice or replace own.
Comments
Post a Comment