From: Vasilij Schneidermann <v.schneidermann@gmail.com>
To: Andreas Schwab <schwab@linux-m68k.org>
Cc: emacs-devel <emacs-devel@gnu.org>
Subject: Re: Combining syntax comment sequences (yaml-mode)
Date: Wed, 23 Dec 2015 22:56:33 +0100 [thread overview]
Message-ID: <20151223215633.GB780@odonien> (raw)
In-Reply-To: <87bn9hxwbc.fsf@igel.home>
With the given hint I was able to write up a helper function adding
`syntax-table` properties:
(defvar yaml-mode-syntax-propertize-function
(syntax-propertize-rules
("^#" (0 "<"))
("[ \t]+#" (0 "<"))))
While this looks much neater than my previous approach, it doesn't
nearly function as well. After loading up the file, not a single
comment is highlighted correctly. The only thing that triggers
refontification is deleting(!) text close to the comment. Inserting
text(!!) before or after the comment disables the highlighting again.
This is inacceptable behaviour and since I'm not in the mood for
figuring out how font-lock works, I'll wait and see whether someone's
got an idea how to combine the syntax entries presented in the original
post.
prev parent reply other threads:[~2015-12-23 21:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-23 10:47 Combining syntax comment sequences (yaml-mode) Vasilij Schneidermann
2015-12-23 11:01 ` Andreas Schwab
2015-12-23 18:28 ` Vasilij Schneidermann
2015-12-23 18:46 ` Dmitry Gutov
2015-12-23 21:56 ` Vasilij Schneidermann [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151223215633.GB780@odonien \
--to=v.schneidermann@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=schwab@linux-m68k.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.