forked from Bionus/imgbrd-grabber
-
Notifications
You must be signed in to change notification settings - Fork 0
/
uncrustify.cfg
104 lines (93 loc) · 3.1 KB
/
uncrustify.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
# Use tabs
indent_with_tabs = 2
input_tab_size = 4
output_tab_size = 4
indent_columns = output_tab_size
align_with_tabs = true
align_on_tabstop = true
# Indent inside classes
indent_class = 1
indent_access_spec = 1
indent_access_spec_body = true
# Force a line break at the end of files
nl_end_of_file = force
nl_end_of_file_min = 1
# Stick pointer and reference symbol to variable
align_var_def_star_style = 1
align_var_def_amp_style = 1
# Allow empty function body to be written as '{}'
nl_collapse_empty_body = true
# Indent instead of aligning
indent_align_assign = false
indent_single_after_return = true
indent_func_call_param = true
indent_member_single = true
indent_paren_close = 2
indent_shift = true
indent_cpp_lambda_only_once = true
# Keep one line control structures
nl_func_leave_one_liners = true
nl_cpp_lambda_leave_one_liners = true
nl_if_leave_one_liners = false
nl_while_leave_one_liners = false
nl_for_leave_one_liners = false
# Preprocessor
pp_indent_at_level = true
pp_if_indent_code = true
# Others
indent_ternary_operator = 0
indent_namespace = true
mod_paren_on_return = ignore
indent_switch_case = 4
cmt_indent_multi = false
use_options_overriding_for_qt_macros = false
# Force braces
mod_full_brace_do = force
mod_full_brace_for = force
mod_full_brace_function = force
mod_full_brace_if = force
mod_full_brace_while = force
mod_full_brace_using = force
# Line breaks
nl_enum_brace = force # "enum {" vs "enum \n {"
nl_union_brace = force # "union {" vs "union \n {"
nl_struct_brace = force # "struct {" vs "struct \n {"
nl_do_brace = remove # "do {" vs "do \n {"
nl_if_brace = remove # "if () {" vs "if () \n {"
nl_for_brace = remove # "for () {" vs "for () \n {"
nl_else_brace = remove # "else {" vs "else \n {"
nl_while_brace = remove # "while () {" vs "while () \n {"
nl_switch_brace = force # "switch () {" vs "switch () \n {"
nl_brace_while = remove # "} while" vs "} \n while" - cuddle while
nl_brace_else = remove # "} else" vs "} \n else" - cuddle else
nl_fcall_brace = force # "list_for_each() {" vs "list_for_each()\n{"
nl_fdef_brace = force # "int foo() {" vs "int foo()\n{"
# Spaces
sp_sizeof_paren = remove # "sizeof (int)" vs "sizeof(int)"
sp_before_sparen = force # "if (" vs "if("
sp_after_sparen = force # "if () {" vs "if (){"
sp_after_cast = force # "(int) a" vs "(int)a"
sp_cmt_cpp_start = force # '// A' vs '//A'.
sp_inside_braces = ignore # "{ 1 }" vs "{1}"
sp_inside_braces_struct = force # "{ 1 }" vs "{1}"
sp_inside_braces_enum = force # "{ 1 }" vs "{1}"
sp_inside_braces_empty = remove # "{ }" vs "{}"
sp_else_brace = force # "else {" vs "else{"
sp_brace_else = force # "} else" vs "}else"
sp_assign = force
sp_arith = force
sp_bool = force
sp_compare = force
sp_angle_paren = remove
sp_angle_paren_empty = remove
sp_angle_shift = remove
sp_permit_cpp11_shift = true
sp_template_angle = force
sp_before_angle = remove
sp_inside_angle = remove
sp_assign = force
sp_after_comma = force
sp_func_def_paren = remove # "int foo (){" vs "int foo(){"
sp_func_call_paren = remove # "foo (" vs "foo("
sp_func_proto_paren = remove # "int foo ();" vs "int foo();"
sp_cpp_lambda_assign = remove # "[ = ]() {}" vs "[=]() {}"