# Clang-format configuration for flutter_inappwebview_linux
# Based on Google style with some adjustments for consistency

BasedOnStyle: Google
Language: Cpp
Standard: c++17

# Indentation
IndentWidth: 2
TabWidth: 2
UseTab: Never
IndentCaseLabels: true
NamespaceIndentation: None

# Line length
ColumnLimit: 100

# Braces
BreakBeforeBraces: Attach
AllowShortBlocksOnASingleLine: Empty
AllowShortFunctionsOnASingleLine: Inline
AllowShortIfStatementsOnASingleLine: Never
AllowShortLoopsOnASingleLine: false

# Alignment
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignOperands: true
AlignTrailingComments: true

# Pointers and References
DerivePointerAlignment: false
PointerAlignment: Left

# Includes
IncludeBlocks: Regroup
SortIncludes: true

# Other
SpaceAfterCStyleCast: false
SpaceBeforeParens: ControlStatements
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInParentheses: false
SpacesInSquareBrackets: false

# Keep existing line breaks where sensible
MaxEmptyLinesToKeep: 1
KeepEmptyLinesAtTheStartOfBlocks: false
