Skip to content

settings support for configuring indentation of brackets (c-like languages) #249557

Open
@alanbork

Description

@alanbork

Currently there's no way to configure "indent as you type" rules to match your preferred style. There are quite a few recognized common styles (eg https://en.wikipedia.org/wiki/Indentation_style) and precisely matching all of them might be outside the scope of VScode, and better suited for a extension. But the biggest differentiation between those styles comes down to whether opening and or closing brackets are indented to match the code block. Offering a check box option for "indent opening bracket" and an separate one for "indent closing bracket" would go a long ways towards supporting developer choice. Right now developer choice comes down to using Jetbrains instead which offers nearly infinite customization on this regard, but has gone too far down that path with 100+ settings for auto-styling.

The current vscode style (Allman) would have both of those check boxes unchecked for c-like languages. Whitesmiths would have both checked. By only checking one or the other of those boxes, K&R and Ratliff would be supported.

Metadata

Metadata

Assignees

Labels

editor-autoindentEditor auto indentation issuesfeature-requestRequest for new features or functionality

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions