[Tex/LaTex] automatically update the pdf preview when compiling with Latexmk

latexmktexmakerviewers

In Texmaker program, when using LatexMk to compile, the PDF is generated but is not automatically displayed in the preview section – one would have to hit the second arrow (left side of View PDF) to view the PDF in the preview section.

can we change it so the preview is updated automatically ?

here is LatexMK in the Texmaker configuration:

"/usr/texbin/latexmk" -e "$pdflatex=q/pdflatex -synctex=1 -interaction=nonstopmode/" -pdf %.tex

Best Answer

Kind of late but I had the same question today. I found that in Texmaker, go to Options > Configure Texmaker > Quick Build and select "Latexmk x View PDF".

Then by using the shortcut key F1 for Quick Build (note you can change these in Options), you can compile your document using latexmk and it will automatically open a window with the compiled .pdf. So no need to install additional software!

**Another thing I also discovered is that you can embed the pdf so you can see your tex code side-by-side with your pdf viewer by going into Options > Configure Texmaker and on the right, there's a section for "PDF viewer" in bold. If you check the "Embed" option, and then click OK, you'll get the pdf side-by-side with tex code.

I hope this helps!

Related Question