Lisp Indent Program Indent Custom C Indent
Here are the commands for indentation in C mode and related modes:
C-c C-q
|
Reindent the current top-level function definition or aggregate type
declaration ( |
C-M-q
|
Reindent each line in the balanced expression that follows point
( |
|
Reindent the current line, and/or in some cases insert a tab character
(
If
If that variable is
Any other value (not |
C-u
|
Reindent the current line according to its syntax; also rigidly reindent any other lines of the expression that starts on the current line. See Multi-line Indent. |
To reindent the whole current buffer, type C-x h C-M-\. This first selects the whole buffer as the region, then reindents that region.
To reindent the current block, use C-M-u C-M-q. This moves to the front of the block and then reindents it all.
Lisp Indent Program Indent Custom C Indent