GNU bug report logs -
#58940
[PATCH] feature/tree-sitter: Add more font lock faces
Previous Next
Reported by: Randy Taylor <dev <at> rjt.dev>
Date: Tue, 1 Nov 2022 01:22:01 UTC
Severity: normal
Tags: patch
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #32 received at 58940 <at> debbugs.gnu.org (full text, mbox):
> Date: Sat, 05 Nov 2022 02:46:30 +0000
> From: Randy Taylor <dev <at> rjt.dev>
> Cc: casouri <at> gmail.com, 58940 <at> debbugs.gnu.org
>
> Sorry for the delay, furniture building took longer than anticipated
> and desired.
We all have our lives, no need to apologize.
> +@item font-lock-delimiter-face
> +@vindex font-lock-delimiter-face
> +for delimiters (e.g. @code{;}, @code{:}, @code{,}).
You need a comma or a @: after "e.g.", to avoid its being interpreted
as the end of a sentence.
> +@item font-lock-escape-face
> +@vindex font-lock-escape-face
> +for escape sequences in strings.
I suggest an example of an escape sequence here, ideally from 2 or
more programming languages.
> +@smallexample
> +typedef struct
> +@{
> + int prop;
> +// ^ property
> +@} obj;
> +
> +int main()
> +@{
> + obj o;
> + o.prop = 3;
> +// ^ property
> +@}
> +@end smallexample
Please use @group..@end group here, since the two parts of this can be
typeset on separate pages, but we don't want each one of thgem to be
broken between pages.
> --- a/etc/NEWS
> +++ b/etc/NEWS
> @@ -732,6 +732,13 @@ If the current buffer is visiting a file that is executable, the
> This determines how long to pause Emacs after a process
> filter/sentinel error has been handled.
>
> ++++
> +** New faces for font-lock.
> +'font-lock-bracket-face', 'font-lock-delimiter-face',
> +'font-lock-escape-face', 'font-lock-number-face',
> +'font-lock-misc-punctuation-face', 'font-lock-operator-face',
> +'font-lock-property-face', 'font-lock-punctuation-face'.
Should this say that they are primarily meant for use with
tree-sitter?
> +(defvar font-lock-property-face 'font-lock-property-face
> + "Face name to use for properties.")
This doc string is too concise to be useful. Please add some
information from the detailed descriptions above.
> +(defface font-lock-bracket-face
> + '((t :inherit font-lock-punctuation-face))
It is better to have the parent face font-lock-punctuation-face
defined before it is used.
Thanks.
This bug report was last modified 2 years and 193 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.