# Re: [code] [textadept] open file and latex lexer

From: Mitchell <m.att.foicica.com>
Date: Fri, 3 Jan 2014 09:31:48 -0500 (Eastern Standard Time)

Hi Oliver,

On Thu, 2 Jan 2014, Olivier Guibé wrote:

> I use very often LaTeX, so I tried compilation in Textadept
> menu. Editing a standalone LaTeX file (with error), compiling
> and clicking on the error in the message's buffer (or c+a+e)
> opens a new buffer for my LaTeX file.
> It seems that textadept considers that ~/filename and
> ~/./filename are different and then opens twice the file
> (it is possible to open another with ~/Documents/../filename).
> I made the test in a terminal. I precise that my system
> is Debian Sid 64 bits, and that Textadept 7.1 or 7.2alpha
> have the same behavior.

A variation of this issue came up recently. Textadept cannot handle
relative paths very well because the question "relative to what?" comes
up. However, in your examples, you illustrate something that can be
improved: Textadept can do better to handle './' and '../' sequences. I
will work on this. Thanks for the report.

> As far as the LaTeX lexer is concerned, \begin {environment}
> is not recognized due to the space between "\begin" and "{environment}".
> It is not recommended but LaTeX compilation is OK.
> Please find a modified version of latex.lua lexer which takes
> into account this possibility.
> Another remark is that folding sub-math environment like
> \begin{split}\end{split} is possible while folding math environment
> is not set. It is not very important.
> I tried also to "recognize" $...$ group but my lua and programming
> knowledge is not sufficient : it needs more than the very simple use of
> lpeg.{P,S,R}

Thanks for your contribution! I will commit this.

Cheers,
Mitchell

--
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.

Received on Fri 03 Jan 2014 - 09:31:48 EST

This archive was generated by hypermail 2.2.0 : Sat 04 Jan 2014 - 06:42:48 EST