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

How to do proper line breaking (continuation) for commands, i.e. their options and/or their arguments? For example, in order to transform this:

\usepackage[top=1.0cm, bottom=1.0cm, left=1.0cm, right=1.0cm, includehead, includefoot]{geometry}

Into this:

share|improve this question
Welcome to TeX.sx! The form of the input is mostly your responsibility. Remember that an end of line count as a space, but a blank line counts as and end of paragraph command. – egreg Feb 7 '13 at 22:10
up vote 6 down vote accepted

I don't know if I understood your question. Do you want to break lines automatically? You can just type RETURN. Also, insert a comment command at the end of line.

share|improve this answer
Do I really need % at the end? Just tested - it seems to compile without it. – Alexander Shukaev Feb 7 '13 at 22:08
For option lists the % at the end of lines is not necessary. However it is in many other situations, particularly in definitions of commands. – egreg Feb 7 '13 at 22:08
Alright, thank you for the quick turn guys. Best regards. – Alexander Shukaev Feb 7 '13 at 22:10

keyval (and I think most key/value parsing packages following it) trims all white space around the , and the =. So


is the same as

[ a
b , , , ,
share|improve this answer
That's good news. Basically, I asked this question because I was afraid that LaTeX is being very precise on how one types commands. But, now it seems that parser does a great job on grabbing those tokens. Thanks for the tip. – Alexander Shukaev Feb 7 '13 at 22:18
@Haroogan, yes. This is a good property. We don't need to format our texts and remove all the extra empty spaces between the words (as we have in MS Word). – Sigur Feb 7 '13 at 22:22
Just a very kind author of that package, takes care of user input. – David Carlisle Feb 7 '13 at 22:22

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.