auctex-devel
[Top][All Lists]

Re: [AUCTeX-devel] indenting split long command lines

 From: Tassilo Horn Subject: Re: [AUCTeX-devel] indenting split long command lines Date: Tue, 09 Apr 2013 09:32:28 +0200 User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux)

Julien Cubizolles <address@hidden> writes:

> As far as I know, AucTeX doesn't deal with pstricks in tikz code in
> any special way. Very often in this environments one needs very long
> lines, and some kind of splitting/indenting would be useful. What I
> would like is something like:
>
> \begin{tikzpicture}
>    \draw (0,0) -- (1,1) -- (2,2) -- (3,3)
>          -- (4,4) -- (5,5);
> \end{tikzpicture}
>
> To summarize: split long lines and add an indentation if not on a
> semicolon otherwise keep indentation the same as the beginning of the
> line.

You can define custom indentation functions on a per-environment basis.
See (info "(auctex)Indenting").

> At the moment I manually add a TAB (like in the second line of the
> example) but I couldn't find a way to remove the indentation for the
> third line. Is there a "go back one tab" command ?

I think you can use indent-rigidly' with a negative prefix arg.

Bye,
Tassilo

`