Add: Setting to uniformly slow the acceleration and braking of realistic trains
[openttd-jgr.git] / .editorconfig
blob7b001a859ef90a7ccc0297d3e4e831291b45820a
1 root = true
3 [*]
4 insert_final_newline = true
5 trim_trailing_whitespace = true
7 [*.{c,cpp,h,hpp}]
8 indent_style = tab
9 charset = utf-8
10 #indent_size = <integer>
11 #tab_width = <integer>
12 #end_of_line = <lf, cf, crlf>
14 ### C++ specific editor config rules ###
15 ## Visual Studio ## https://learn.microsoft.com/en-us/visualstudio/ide/cpp-editorconfig-properties?view=vs-2019 ##
16 # Indentation #
17 # Do not indent braces
18 cpp_indent_braces = false
19 # When a new line is typed, it's indented relatively to the innermost open parenthesis
20 cpp_indent_multi_line_relative_to = innermost_parenthesis
21 # Indent new lines within parenthesis
22 cpp_indent_within_parentheses = indent
23 # In existing code, do not use the setting for alignment of new lines within parentheses
24 cpp_indent_preserve_within_parentheses = true
25 # Indent case contents
26 cpp_indent_case_contents = true
27 # Indent case labels
28 cpp_indent_case_labels = true
29 # Do not indent braces following a case statement
30 cpp_indent_case_contents_when_block = false
31 # Do not indent braces of lambdas used as parameters
32 cpp_indent_lambda_braces_when_parameter = false
33 # No override for "Position of goto labels" (Unspecified)
34 #cpp_indent_goto_labels
35 # Move preprocessor directives to the leftmost column
36 cpp_indent_preprocessor = leftmost_column
37 # Do not indent access specifiers
38 cpp_indent_access_specifiers = false
39 # Indent namespace contents
40 cpp_indent_namespace_contents = true
41 # Preserve indentation of comments
42 cpp_indent_preserve_comments = true
44 # Newline #
45 # Keep open braces for namespaces on the same line, but add a space before the brace
46 cpp_new_line_before_open_brace_namespace = same_line
47 # Keep open braces for types/classes on the same line, but add a space before the brace
48 cpp_new_line_before_open_brace_type = same_line
49 # Move open braces for functions to a new line
50 cpp_new_line_before_open_brace_function = new_line
51 # Keep open braces for control blocks on the same line, but add a space before the brace
52 cpp_new_line_before_open_brace_block = same_line
53 # Keep open braces for lambdas on the same line, but add a space before the brace
54 cpp_new_line_before_open_brace_lambda = same_line
55 # Place scope braces on separate lines
56 cpp_new_line_scope_braces_on_separate_lines = true
57 # Do not move closing braces to the same line as opening braces for empty types
58 cpp_new_line_close_brace_same_line_empty_type = false
59 # Do not move closing braces to the same line as opening braces for empty function bodies
60 cpp_new_line_close_brace_same_line_empty_function = false
61 # Do not place 'catch' and similar keywords on a new line
62 cpp_new_line_before_catch = false
63 # Do not place 'else' on a new line
64 cpp_new_line_before_else = false
65 # Do not place 'while' in a do-while loop on a new line
66 cpp_new_line_before_while_in_do_while = false
68 # Spacing #
69 # Remove spaces between function names and opening parentheses of argument lists
70 cpp_space_before_function_open_parenthesis = remove
71 # Do not insert a space within parentheses of an argument list
72 cpp_space_within_parameter_list_parentheses = false
73 # Do not insert a space between parentheses when argument list is empty
74 cpp_space_between_empty_parameter_list_parentheses = false
75 # Insert space between keyword and opening parenthesis in control flow statements
76 cpp_space_after_keywords_in_control_flow_statements = true
77 # Do not insert a space within parentheses of a control statement
78 cpp_space_within_control_flow_statement_parentheses = false
79 # Do not insert a space before opening parenthesis of lambda argument lists
80 cpp_space_before_lambda_open_parenthesis = false
81 # Do not insert a space within parentheses of a C-style cast
82 cpp_space_within_cast_parentheses = false
83 # Do not insert a space after closing parenthesis of C-style cast
84 cpp_space_after_cast_close_parenthesis = false
85 # Do not insert a space within parentheses of a parenthesized expression
86 cpp_space_within_expression_parentheses = false
87 # Insert space before opening brace of blocks
88 cpp_space_before_block_open_brace = true
89 # Do not insert a space between empty braces
90 cpp_space_between_empty_braces = false
91 # Do not insert a space before opening brace of uniform initialization and initializer lists
92 cpp_space_before_initializer_list_open_brace = false
93 # No override for "Insert space within braces of uniform initialization and initializer lists" (Spacing for this varies)
94 #cpp_space_within_initializer_list_braces
95 # Preserve spaces inside uniform initialization and initializer lists
96 cpp_space_preserve_in_initializer_list = true
97 # Do not insert space before opening square brackets
98 cpp_space_before_open_square_bracket = false
99 # Do not insert space within square bracket
100 cpp_space_within_square_brackets = false
101 # Do not insert space before empty square brackets
102 cpp_space_before_empty_square_brackets = false
103 # Do not insert space between empty square brackets
104 cpp_space_between_empty_square_brackets = false
105 # Group square brackets for multi-dimensional arrays together
106 cpp_space_group_square_brackets = true
107 # Do not insert space within square brackets for lambdas
108 cpp_space_within_lambda_brackets = false
109 # Do not insert space between empty lambda brackets
110 cpp_space_between_empty_lambda_brackets = false
111 # Do not insert space before commas
112 cpp_space_before_comma = false
113 # Insert space after commas
114 cpp_space_after_comma = true
115 # Remove spaces before and after member operators
116 cpp_space_remove_around_member_operators = true
117 # Insert space before colon for base in type declarations
118 cpp_space_before_inheritance_colon = true
119 # Insert space before colon for constructors
120 cpp_space_before_constructor_colon = true
121 # Remove space before semicolons
122 cpp_space_remove_before_semicolon = true
123 # No override for "Insert space after semicolons" (Depends on if loop is unconditional)
124 #cpp_space_after_semicolon
125 # Remove spaces between unary operators and their operands
126 cpp_space_remove_around_unary_operator = true
127 # Insert spaces before and after binary operators
128 cpp_space_around_binary_operator = insert
129 # Insert spaces around assignment operators
130 cpp_space_around_assignment_operator = insert
131 # Align pointer/reference symbol to the right
132 cpp_space_pointer_reference_alignment = right
133 # Insert spaces around conditional operators
134 cpp_space_around_ternary_operator = insert
136 # Wrapping #
137 # Always apply New Lines settings for blocks
138 cpp_wrap_preserve_blocks = never
142 ## Rider & ReSharper ## https://www.jetbrains.com/help/resharper/EditorConfig_CPP_CppBlankLinesPageScheme.html ##
143 # Blank Lines #
144 # No override for "Max blank lines in declarations" (Unspecified; Not consistent across source code)
145 #cpp_keep_blank_lines_in_declarations
146 # No override for "Max blank lines in rest of source code" (Unspecified; Not consistent across source code)
147 #cpp_keep_blank_lines_in_code
148 # No override for "Number of blank lines around class/struct/enum definition" (Unspecified; Not consistent across source code)
149 #cpp_blank_lines_around_class_definition
150 # No override for "Number of blank lines around function declarations" (Unspecified; Not consistent across source code)
151 #cpp_blank_lines_around_function_declaration
152 # No override for "Number of blank lines around function definitions" (Unspecified; Not consistent across source code)
153 #cpp_blank_lines_around_function_definition
154 # No override for "Number of blank lines around single line function definitions" (Unspecified; Not consistent across source code)
155 #cpp_blank_lines_around_single_line_function_definition
156 # No override for "Number of blank lines around namespaces" (Unspecified; Not consistent across source code)
157 #cpp_blank_lines_around_namespace
158 # No override for "Number of blank lines around other definitions and declarations" (Unspecified; Not consistent across source code)
159 #cpp_blank_lines_around_other_declaration
161 # Braces Layout #
162 # Keep open braces for namespace declarations on the same line, but add a space before the brace
163 cpp_namespace_declaration_braces = end_of_line
164 # Keep open braces for linkage declarations on the same line, but add a space before the brace
165 cpp_linkage_specification_braces = end_of_line
166 # Keep open braces for types/classes on the same line, but add a space before the brace
167 cpp_type_declaration_braces = end_of_line
168 # Keep open braces for namespace definitions on the same line (does not modify spacing before the brace)
169 cpp_place_namespace_definitions_on_same_line = true
170 # Move open braces for functions to a new line
171 cpp_invocable_declaration_braces = next_line
172 # Keep open braces for lambdas on the same line, but add a space before the brace
173 cpp_anonymous_method_declaration_braces = end_of_line
174 # Keep open braces for case blocks on the same line, but add a space before the brace
175 cpp_case_block_braces = end_of_line
176 # No override for "Requires expression braces" style (requires expressions are a C++20 feature)
177 #cpp_requires_expression_braces
178 # Keep open braces for all other blocks on the same line, but add a space before the brace
179 cpp_other_braces = end_of_line
180 # Only indent the insides of multi-line expression braces
181 cpp_expression_braces = inside
182 # Place the braces of empty blocks together and on the same line
183 cpp_empty_block_style = together_same_line
184 # Force line breaks within simple compound statements
185 cpp_simple_block_style = line_break
186 # No override for "Regular expression for macros starting a block" (Marco blocks aren't used)
187 #cpp_macro_block_begin
188 # No override for "Regular expression for macros ending a block" (Marco blocks aren't used)
189 #cpp_macro_block_end
191 # Tabs and indents #
192 # Redundant override (Already overriden globally by 'indent_style')
193 #cpp_indent_style
194 # Redundant override (Already overriden globally by 'indent_size')
195 #cpp_indent_size
196 # Redundant override (Already overriden globally by 'tab_width')
197 #cpp_tab_width
198 # Use spaces instead of tabs as indentation for precise alignment
199 cpp_alignment_tab_fill_style = use_spaces
200 # Allow alignment even if construct is located too far to the right, more than 2/3 of 'Hard wrap at' limit
201 cpp_allow_far_alignment = true
203 # Indentation and Alignment #
204 # No override for "Continuous line indent" (Varies throughout source code)
205 #cpp_continuous_line_indent
206 # Do not use continuous line indent in function declaration and invocation parentheses
207 cpp_use_continuous_line_indent_in_method_pars = false
208 # Do not use continuous line indent in initializer lists
209 cpp_use_continuous_line_indent_in_expression_braces = false
210 # Indent namespace members (including nested ones)
211 cpp_namespace_indentation = all
212 # No override for "Indent linkage specification block members" (Unspecified)
213 #cpp_linkage_specification_indentation
214 # Do not indent access specifier from class
215 cpp_indent_access_specifiers_from_class = false
216 # Indent class member from access specifier
217 cpp_indent_class_members_from_access_specifiers = true
218 # Do not indent if a function definition or declaration is wrapped after the type
219 cpp_indent_wrapped_function_names = false
220 # Indent 'case' labels from 'switch'
221 cpp_indent_switch_labels = true
222 # No override for "Indent function declarations' parentheses" (Varies throughout source code)
223 #cpp_indent_method_decl_pars
224 # No override for "Indent method calls' parentheses" (Varies throughout source code)
225 #cpp_indent_invocation_pars
226 # No override for "Indent statement (if, while, for, etc) parentheses" (Varies throughout source code)
227 #cpp_indent_statement_pars
228 # Do not change preprocessor directives indenting
229 cpp_indent_preprocessor_directives = do_not_change
230 # No override for "Indent C++/CLI generic constraints" (C++/CLI is not used)
231 #cpp_indent_type_constraints
232 # Align/indent comments started at the first column
233 cpp_indent_comment = true
234 # Comments that comment out code will use the indentation level of the commented code.
235 cpp_place_comments_at_first_column = false
236 # Align multiline declarators in declaration
237 cpp_align_multiple_declaration = true
238 # Align multiline function parameters
239 cpp_align_multiline_parameter = true
240 # Align multiline call arguments
241 cpp_align_multiline_argument = true
242 # Do not align first of multiline call arguments with the opening parentheses
243 cpp_align_first_arg_by_paren = false
244 # Align multiline initializer list arguments
245 cpp_align_multiline_expression_brace = true
246 # No override for "Align multiline template parameters in template declaration" (Unspecified)
247 #cpp_align_multiline_type_parameter
248 # No override for "Align multiline template arguments" (Unspecified)
249 #cpp_align_multiline_type_argument
250 # Align multiline base classes in class base clause
251 cpp_align_multiline_extends_list = true
252 # Align multiline member initializers in member initializer lists
253 cpp_align_multiline_ctor_init = true
254 # Outdent commas placed on new line
255 cpp_outdent_commas = true
256 # Do not align multiline ?: operator with first line (since alignment is incorrect)
257 cpp_align_ternary = none
258 # Do not indent aligned ?: operator (since indentation varies)
259 cpp_indent_aligned_ternary = false
260 # No override for "Align multiline chained method calls" (Unspecified)
261 #cpp_align_multiline_calls_chain
262 # No override for "Outdent '.' and '->' in chained method calls on new lines" (Unspecified)
263 #cpp_outdent_dots
264 # Do not align multiline chained binary expressions
265 cpp_align_multiline_binary_expressions_chain = false
266 # Fix column alignment in adjacent lines
267 cpp_int_align_fix_in_adjacent = true
268 # Align assignments with adjacent assignments
269 cpp_int_align_eq = true
270 # Do not align declaration names with adjacent declaration names
271 cpp_int_align_declaration_names = false
272 # Align end-of-line comments with adjacent end-of-line comments
273 cpp_int_align_comments = true
275 # Spaces #
276 # Do not put space before ANY commas
277 cpp_space_before_comma = false
278 # Put space after ALL commas
279 cpp_space_after_comma = true
280 # Put space before ptr in declaration of variable
281 cpp_space_before_ptr_in_data_member = true
282 # Do not put space after ptr in declaration of variable
283 cpp_space_after_ptr_in_data_member = false
284 # Put space before ptr in declaration of multiple variables
285 cpp_space_before_ptr_in_data_members = true
286 # Do not put space after ptr in declaration of multiple variables
287 cpp_space_after_ptr_in_data_members = false
288 # Put space before ptr in return type of function
289 cpp_space_before_ptr_in_method = true
290 # Do not put space after ptr in return type of function
291 cpp_space_after_ptr_in_method = false
292 # Do not put space before ptr in abstract declaration
293 cpp_space_before_ptr_in_abstract_decl = false
294 # Put space before ref in declaration of variable
295 cpp_space_before_ref_in_data_member = true
296 # Do not put space after ref in declaration of variable
297 cpp_space_after_ref_in_data_member = false
298 # Put space before ref in declaration of multiple variables
299 cpp_space_before_ref_in_data_members = true
300 # Do not put space after ref in declaration of multiple variables
301 cpp_space_after_ref_in_data_members = false
302 # Do not put space before ref in return type of function
303 cpp_space_before_ref_in_method = false
304 # Put space after ref in return type of function
305 cpp_space_after_ref_in_method = true
306 # Do not put space before ref in abstract declaration
307 cpp_space_before_ref_in_abstract_decl = false
308 # Do not put space before parentheses in function parameters
309 cpp_space_between_method_declaration_name_and_open_parenthesis = false
310 # Do not put space before parentheses in lambda parameters
311 cpp_space_before_lambda_parentheses = false
312 # Do not put space within parentheses in function parameters
313 cpp_space_between_method_declaration_parameter_list_parentheses = false
314 # Do not put space within empty parentheses in function parameters
315 cpp_space_between_method_declaration_empty_parameter_list_parentheses = false
316 # Do not put space before angle brackets in template parameters
317 cpp_space_before_template_params = false
318 # Do not put space within angle brackets in template parameters
319 cpp_space_within_template_params = false
320 # Do not put space within empty angle brackets in template parameters
321 cpp_space_within_empty_template_params = false
322 # Do not put space before angle brackets in template arguments
323 cpp_space_before_template_args = false
324 # Do not put space within angle brackets in template arguments
325 cpp_space_within_template_args = false
326 # Do not put space between closing angle brackets in template arguments
327 cpp_space_between_closing_angle_brackets_in_template_args = false
328 # Put space around '=' in alias declaration and namespace alias
329 cpp_space_around_alias_eq = true
330 # Do not put space around '->' in trailing return types
331 cpp_space_around_deref_in_trailing_return_type = false
332 # Put space before base types list colon
333 cpp_space_before_colon_in_inheritance_clause = true
334 # Put space after base types list colon
335 cpp_space_after_colon_in_inheritance_clause = true
336 # No override for "Before C++/CLI generic constraint colon" (Unspecified)
337 #cpp_space_before_type_parameter_constraint_colon
338 # No override for "After C++/CLI generic constraint colon" (Unspecified)
339 #cpp_space_after_type_parameter_constraint_colon
340 # Put space before parentheses of control statements
341 cpp_space_after_keywords_in_control_flow_statements = true
342 # Do not put space within parentheses of control statements
343 cpp_space_between_parentheses_of_control_flow_statements = false
344 # Do not put space before semicolon in 'for' statements
345 cpp_space_before_semicolon_in_for_statement = false
346 # Put space after semicolon in 'for' statements
347 cpp_space_after_semicolon_in_for_statement = true
348 # Put space before ':' in range-based for loop
349 cpp_space_before_for_colon = true
350 # Put space after ':' in range-based for loop
351 cpp_space_after_for_colon = true
352 # Do not put space before colon in switch case or label statement
353 cpp_space_before_colon_in_case = false
354 # Put space after colon in switch case or label statement
355 cpp_space_after_colon_in_case = true
356 # Put space around binary operator
357 cpp_space_around_binary_operator = true
358 # Put space around assignment operator
359 cpp_space_around_assignment_operator = true
360 # Do not put space around dot, '->', '.*' and '->.'
361 cpp_space_around_member_access_operator = false
362 # Do not put space within any parentheses
363 cpp_space_within_parentheses = false
364 # Do not put space before array subscript brackets
365 cpp_space_before_open_square_brackets = false
366 # Do not put space within array subscript brackets
367 cpp_space_between_square_brackets = false
368 # Do not put space before empty parentheses in function call and initialization
369 cpp_space_between_method_call_name_and_opening_parenthesis = false
370 # Do not put space within parentheses in cast expressions
371 cpp_space_between_typecast_parentheses = false
372 # Do not put space after parentheses in cast expressions
373 cpp_space_after_cast = false
374 # Do not put space within parentheses in function call and initialization
375 cpp_space_between_method_call_parameter_list_parentheses = false
376 # Do not put space within empty parentheses in function call and initialization
377 cpp_space_between_method_call_empty_parameter_list_parentheses = false
378 # Put space in ternary operator '? :' before '?'
379 cpp_space_before_ternary_quest = true
380 # Put space in ternary operator '? :' after '?'
381 cpp_space_after_ternary_quest = true
382 # Put space in ternary operator '? :' before ':'
383 cpp_space_before_ternary_colon = true
384 # Put space in ternary operator '? :' after ':'
385 cpp_space_after_ternary_colon = true
386 # Do not put space before uniform initialization braces
387 cpp_space_before_initializer_braces = false
388 # Do not put space within uniform initialization braces
389 cpp_space_within_initializer_braces = false
390 # Do not put space within empty uniform initialization braces
391 cpp_space_within_empty_initializer_braces = false
392 # Put space before end of line comment
393 cpp_space_before_trailing_comment = true
394 # Preserve spaces before end of line comment
395 cpp_disable_space_changes_before_trailing_comment = true
397 # Line breaks and Wrapping #
398 # Redundant override (Already overriden globally by 'insert_final_newline')
399 #cpp_insert_final_newline
400 # Redundant override (Already overriden earlier in Visual Studio section)
401 #cpp_new_line_before_else
402 # Do not place 'while' in a do-while loop on a new line
403 cpp_new_line_before_while = false
404 # Redundant override (Already overriden earlier in Visual Studio section)
405 #cpp_new_line_before_catch
406 # Do not change the line breaks of single embedded statements
407 cpp_simple_embedded_statement_style = do_not_change
408 # Do not change the line breaks of simple 'case' statement
409 cpp_simple_case_statement_style = do_not_change
410 # Put member function definition return type on same line
411 cpp_function_definition_return_type_style = on_single_line
412 # Put top-level function definition return type on same line
413 cpp_toplevel_function_definition_return_type_style = on_single_line
414 # Put member function declaration return type on same line
415 cpp_function_declaration_return_type_style = on_single_line
416 # Put top-level function declaration return type on same line
417 cpp_toplevel_function_declaration_return_type_style = on_single_line
418 # Force template<...> of a template declaration on new line
419 cpp_break_template_declaration = line_break
420 # No override for "Break line before the requires-clause" (requires-clause is a C++20 feature)
421 #cpp_line_break_before_requires_clause
422 # Do not change the line break before the colon in member initializer lists
423 cpp_member_initializer_list_style = do_not_change
424 # Do not change the line break after the colon in member initializer lists
425 cpp_line_break_after_colon_in_member_initializer_lists = do_not_change
426 # No override for "Break line before comma in member initializer lists" (Varies throughout source code)
427 #cpp_line_break_before_comma_in_member_initializer_lists
428 # No override for "Break line after comma in member initializer lists" (Varies throughout source code)
429 #cpp_line_break_after_comma_in_member_initializer_lists
430 # No override for "Allow C++/CLI generic constraints on the same line" (C++/CLI is not used)
431 #cpp_place_type_constraints_on_same_line
432 # No override for "Keep existing line breaks" (Varies throughout source code; depends on developer preference)
433 #cpp_keep_user_linebreaks
434 # No override for "Hard wrap at _ characters" (Unspecified)
435 #cpp_max_line_length
436 # Do not prefer wrap before ','
437 cpp_wrap_before_comma = false
438 # Do not prefer wrap before ',' in base clause
439 cpp_wrap_before_comma_in_base_clause = false
440 # No override for "Wrap ternary expression" (Varies throughout source code)
441 #cpp_wrap_ternary_expr_style
442 # No override for "Prefer wrap before '?' and ':' in ternary expressions" (Varies throughout source code)
443 #cpp_wrap_before_ternary_opsigns
444 # No override for "Prefer wrap before ':'" (Varies throughout source code)
445 #cpp_wrap_before_colon
446 # No override for "Prefer wrap before first C++/CLI generic constraint" (C++/CLI is not used)
447 #cpp_wrap_before_first_type_parameter_constraint
448 # No override for "Wrap multiple C++/CLI generic constraints" (C++/CLI is not used)
449 #cpp_wrap_multiple_type_parameter_constraints_style
450 # No override for "Wrap enum definition" (Varies throughout source code)
451 #cpp_wrap_enumeration_style
452 # No override for "Wrap braced initializer list" (Varies throughout source code)
453 #cpp_wrap_braced_init_list_style
454 # No override for "Wrap base classes list" (Varies throughout source code)
455 #cpp_wrap_base_clause_style
456 # No override for "Wrap constructor initializer" (Varies throughout source code)
457 #cpp_wrap_ctor_initializer_style
458 # No override for "Wrap formal parameters" (Varies throughout source code)
459 #cpp_wrap_parameters_style
460 # Do not prefer wrap before '(' in declaration
461 cpp_wrap_before_declaration_lpar = false
462 # Prefer wrap after '(' in declaration
463 cpp_wrap_after_declaration_lpar = true
464 # Do not prefer wrap before ')' in declaration
465 cpp_wrap_before_declaration_rpar = false
466 # No override for "Wrap invocation arguments" (Varies throughout source code)
467 #cpp_wrap_arguments_style
468 # Do not prefer wrap before '(' in invocation
469 cpp_wrap_before_invocation_lpar = false
470 # Prefer wrap after '(' in invocation
471 cpp_wrap_after_invocation_lpar = true
472 # Do not prefer wrap before ')' in invocation
473 cpp_wrap_before_invocation_rpar = false
474 # Prefer wrap after '{' in initializer lists
475 cpp_wrap_after_expression_lbrace = true
476 # Do not prefer wrap before '}' in initializer lists
477 cpp_wrap_before_expression_rbrace = false