CC Mode Manual
3. New Indentation Engine
CC Mode has a new indentation engine, providing a simplified, yet
flexible and general mechanism for customizing indentation. It separates
indentation calculation into two steps: first, CC Mode analyzes the
line of code being indented to determine the kind of language construct
it's looking at, then it applies user defined offsets to the current
line based on this analysis.
This section will briefly cover how indentation is calculated in
CC Mode. It is important to understand the indentation model
being used so that you will know how to customize CC Mode for
your personal coding style.