axmol/.clang-format

64 lines
1.6 KiB
Plaintext
Raw Normal View History

2021-07-15 23:03:43 +08:00
# This file is copy from https://github.com/google/angle with some modifications
# Defines the ADXE style for automatic reformatting.
# https://code.google.com/p/angleproject/wiki/CodingStandard
# See Clang docs: http://clang.llvm.org/docs/ClangFormatStyleOptions.html
BasedOnStyle: Chromium
2021-07-15 23:03:43 +08:00
# Allow double brackets such as std::vector<std::vector<int>>.
2021-04-24 18:13:28 +08:00
Standard: Cpp11
2021-07-15 23:03:43 +08:00
# Indent 4 spaces at a time.
IndentWidth: 4
# Keep lines under 120 columns long.
ColumnLimit: 120
SortIncludes: false
2021-07-15 23:03:43 +08:00
# Always break before braces
BreakBeforeBraces: Custom
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
AfterControlStatement: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterStruct: true
AfterUnion: true
BeforeCatch: true
BeforeElse: true
IndentBraces: false
SplitEmptyFunction: false
SplitEmptyRecord: false
SplitEmptyNamespace: false
# Keeps extern "C" blocks unindented.
AfterExternBlock: false
# Indent case labels.
IndentCaseLabels: true
# Left-align pointers and references
PointerAlignment: Left
2021-07-15 23:03:43 +08:00
# ANGLE likes to align things as much as possible.
AlignOperands: true
AlignConsecutiveAssignments: true
2021-07-15 23:03:43 +08:00
2021-07-19 12:26:25 +08:00
# Use 0 space negative offset for access modifiers
AccessModifierOffset: -4
2021-07-15 23:03:43 +08:00
# TODO(jmadill): Decide if we want this on. Doesn't have an "all or none" mode.
AllowShortCaseLabelsOnASingleLine: false
# Useful for spacing out functions in classes
KeepEmptyLinesAtTheStartOfBlocks: true
# Indent nested PP directives.
IndentPPDirectives: AfterHash
# Include blocks style
IncludeBlocks: Preserve
2021-04-24 17:11:04 +08:00
UseTab: Never
2021-07-15 23:03:43 +08:00
BreakConstructorInitializers: BeforeComma