Possible Duplicate:
How to write hidden notes in a LaTeX file?
Conditional typesetting / build

Is it possible to add a flag (variable) in my .tex file, so that I can switch among two modes: a light version and a full version?

The text which is supposed to be displayed in full mode could be wrapped in an environment:

... flag ...

So when flag is 0, the text wrapped in fullmode is hidden in the pdf file generated; while flag is 1, the text wrapped in fullmode is displayed ...

Does anyone know how to realize that?

marked as duplicate by egreg, user11232, Marco Daniel, diabonas, Claudio Fiandrino Sep 30 '12 at 14:42

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.


You can use the versions package and use the commands \includeversion{fullmode} or \excludeversions{fullmode} in the preamble as your flag.

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