From 84a501f516a4aa0e013d53fb7150f4ed1e3e3bac Mon Sep 17 00:00:00 2001 From: Rupert Date: Wed, 4 Dec 2024 23:50:20 +0100 Subject: [PATCH] clang-format update - Add Alignment for bitfields. - BreakBefore*Operators: adhere to GIMP Coding Style. - Align... AcrossComments: allows section comments in long lists w/o disturbing alignment (e.g. the struct at top of bmp-load.c). Alignment can still be reset with a newline. --- .clang-format | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.clang-format b/.clang-format index 13efcc2dff5..fe2521d2844 100644 --- a/.clang-format +++ b/.clang-format @@ -9,15 +9,18 @@ BasedOnStyle: GNU AlignAfterOpenBracket: Align AlignArrayOfStructures: Left -AlignConsecutiveAssignments: Consecutive -AlignConsecutiveDeclarations: Consecutive -AlignConsecutiveMacros: Consecutive +AlignConsecutiveAssignments: AcrossComments +AlignConsecutiveDeclarations: AcrossComments +AlignConsecutiveBitFields: AcrossComments +AlignConsecutiveMacros: AcrossComments AlignEscapedNewlines: Left AllowAllParametersOfDeclarationOnNextLine: false AlwaysBreakAfterReturnType: AllDefinitions BinPackParameters: false +BreakBeforeBinaryOperators: None BreakBeforeBraces: GNU +BreakBeforeTernaryOperators: false IndentWidth: 2 PointerAlignment: Right UseTab: Never -- GitLab