notepad++ and TEX compiling

By | 6. January 2011

For windows I love the diverse text editor notepad++. These days I was confronted with the task, that I needed to compile a TEX document. The problem is that notepad++ does no have an integration for TEX compiling. So, how to do it than?

After searching a little for answers I found an easy approach, using the exec plug-in. It is possible to run external programs out of notepad++. Their output is shown in an extra part of the window. Using yap as DVI viewer can also be integrated. Even a double-click at a specific part of the text in yap will bring you back to the corresponding line in notepad++ by using commandline options.

Following a very short and not well explained how-to:

cd “$(FULL_CURRENT_PATH)”
C:\…\pdflatex.exe -interaction=nonstopmode “$(FULL_CURRENT_PATH)”
C:\…\bibtex.exe “$(CURRENT_DIRECTORY)\$(NAME_PART)”
C:\…\pdflatex.exe -interaction=nonstopmode “$(FULL_CURRENT_PATH)”
C:\…\pdflatex.exe -interaction=nonstopmode “$(FULL_CURRENT_PATH)”
“C:\…\Adobe.exe” “$(CURRENT_DIRECTORY)\$(NAME_PART).pdf”

Keep in mind that it might be possible to reduce the number of pdflatex calls. You need to test it yourself. Having the wrong number or sequence of calls leads to missing references or else.

To integrate the yap integration for jumping to the corresponding line, add the following switch to the last latex call:

-src-specials

Actually this only works if you use latex instead of pdflatex!

print

Leave a Reply

Your email address will not be published. Required fields are marked *