[TxMt] Latex grammar problem

Allan Odgaard throw-away-1 at macromates.com
Fri Jun 2 05:27:53 UTC 2006


On 1/6/2006, at 7:51, Charilaos Skiadas wrote:

>>> [...] The scope for the Miscellaneous item is text.latex. I am  
>>> thinking it should perhaps also work in source.tex ?
>> That sounds right.
> So does this mean the scope should be  text.latex, or source.tex,  
> or both?

Both

> [...] The weird thing now however is that if I type a dollar sign  
> inside the double-quoted string, it does not do smart inserting of  
> the corresponding closing dollar sign. Is this just a problem in my  
> installation somehow?

Did it ever do this? The Source bundle alters smart-typing pairs for  
double quoted strings (to not have ' auto-paired) so the  
Miscellaneous should probably be:

    source.tex, text.latex, string.quoted.double.(la)tex

That way it will override the general double-quoted string auto-pairs.

> There was some weird matching of things of the form \. where dot is  
> anything taking place in the syntax for double-quoted strings,  
> which I removed since I did not see what it was good for. It just  
> messed with all commands. I just had the patterns include $base.

Likely this was just left over from copy’n’paste (most languages will  
need to match \. as an escape sequence to allow: "this \"is\" a string")

> Btw, perhaps the double-quoted strings should be moved to  
> source.tex? After all, they are valid in TeX.

Okay, sounds like it should be moved then.







More information about the textmate mailing list