Apply clang-format across the whole tree

Run clang-format (the repo's .clang-format: LLVM base, 120 cols, tabs,
Allman functions) over every source file so the tree is formatter-clean.
Whitespace only -- no behavior change; full x64 + x86 suites pass.

Also set SortIncludes: false in .clang-format. Windows include order is
load-bearing (windows.h must precede tlhelp32.h / mmreg.h / xinput.h /
dinput.h; winsock2.h must precede windows.h), and the default
alphabetical sort reorders tlhelp32.h ahead of windows.h -- a build
break. Leaving order alone keeps the manual, correct grouping.
This commit is contained in:
2026-07-12 11:52:53 +02:00
parent c684a15fb9
commit 30eccf749d
155 changed files with 3333 additions and 6171 deletions

View File

@@ -9,8 +9,7 @@
#include <windows.h> // USER_DEFAULT_SCREEN_DPI (== 96, the 100%-scale baseline)
namespace coop
{
namespace coop {
// ImGui's built-in default font (ProggyClean) rasterizes at this pixel size at 100% scale. Named once
// here so the DPI math scales from a single owned constant instead of a bare 13 sprinkled around.
@@ -26,8 +25,7 @@ inline constexpr float kMaxUiScale = 8.0f;
// callers never derive a zero-size font.
inline float dpi_scale_from(unsigned dpi)
{
if (dpi == 0)
{
if (dpi == 0) {
dpi = USER_DEFAULT_SCREEN_DPI;
}
const float scale = static_cast<float>(dpi) / static_cast<float>(USER_DEFAULT_SCREEN_DPI);