.editorconfig 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. # For format see editorconfig.org
  2. # Copyright 2022 Collabora Ltd.
  3. # SPDX-License-Identifier: Zlib
  4. root = true
  5. [*.{c,cg,cpp,gradle,h,java,m,metal,pl,py,S,sh,txt}]
  6. indent_size = 4
  7. indent_style = space
  8. [*.{html,js,json,m4,yml,yaml,vcxproj,vcxproj.filters}]
  9. indent_size = 2
  10. indent_style = space
  11. [*.xml]
  12. indent_size = 4
  13. indent_style = space
  14. [{CMakeLists.txt,cmake/*.cmake}]
  15. indent_size = 2
  16. indent_style = space
  17. insert_final_newline = true
  18. trim_trailing_whitespace = true
  19. [{cmake/cmake_uninstall.cmake.in,test/CMakeLists.txt,cmake/SDL3Config.cmake.in}]
  20. indent_size = 4
  21. indent_style = space
  22. insert_final_newline = true
  23. trim_trailing_whitespace = true
  24. [{Makefile.*,*.mk,*.sln,*.pbxproj,*.plist}]
  25. indent_size = 8
  26. indent_style = tab
  27. tab_width = 8
  28. [src/joystick/controller_type.*]
  29. indent_style = tab
  30. [src/joystick/hidapi/steam/*.h]
  31. indent_style = tab
  32. [src/libm/*.c]
  33. indent_style = tab
  34. [src/test/SDL_test_{crc32,md5,random}.c]
  35. indent_size = 2
  36. indent_style = space
  37. [src/video/yuv2rgb/*.{c,h}]
  38. indent_style = tab
  39. [wayland-protocols/*.xml]
  40. indent_size = 2
  41. indent_style = space
  42. [*.{markdown,md}]
  43. indent_size = 4
  44. indent_style = space
  45. # Markdown syntax treats tabs as 4 spaces
  46. tab_width = 4
  47. [{*.bat,*.rc}]
  48. end_of_line = crlf