Commit graph

9 commits

Author SHA1 Message Date
John Lindgren
d54051d9c1 clang-format: tweak to match existing code a little better
"clang-format -i src/view.c" before:
  1 file changed, 204 insertions(+), 169 deletions(-)

"clang-format -i src/view.c" after:
  1 file changed, 181 insertions(+), 146 deletions(-)
2025-09-13 12:06:52 +01:00
John Lindgren
1e514c7550 add .clang-format (with a disclaimer)
.clang-format gets picked up nowadays by some IDEs (tested Qt Creator)
for auto-formatting aids. With the large caveat that it's not 100%
accurate to labwc's preferred coding style, I've found that this config
gets it right 90% of the time, which is enough to be helpful.

I added a prominent disclaimer comment to the top of the file to warn
people away from relying completely on clang-format. This isn't meant
to replace manual attention to formatting details (or to replace
./scripts/check) but I think it doesn't hurt.
2024-04-18 21:52:38 +01:00
Johan Malm
41274db128 Delete .clang-format
The file is not accurate and clang-format cannot describe our coding
style
2021-12-26 23:10:39 +00:00
alexander bryan
1ac654f006 Apply coding std to <mouse> code & add .clang-format
The files:
    include/config/mousebind.h
    src/config/mousebind.c
    src/config/rc.xml
were formatted automatically via clang-format using the rules specified
in the .clang-format file. Specifically, the command;
clang-format -i -style=file include/config/mousebind.h \
src/config/mousebind.c src/config/rc.xml

This is unfortunately adding a break before the brace in enum
declarations
2021-09-01 07:05:37 +01:00
Johan Malm
00adc7ed34 Remove .clang-format
Can't get it to work on wlroots style
2020-09-29 20:50:27 +01:00
Johan Malm
53b360dd11 Tiny .clang-format tweak 2020-09-28 21:35:18 +01:00
Johan Malm
96e05057a3 Update .clang-format
Align with wlroots style
2020-09-28 20:41:41 +01:00
Johan Malm
e716a92c00 Support xwayland view resize (LAB_DECO_PART_LEFT) 2020-05-25 13:42:40 +01:00
Johan Malm
7732869870 Add .clang-format and apply 2019-12-27 21:22:45 +00:00