Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

This question already has an answer here:

Is there any indentation tool for (la)tex?

I currently use TexShop under Mac OSX, so I can either use a TexShop plugin or a command line tool.

share|improve this question
    
I just select the text I want indented and use command ] to indent, and command [ to unindent. Not very automated, but does work, and that way I have control of what it looks like. –  Peter Grill Feb 23 '13 at 17:13
    
It shifts the entire block of text. I'm looking for a utility that can indent inner parts (e.g. subsections) more than their parents (e.g. sections). –  Adam Matan Feb 23 '13 at 18:12
1  
What about Emacs? ;) –  mbork Feb 23 '13 at 18:20
    
As you are typing after a section, just use command ] on the first line, then all lines following will retain that indent (at least in TeXShop). Similarly if you are coming out of an indented block, use command [. For text that already exist select the block you want to indent and apply command ]. Any automated tool won't easily be able to work with custom environments or macros without some configuration set up. –  Peter Grill Feb 23 '13 at 18:25
add comment

marked as duplicate by Joseph Wright Aug 10 '13 at 9:18

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.

1 Answer

up vote 6 down vote accepted

Just have a look to indent.plx. In my opinion an interesting tool. Have a look at LaTeX code sniffer and/or beautifier? for details.

share|improve this answer
add comment

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