1

I know that % can be used to make LaTeX ignore an entire line. However, suppose that I want LaTeX to skip 50 consecutive lines of code, is there a better way to do this than inserting % 50 times in front of each line?

Werner
  • 603,163
  • This depends a lot on what you want to do; look on the site for the comment package. – egreg Apr 19 '17 at 23:06
  • @gernot Why should nested conditional bother? – egreg Apr 19 '17 at 23:07
  • 1
    I usually write \def\useless{ at the beginning and } at the end... –  Apr 19 '17 at 23:08
  • These solutions work like charms, thank you very much! – BigbearZzz Apr 19 '17 at 23:10
  • Your editor, if well configured, can probably add a % at the beginning of every line of a selection? – Bernard Apr 19 '17 at 23:11
  • \iffalse...\fi. If you use a TeX-aware editor, then there is probably a shortcut that allows you to add % signs in front of many lines at once, and also to remove them again at the same time. – gernot Apr 19 '17 at 23:11
  • 1
    @egreg I don't know. Maye because I'm pessimistic or extra-cautious? ;-) – gernot Apr 19 '17 at 23:12
  • @Bernard I use TeXstudio. I believe it should be possible but I've never tried it yet (not like I know how though). – BigbearZzz Apr 19 '17 at 23:13
  • I don't know well enough TeXstudio to say. I'm pretty sure it's possible with Emacs, and I can do (and undo) it in WinEdt. – Bernard Apr 19 '17 at 23:20

0 Answers0