groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] GroffHub


From: John Gardner
Subject: Re: [Groff] GroffHub
Date: Fri, 22 Jul 2016 23:23:08 +1000

>
> *That's why .ig doesn't cause subsequent lines to be ignored.*


Uh, actually, I completely forgot about that macro... That actually *can*
be handled in a line-based fashion, because TextMate operates by opening
"scopes" in response to patterns. Thanks for picking up on that!

*And why \\fB inside a .de is treated as \fB.*


That was actually a conscious exception on my part. Many roff macros need
heavy escaping, so I made all `\` characters match as one character.

For syntax themes that recognise punctuation characters, this can have a
huge improvement to readability:

[image: Inline images 1]
So the expected result of \fB inside a `.de` block would, of course, be
that the text inside is emboldened.

*Why is .PS orange versus .PE's purple?*


Hrm, could you show me where you're seeing that, please? =) BTW, I'm still
finishing off some rough edges - specifically, adding highlighting for Pic
and other preprocessors.

On 22 July 2016 at 22:55, Ralph Corderoy <address@hidden> wrote:

> Hi John,
>
> Nice work.
>
> > Yes, a limitation in highlighting is that each regular expression is
> > scoped to one line at once, so there's no possibility of knowing
> > what's on the next line, or what was on the previous line. This is
> > done by the TextMate-grammar engine for performance reasons, but it
> > also makes working with line-based languages like Roff a nightmare.
>
> Understood.  That's why .ig doesn't cause subsequent lines to be
> ignored.  And why \\fB inside a .de is treated as \fB.  Why is .PS
> orange versus .PE's purple?
>
> Cheers, Ralph.
>

PNG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]