help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Indenting code: C-M-\ v C-x C-q


From: Stephen H. Westin
Subject: Re: Indenting code: C-M-\ v C-x C-q
Date: 11 Nov 2003 15:26:50 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

"Siegfried Heintze" <address@hidden> writes:

<snip>

> I just I happend to be poking around the www.Xemacs.com and noticed
> something about indenting perl code with C-M-\ and discovered it works great
> for indenting perl code in regular emacs too!
> 
> Oh -- the time I could have saved if I had known this!  Why are there two
> keys to do the same thing?

They don't. C-x C-q does a paragraph fill. With text, this means that
it takes the current paragraph (all the text surrounding the point and
between blank lines), treats it as a single line, then divides into
lines no wider than the fill column. C-M-\ indents programming code
within the currently selected region, without changing line breaks.

If writers of java-mode and such added auto indenting to "fill-paragraph",
I guess that's a nice extra feature.

<snip>

-- 
-Stephen H. Westin
Any information or opinions in this message are mine: they do not
represent the position of Cornell University or any of its sponsors.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]