summaryrefslogtreecommitdiff
path: root/lisp/textmodes/conf-mode.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/textmodes/conf-mode.el')
-rw-r--r--lisp/textmodes/conf-mode.el7
1 files changed, 6 insertions, 1 deletions
diff --git a/lisp/textmodes/conf-mode.el b/lisp/textmodes/conf-mode.el
index 382312f8b81..5e1636033f6 100644
--- a/lisp/textmodes/conf-mode.el
+++ b/lisp/textmodes/conf-mode.el
@@ -245,6 +245,7 @@ This variable is best set in the file local variables, or through
("^\\s-*\\(.+?\\)\\(?:\\[\\(.*?\\)\\]\\)?\\s-*="
(1 'font-lock-variable-name-face)
(2 'font-lock-constant-face nil t))
+ ;; Must be lower-case according to the TOML spec.
("\\_<false\\|true\\_>" 0 'font-lock-keyword-face))
"Keywords to highlight in Conf TOML mode.")
@@ -435,6 +436,7 @@ The optional arg FONT-LOCK is the value for FONT-LOCK-KEYWORDS."
(setq-local comment-start comment)
(setq-local comment-start-skip
(concat (regexp-quote comment-start) "+\\s *"))
+ (setq-local text-conversion-style t)
(if font-lock
(setq-local font-lock-defaults `(,font-lock nil t nil nil))))
@@ -643,7 +645,10 @@ For details see `conf-mode'. Example:
\[entry]
value = \"some string\""
- (conf-mode-initialize "#" 'conf-toml-font-lock-keywords)
+ (conf-mode-initialize "#")
+ ;; Booleans are "always lowercase", so we must *not* use case
+ ;; folding. Therefore, we can't set it using `conf-mode-initialize´.
+ (setq-local font-lock-defaults `(,conf-toml-font-lock-keywords nil nil nil nil))
(setq-local conf-assignment-column 0)
(setq-local conf-assignment-sign ?=))