From 18b7b506b791e3cd53191832c2daba2a8a40ab9f Mon Sep 17 00:00:00 2001 From: David Kastrup Date: Sun, 30 Nov 2014 14:52:22 +0100 Subject: [PATCH] Issue 4208/3: Emacs mode: recognize \this-is-a-command syntax This is a late followup for Issue 2702: Unify the lexer's idea of words and commands across all modes. --- elisp/lilypond-font-lock.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/elisp/lilypond-font-lock.el b/elisp/lilypond-font-lock.el index 73a8df8f7d..be7b592635 100644 --- a/elisp/lilypond-font-lock.el +++ b/elisp/lilypond-font-lock.el @@ -58,8 +58,8 @@ ;; ... keywords (defined above, see kwregex) (cons (concat "\\(\\([_^-]?\\(" kwregex "\\)\\)+\\)\\($\\|[] \t(~{}>\\\\_()^*-]\\)") '(1 font-lock-keyword-face)) -;; ... user defined identifiers \[a-zA-Z]+ - '("\\([_^-]?\\\\\\([a-zA-Z][a-zA-Z]*\\)\\)" 1 font-lock-constant-face) +;; ... user defined identifiers, roughly \[a-zA-Z]+ with single - or _ in between. + '("\\([_^-]?\\\\\\([a-zA-Z[:nonascii:]]\\(?:[-_]?[a-zA-Z[:nonascii:]]\\)*\\)\\)" 1 font-lock-constant-face) ;; ... the left side of '=' -mark '("\\([_a-zA-Z.0-9-]+\\)[ \t]*=[ \t]*" 1 font-lock-variable-name-face) -- 2.39.2