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

This question already has an answer here:

I'm writing at my thesis and it has now about 60 pages.. When I want to compile it (to pdf), it lasts about 20 seconds.. Is it normal? I think, the included graphics costs a lot of time?!

Unfortunately I don't have much experience in LaTeX...

But I discovered the draft mode.. There it compiles much faster... But it omits beside the graphics also the lstlistings in my code..

In the draft of my thesis, I don't need the graphics, but the code snippets (embedded in lstlistings) would be nice..

Are there any possibilities to get this? Fast compiling and lstlistings..

share|improve this question

marked as duplicate by Martin Schröder, Jesse, egreg, Thorsten, Claudio Fiandrino Dec 14 '13 at 14:26

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

Are you using the draft as option in the class or in the graphicx package? – Sigur Dec 13 '13 at 13:11
a 190pp doc i regularly compile takes 2.5 seconds with latex, 7 seconds with pdflatex; so pdflatex itself is one source of your problem. (i suspect graphics in pdflatex are worse still, in comparison, since they have to be copied to the output, whereas latex merely puts a \special command into the output stream. (my doc doesn't have any graphics at all.) – wasteofspace Dec 13 '13 at 13:38
mh, Sigur, I use the draft option in the documentclass! – mrbela Dec 13 '13 at 13:48
split your document into multiple files and then use include and includeonly – cmhughes Dec 13 '13 at 20:30
Welcome to TeX.SX! Usually, we don't put a greeting or a “thank you” in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Accepting and upvoting answers is the preferred way here to say “thank you” to users who helped you. A suggestion: Do us a favour and change your username to something more telling than "user1234". – Martin Schröder Dec 14 '13 at 13:47
up vote 10 down vote accepted

You could compile everything in your document in draft mode except for the graphics by passing the draft option to your documentclass and then the final option, which is the inverse of draft to listings.

share|improve this answer

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