Latex & regular expression search

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Jan Felde

Latex & regular expression search

Post by Jan Felde »

Hi,

I am trying to set up Textpad to work with Latex. I have added the Latex command to the tools menu and now I would like to use the regular expression search to be able to jump from an error line right into my source code.

If have set the error messages in Latex to C/C++ style so they look like

./Test1.tex:4: LaTeX Error: Missing \begin{document}.

where test1.tex is the source file name and 4 is the line the error is on.

What would be the correct regular expression and how do I set the File, Line and Column? The help file has not been too specific on this.

Thanks & kind regards

Jan
Andreas

Re: Latex & regular expression search

Post by Andreas »

\([^:]+\):\([^:]\):

File = 1, Line = 2, Column empty (as no column is provided)

But I am not sure whether it will work as the filenames are given relative to some directory.
Bob Howlett

Re: Latex & regular expression search

Post by Bob Howlett »

If you are using fptex (or the tex distribution from the texlive CD)
then your texmf.cnf file should include the line
TEXEDIT = c:\Progra~1\TextPa~1\System\Ddeopn32 TextPad %s(%d)
(This line should already be in texmf.cnf, commented out, along with
the alternatives appropriate for other editors.)
Then typing e at TeX's error prompt will open textpad and take you
to the line at which the error occurred.
I don't know how it is done if you are using miktex (although there
will surely be something similar available).
Post Reply