[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: "Font-lock is limited to text matching" is a myth
From: |
Stefan Monnier |
Subject: |
Re: "Font-lock is limited to text matching" is a myth |
Date: |
Mon, 10 Aug 2009 23:33:33 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) |
> I think Daniel suggested that it is a frame-work that can be used for
> book-keeping of how far parsing has gone (the state must be kept
> elsewhere) and parsing while Emacs is idle. Don't you think it can be
> used for that?
As it stands, it's not really adapted to it.
I mean, it's OK and there's worse, but it's not great. It's designed
mostly to keep track of what has been highlighted (without paying too
much attention to potential dependencies between chunks), and it is
designed to rehighlight the parts that change and that are displayed.
For parsing, we generally assume sequential dependencies (e.g. can't
parse the end of the buffer before parsing the beginning), so
font-lock's tracking is not very well adapted. And parsing may need to
be applied to chunks of text that has not yet and will never
be displayed.
Basically font-lock-syntactic-keywords is the part of font-lock that was
"designed" to handle the parsing side (together with syntax-table), but
it deserves to be improved significantly and it should be moved out of
font-lock since it provides services that are useful/needed by many
other packages, and in buffers where font-lock might not even
be desired.
Stefan
- Re: "Font-lock is limited to text matching" is a myth, (continued)
- Re: "Font-lock is limited to text matching" is a myth, Xah Lee, 2009/08/12
- asynchronous parsing (was: "Font-lock is limited to text matching" is a myth), Ted Zlatanov, 2009/08/12
- Re: asynchronous parsing, joakim, 2009/08/12
- Re: asynchronous parsing, Ted Zlatanov, 2009/08/12
- Re: asynchronous parsing, joakim, 2009/08/12
- Re: asynchronous parsing, Stefan Monnier, 2009/08/12
- Re: asynchronous parsing, Ted Zlatanov, 2009/08/13
- Re: "Font-lock is limited to text matching" is a myth, Lennart Borgman, 2009/08/11
- Re: "Font-lock is limited to text matching" is a myth, Stefan Monnier, 2009/08/10
- Re: "Font-lock is limited to text matching" is a myth, Lennart Borgman, 2009/08/10
- Re: "Font-lock is limited to text matching" is a myth,
Stefan Monnier <=
- Re: Why js2-mode in Emacs 23.2?, Stefan Monnier, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Deniz Dogan, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Stefan Monnier, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Stephen Eilert, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Lennart Borgman, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Deniz Dogan, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Stephen Eilert, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Deniz Dogan, 2009/08/10
- Re: Why js2-mode in Emacs 23.2?, Lennart Borgman, 2009/08/10