.clang-format 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. Language: Cpp
  2. # BasedOnStyle: Google
  3. AccessModifierOffset: -1
  4. AlignAfterOpenBracket: Align
  5. AlignConsecutiveAssignments: false
  6. AlignConsecutiveDeclarations: false
  7. AlignEscapedNewlinesLeft: true
  8. AlignOperands: true
  9. AlignTrailingComments: true
  10. AllowAllParametersOfDeclarationOnNextLine: true
  11. AllowShortBlocksOnASingleLine: false
  12. AllowShortCaseLabelsOnASingleLine: false
  13. AllowShortFunctionsOnASingleLine: All
  14. AllowShortIfStatementsOnASingleLine: true
  15. AllowShortLoopsOnASingleLine: true
  16. AlwaysBreakAfterDefinitionReturnType: None
  17. AlwaysBreakAfterReturnType: None
  18. AlwaysBreakBeforeMultilineStrings: true
  19. AlwaysBreakTemplateDeclarations: true
  20. BinPackArguments: true
  21. BinPackParameters: true
  22. BraceWrapping:
  23. AfterClass: true
  24. AfterControlStatement: true
  25. AfterEnum: true
  26. AfterFunction: true
  27. AfterNamespace: true
  28. AfterObjCDeclaration: true
  29. AfterStruct: true
  30. AfterUnion: true
  31. BeforeCatch: true
  32. BeforeElse: true
  33. IndentBraces: false
  34. BreakBeforeBinaryOperators: None
  35. BreakBeforeBraces: Allman
  36. BreakBeforeTernaryOperators: true
  37. BreakConstructorInitializers: BeforeColon
  38. BreakConstructorInitializersBeforeComma: false
  39. ColumnLimit: 80
  40. CommentPragmas: '^ IWYU pragma:'
  41. ConstructorInitializerAllOnOneLineOrOnePerLine: false
  42. ConstructorInitializerIndentWidth: 0
  43. ContinuationIndentWidth: 2
  44. Cpp11BracedListStyle: true
  45. DerivePointerAlignment: true
  46. DisableFormat: false
  47. ExperimentalAutoDetectBinPacking: false
  48. ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
  49. IncludeCategories:
  50. - Regex: '^<.*\.h>'
  51. Priority: 1
  52. - Regex: '^<.*'
  53. Priority: 2
  54. - Regex: '.*'
  55. Priority: 3
  56. IndentCaseLabels: true
  57. IndentWidth: 2
  58. IndentWrappedFunctionNames: false
  59. KeepEmptyLinesAtTheStartOfBlocks: false
  60. MacroBlockBegin: ''
  61. MacroBlockEnd: ''
  62. MaxEmptyLinesToKeep: 1
  63. NamespaceIndentation: None
  64. ObjCBlockIndentWidth: 2
  65. ObjCSpaceAfterProperty: false
  66. ObjCSpaceBeforeProtocolList: false
  67. PenaltyBreakBeforeFirstCallParameter: 1
  68. PenaltyBreakComment: 300
  69. PenaltyBreakFirstLessLess: 120
  70. PenaltyBreakString: 1000
  71. PenaltyExcessCharacter: 1000000
  72. PenaltyReturnTypeOnItsOwnLine: 200
  73. PointerAlignment: Left
  74. ReflowComments: true
  75. SortIncludes: true
  76. SpaceAfterCStyleCast: false
  77. SpaceBeforeAssignmentOperators: true
  78. SpaceBeforeParens: ControlStatements
  79. SpaceInEmptyParentheses: false
  80. SpacesBeforeTrailingComments: 2
  81. SpacesInAngles: false
  82. SpacesInContainerLiterals: true
  83. SpacesInCStyleCastParentheses: false
  84. SpacesInParentheses: false
  85. SpacesInSquareBrackets: false
  86. Standard: Auto
  87. TabWidth: 2
  88. UseTab: Never