Skip to content
Snippets Groups Projects
Commit 03d04a80 authored by Andreas Traczyk's avatar Andreas Traczyk
Browse files

misc: update .clang-format file

Change-Id: I8fd6b6dcf9a7bf539add5a9e64d14821ecc89387
parent 512168c4
Branches
Tags
No related merge requests found
# Based on the .clang-format for Qt Creator
#
# This is for clang-format >= 10.0.
#
# https://releases.llvm.org/10.0.0/tools/clang/docs/ClangFormatStyleOptions.html
#
---
Language: Cpp Language: Cpp
AccessModifierOffset: -4 AccessModifierOffset: -4
AlignAfterOpenBracket: Align AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false AlignConsecutiveDeclarations: false
AlignConsecutiveMacros: true
AlignEscapedNewlines: DontAlign AlignEscapedNewlines: DontAlign
AlignOperands: true AlignOperands: true
AlignTrailingComments: true AlignTrailingComments: true
...@@ -11,11 +19,11 @@ AllowShortBlocksOnASingleLine: false ...@@ -11,11 +19,11 @@ AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: Inline AllowShortFunctionsOnASingleLine: Inline
AllowShortIfStatementsOnASingleLine: false AllowShortIfStatementsOnASingleLine: false
AllowShortLambdasOnASingleLine: Inline
AllowShortLoopsOnASingleLine: false AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterReturnType: None AlwaysBreakAfterReturnType: TopLevelDefinitions
AlwaysBreakBeforeMultilineStrings: false AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: true AlwaysBreakTemplateDeclarations: Yes
AlwaysBreakAfterDefinitionReturnType: All
BinPackArguments: false BinPackArguments: false
BinPackParameters: false BinPackParameters: false
BraceWrapping: BraceWrapping:
...@@ -67,7 +75,6 @@ IndentWrappedFunctionNames: false ...@@ -67,7 +75,6 @@ IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave JavaScriptQuotes: Leave
JavaScriptWrapImports: true JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false KeepEmptyLinesAtTheStartOfBlocks: false
# Do not add QT_BEGIN_NAMESPACE/QT_END_NAMESPACE as this will indent lines in between.
MacroBlockBegin: "" MacroBlockBegin: ""
MacroBlockEnd: "" MacroBlockEnd: ""
MaxEmptyLinesToKeep: 1 MaxEmptyLinesToKeep: 1
...@@ -82,13 +89,14 @@ PenaltyBreakFirstLessLess: 400 ...@@ -82,13 +89,14 @@ PenaltyBreakFirstLessLess: 400
PenaltyBreakString: 600 PenaltyBreakString: 600
PenaltyExcessCharacter: 50 PenaltyExcessCharacter: 50
PenaltyReturnTypeOnItsOwnLine: 300 PenaltyReturnTypeOnItsOwnLine: 300
PointerAlignment: Right PointerAlignment: Left
ReflowComments: false ReflowComments: true
SortIncludes: true SortIncludes: false
SortUsingDeclarations: true SortUsingDeclarations: false
SpaceAfterCStyleCast: true SpaceAfterCStyleCast: true
SpaceAfterTemplateKeyword: false SpaceAfterTemplateKeyword: false
SpaceBeforeAssignmentOperators: true SpaceBeforeAssignmentOperators: true
SpaceBeforeCpp11BracedList: true
SpaceBeforeParens: ControlStatements SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1 SpacesBeforeTrailingComments: 1
...@@ -99,3 +107,4 @@ SpacesInParentheses: false ...@@ -99,3 +107,4 @@ SpacesInParentheses: false
SpacesInSquareBrackets: false SpacesInSquareBrackets: false
Standard: Cpp11 Standard: Cpp11
TabWidth: 4 TabWidth: 4
UseTab: Never
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment