BasedOnStyle: WebKit Standard: Cpp11 ColumnLimit: 0 # We want a space between the type and the star for pointer types. DerivePointerAlignment: false PointerAlignment: Right # We use template< without space. SpaceAfterTemplateKeyword: false # We want to break before the operators, but not before a '='. BreakBeforeBinaryOperators: false # Braces are usually attached, but not after functions or class declarations. BreakBeforeBraces: Custom BraceWrapping: AfterClass: true AfterControlStatement: false AfterEnum: false AfterFunction: true AfterNamespace: false AfterObjCDeclaration: false AfterStruct: false AfterUnion: false BeforeCatch: false BeforeElse: false IndentBraces: false # When constructor initializers do not fit on one line, put them each on a new line. ConstructorInitializerAllOnOneLineOrOnePerLine: true # Indent initializers by 4 spaces ConstructorInitializerIndentWidth: 4 # Indent width for line continuations. ContinuationIndentWidth: 8 # No indentation for namespaces. NamespaceIndentation: None # Horizontally align arguments after an open bracket. # The coding style does not specify the following, but this is what gives # results closest to the existing code. AlignAfterOpenBracket: true BreakTemplateDeclarations: Yes # Ideally we should also allow less short function in a single line, but # clang-format does not handle that. AllowShortFunctionsOnASingleLine: Inline # Sort includes and regroup them into consistent blocks: # 0. self include (the .h matching the .cpp, automatic) # 1. project includes "" # 2. Qt includes # 3. system includes <...> SortIncludes: CaseSensitive IncludeBlocks: Regroup IncludeCategories: - Regex: "^\"" Priority: 1 - Regex: "^