virtualx-engine/scene/main
Rémi Verschelde 07bc4e2f96 Style: Enforce separation line between function definitions
I couldn't find a tool that enforces it, so I went the manual route:
```
find -name "thirdparty" -prune \
  -o -name "*.cpp" -o -name "*.h" -o -name "*.m" -o -name "*.mm" \
  -o -name "*.glsl" > files
perl -0777 -pi -e 's/\n}\n([^#])/\n}\n\n\1/g' $(cat files)
misc/scripts/fix_style.sh -c
```

This adds a newline after all `}` on the first column, unless they
are followed by `#` (typically `#endif`). This leads to having lots
of places with two lines between function/class definitions, but
clang-format then fixes it as we enforce max one line of separation.

This doesn't fix potential occurrences of function definitions which
are indented (e.g. for a helper class defined in a .cpp), but it's
better than nothing. Also can't be made to run easily on CI/hooks so
we'll have to be careful with new code.

Part of #33027.
2020-05-14 16:54:55 +02:00
..
canvas_item.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
canvas_item.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
canvas_layer.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
canvas_layer.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
http_request.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
http_request.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
instance_placeholder.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
instance_placeholder.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
node.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
node.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
resource_preloader.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
resource_preloader.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
scene_tree.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
scene_tree.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
SCsub SCons: Format buildsystem files with psf/black 2020-03-30 09:05:53 +02:00
shader_globals_override.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
shader_globals_override.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
timer.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
timer.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
viewport.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
viewport.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2020-05-14 16:54:55 +02:00
window.cpp Style: Enforce separation line between function definitions 2020-05-14 16:54:55 +02:00
window.h doc: Sync classref with DisplayServer/Window changes 2020-03-31 11:56:58 +02:00