From 5c95239aca211147ffd93735a11d4908fc8a6d4d Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Mon, 22 May 2023 15:23:39 +0100 Subject: [PATCH] ; Fix markup of some treesit vars in Elisp manual. * doc/lispref/modes.texi (Parser-based Font Lock): (Parser-based Indentation): * doc/lispref/parsing.texi (Multiple Languages): Use @code in place of @var when the argument is not a metavariable. --- doc/lispref/modes.texi | 10 +++++----- doc/lispref/parsing.texi | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index 00298d88f43..cb491d52c50 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -4073,8 +4073,8 @@ replacing syntactic font lock, then the regexp-based font lock. Although parser-based font lock doesn't share the same customization variables with regexp-based font lock, it uses similar customization -schemes. The tree-sitter counterpart of @var{font-lock-keywords} is -@var{treesit-font-lock-settings}. +schemes. The tree-sitter counterpart of @code{font-lock-keywords} is +@code{treesit-font-lock-settings}. @cindex tree-sitter fontifications, overview @cindex fontifications with tree-sitter, overview @@ -4108,9 +4108,9 @@ To setup tree-sitter fontification, a major mode should first set @code{treesit-major-mode-setup}. @defun treesit-font-lock-rules &rest query-specs -This function is used to set @var{treesit-font-lock-settings}. It +This function is used to set @code{treesit-font-lock-settings}. It takes care of compiling queries and other post-processing, and outputs -a value that @var{treesit-font-lock-settings} accepts. Here's an +a value that @code{treesit-font-lock-settings} accepts. Here's an example: @example @@ -4981,7 +4981,7 @@ below: then the major mode needs only to write some indentation rules and the engine takes care of the rest. To enable the parser-based indentation engine, either set -@var{treesit-simple-indent-rules} and call +@code{treesit-simple-indent-rules} and call @code{treesit-major-mode-setup}, or equivalently, set the value of @code{indent-line-function} to @code{treesit-indent}. diff --git a/doc/lispref/parsing.texi b/doc/lispref/parsing.texi index cba323d3a56..b70f953f8ed 100644 --- a/doc/lispref/parsing.texi +++ b/doc/lispref/parsing.texi @@ -1644,9 +1644,9 @@ directly translate into operations shown above. @end example @defun treesit-range-rules &rest query-specs -This function is used to set @var{treesit-range-settings}. It -takes care of compiling queries and other post-processing, and outputs -a value that @var{treesit-range-settings} can have. +This function is used to set @code{treesit-range-settings}. It takes +care of compiling queries and other post-processing, and outputs a +value that @code{treesit-range-settings} can have. It takes a series of @var{query-spec}s, where each @var{query-spec} is a @var{query} preceded by zero or more @var{keyword}/@var{value} -- 2.39.2