# Style for Goxel.
#
# This is still a work in progress, and shouldn't be used systematically yet.
# Unfortunately I couldn't make it work with the style I like, so for the
# moment I disable all alignments.

BasedOnStyle: LLVM

AllowShortFunctionsOnASingleLine: Empty
AllowShortIfStatementsOnASingleLine: WithoutElse

Cpp11BracedListStyle: false

SpacesInContainerLiterals: false

ColumnLimit: 79
PenaltyExcessCharacter: 1000

# Never use tabs for indentation.
UseTab: Never
TabWidth: 4
IndentWidth: 4

ContinuationIndentWidth: 8
BracedInitializerIndentWidth: 4

BreakBeforeBraces: Custom
BraceWrapping:
  AfterClass: false
  AfterControlStatement: MultiLine
  AfterEnum: false
  AfterFunction: true
  AfterNamespace: false
  AfterStruct: false
  AfterUnion: false
  BeforeCatch: true
  BeforeElse: true
  IndentBraces: false

BinPackParameters: false
AllowAllArgumentsOnNextLine: true

SortIncludes: true

PenaltyReturnTypeOnItsOwnLine: 10000
PenaltyBreakAssignment: 100
PenaltyIndentedWhitespace: 2

ForEachMacros:
  - DL_FOREACH
  - DL_FOREACH
  - DL_FOREACH2
  - DL_FOREACH_SAFE
  - DL_FOREACH_SAFE2
  - DL_FOREACH_REVERSE
