Saturday, February 18, 2012

Tools: Latex: Texnic Center and Okular forward search

Put the following command in your Tex->DVI Viewer config under command for opening and forward search:

'%bm.dvi#src:%l %Dc/%nc' --unique

%bm.dvi is your output filename of the Project.
#src:%l gives the linenumber of the current curson
%Dc gives the complete path to the current source file with slashes
%nc gives the full name of the current source file.
--unique ensures only one Okular instance is opened.

Please be sure to use single quotes as double quotes produced no search in my case.

So far I noticed that it does not work if you have lines with latex commands only, e.g. \begin{itemize} or latex TOC elements, e.g. \section{Introduction}.
Just go to the nearest written text section.

No comments:

Post a Comment