TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been a relatively long-time user of TeXnicCenter, and whenever I recompiled a tex file to PDF and viewed the output in that program, I would get an updated version of the PDF that was already open.

I started using Kile and realized that whenever I tried doing the same thing, Kile would open a new PDF file, even if an older version of the PDF was already open. I was wondering if there is some way to change this, so that the old PDF file becomes updated, and so that I wouldn't end up with multiple versions of the same PDF open.

share|improve this question
If you have the PDF open and then compile by pressing PDFLaTex the old PDF gets updated. There is no need to press ViewPDF. Pressing ViewPDF (or compiling with QuickBuild) creates another PDF. I don't see any way to change that through configuring Kile or Okular. – DJP Jul 27 '11 at 6:25
Oh, I see. I guess that was just a habit that carried over from before. Thanks for the help! – user3129 Jul 28 '11 at 5:54
@DJP Could you make you make your comment into an answer? – Torbjørn T. Oct 1 '11 at 21:06
Done. Should these comments to the original post be removed as well? – DJP Oct 1 '11 at 23:19
Under "ViewPDF" there is a configuration "Okular unique", which seems to do what you want; unfortunately, it is not very convenient, since it reloads the file in the same okular window, but at the first page each time. On the other hand, letting okular just refresh the file, as suggested by @DJP, retains your view. – nplatis May 9 '13 at 7:26

The standard viewer for Kile is Okular. Under Settings >> configure Kile >> Tools >> Build >> viewPDF you need to add --unique to the options. This will make Okular only open a single window.

share|improve this answer

I've been annoyed by that problem, too. Unfortunately, I don't see any way to prevent the behavior through configuring Kile or the PDF viewer (Okular for me).

But if you want to avoid having multiple PDFs being created, don't compile with QuickBuild. Compile with PDFLaTeX and click on the old PDF file and you will find it has been updated. Do not press ViewPDF or another PDF viewer instance is created.

share|improve this answer

I had the same problem too, and it drove me crazy. Here is a fix that might work. I use evince as the default pdf/ps viewer in Kile, the default in my installation was Okular. You can go to Tools> Configure Kile> Buid > ViewPdf and change command to evince. Of course you must have evince in installed.

share|improve this answer

This is not a direct answer, rather a workaround (taken from here). Have a script that checks if okular is open already, in which case doesn't invoke okular again.

open=`ps -fe | grep "okular $1.pdf" | grep -vc grep`
if [ $open -eq 0 ]; then
  okular $1.pdf &

Then in okular's settings (Settings->Okular Settings->General), select Reload document on file change.

share|improve this answer

You could configure Quickbuild to only use PDFLaTeX (without ViewPDF) and save it from Settings->tools->Build menu.

share|improve this answer
Welcome to TeX.sx! – Kurt Apr 16 '13 at 9:32

In my case the answer from StrongBad didn't work. But then I saw, that KILE has the option to directly select "Okular Unique" as configuration. With this setup all things work as expected.Configuration KILE unique PDF

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.