hyprwm/Hyprland
Hyprland is an independent, highly customizable, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
The score is jscpd's own --health model: markup, data and text left out, tests kept. The numbers below are the trending scan's.
Most complex files
- src/render/Renderer.cpp1017 cx
- src/output/Monitor.cpp687 cx
- src/managers/input/InputManager.cpp674 cx
- src/layout/algorithm/tiled/scrolling/ScrollingAlgorithm.cpp564 cx
- src/desktop/view/window/Window.cpp556 cx
- src/config/shared/actions/ConfigActions.cpp539 cx
- hyprtester/plugin/src/main.cpp505 cx
- src/render/OpenGL.cpp502 cx
- src/ipc/s1/Commands.cpp494 cx
- src/layout/algorithm/tiled/master/MasterAlgorithm.cpp429 cx
Dead code 0% unused · 0 findings
No dead code found — everything here is reachable.
The code number leaves out tests, fixtures, docs, examples, data files, styles, translations and vendored code, and 2 generated files: src/config/lua/DefaultConfig.hpp, src/render/shaders/glsl/defines.h.
Largest clones in the code
- 90 lines in 4 placescpp665 tokenshyprtester/clients/keyboard-modifiers.cpp:106–195hyprtester/clients/pointer-scroll.cpp:118–207hyprtester/clients/pointer-warp.cpp:110–199hyprtester/clients/shortcut-inhibitor.cpp:113–202
106const char* name = "/wl-shm-kb-mods"; 107state.shmFd = shm_open(name, O_RDWR | O_CREAT | O_EXCL, 0600); 108if (state.shmFd < 0) 109 return false; 110 111if (shm_unlink(name) < 0 || ftruncate(state.shmFd, size) < 0) { 112 close(state.shmFd); 113 return false; 114} 115First 10 of 90 lines.
- 48 lines in 2 placescpp513 tokens
59static void debugLog(std::format_string<Args...> fmt, Args&&... args) { 60 std::string text = std::format(fmt, std::forward<Args>(args)...); 61 logfile << text << std::endl; 62 if (!debug) 63 return; 64 std::println("{}", text); 65 std::fflush(stdout); 66} 67 68static bool bindRegistry(SWlState& state) {First 10 of 48 lines.
- 63 lines in 2 placescpp475 tokens
133 state.shmPool->sendResize(size * 2); 134 state.shmBufSize = size; 135} 136 137auto buf = makeShared<CCWlBuffer>(state.shmPool->sendCreateBuffer(0, geom.x, geom.y, stride, WL_SHM_FORMAT_XRGB8888)); 138if (!buf->resource()) 139 return false; 140 141if (state.shmBuf) { 142 state.shmBuf->sendDestroy();First 10 of 63 lines.
7 more
- 46 lines in 2 placescpp454 tokens
- 34 lines in 2 placescpp443 tokens
- 37 lines in 2 placescpp398 tokens
- 24 lines in 3 placescpp197 tokens
- 8 lines in 8 placescpp54 tokens
- 10 lines in 4 placescpp123 tokens
- 58 lines in 2 placescpp366 tokens
Largest clones over all files, tests and data included
- 65 lines in 13 placesyamldata files404 tokens.github/DISCUSSION_TEMPLATE/bugs-cmake-meson-nix.yml:1–65.github/DISCUSSION_TEMPLATE/bugs-config.yml:1–65.github/DISCUSSION_TEMPLATE/bugs-crashes.yml:1–65.github/DISCUSSION_TEMPLATE/bugs-drm.yml:1–65.github/DISCUSSION_TEMPLATE/bugs-input.yml:1–65and 8 more
1body: 2 - type: markdown 3 attributes: 4 value: | 5 > [!IMPORTANT] 6 > Please do **not** use AI to report bugs. Fill this report with your own words. We don't care about your poor grammar. 7 > It's much more clear to us if you don't use AI and instead write a clear, concise report yourself. 8 - type: input 9 attributes: 10 label: Hyprland versionFirst 10 of 65 lines.
- 90 lines in 4 placescpp665 tokenshyprtester/clients/keyboard-modifiers.cpp:106–195hyprtester/clients/pointer-scroll.cpp:118–207hyprtester/clients/pointer-warp.cpp:110–199hyprtester/clients/shortcut-inhibitor.cpp:113–202
106const char* name = "/wl-shm-kb-mods"; 107state.shmFd = shm_open(name, O_RDWR | O_CREAT | O_EXCL, 0600); 108if (state.shmFd < 0) 109 return false; 110 111if (shm_unlink(name) < 0 || ftruncate(state.shmFd, size) < 0) { 112 close(state.shmFd); 113 return false; 114} 115First 10 of 90 lines.
- 48 lines in 7 placesyamldata files296 tokens.github/DISCUSSION_TEMPLATE/feature-requests-config.yml:1–48.github/DISCUSSION_TEMPLATE/feature-requests-layouts.yml:1–48.github/DISCUSSION_TEMPLATE/feature-requests-other.yml:1–48.github/DISCUSSION_TEMPLATE/feature-requests-protocols-integrations.yml:1–48.github/DISCUSSION_TEMPLATE/feature-requests-renderer.yml:1–48and 2 more
1body: 2 - type: markdown 3 attributes: 4 value: | 5 > [!IMPORTANT] 6 > Please do **not** use AI to make feature requests. Fill this request with your own words. We don't care about your poor grammar. 7 > It's much more clear to us if you don't use AI and instead write a clear, concise request yourself. 8 - type: textarea 9 attributes: 10 label: What's the problem?First 10 of 48 lines.
- 166 lines in 3 placescpptests791 tokens
- 146 lines in 2 placescpptests1,131 tokens
By format, code only
| Format | Files | Lines | Clones | Duplicated lines | Duplication |
|---|---|---|---|---|---|
| cpp | 472 | 119,065 | 432 | 5,352 | 4.5% |
| cpp-header | 489 | 30,471 | 71 | 754 | 2.47% |
| bash | 7 | 482 | 1 | 22 | 4.56% |
| python | 1 | 942 | 0 | 0 | 0% |
| lua | 1 | 342 | 0 | 0 | 0% |
| c-header | 1 | 63 | 0 | 0 | 0% |
By format, all files
| Format | Files | Lines | Clones | Duplicated lines | Duplication |
|---|---|---|---|---|---|
| cpp | 611 | 162,164 | 816 | 11,364 | 7.01% |
| cpp-header | 495 | 30,766 | 73 | 769 | 2.5% |
| markup | 16 | 3,977 | 30 | 443 | 11.14% |
| yaml | 35 | 2,019 | 20 | 1,088 | 53.89% |
| glsl | 50 | 3,899 | 15 | 182 | 4.67% |
| lua | 6 | 933 | 6 | 59 | 6.32% |
| cmake | 5 | 1,016 | 1 | 9 | 0.89% |
| bash | 7 | 482 | 1 | 22 | 4.56% |
| rest | 2 | 202 | 1 | 15 | 7.43% |
| makefile | 2 | 155 | 1 | 6 | 3.87% |
Trending appearances
| Day | Rank | Stars | Files | Lines | Clones | All files | Code | Health | Commit |
|---|---|---|---|---|---|---|---|---|---|
| Nov 2, 2026 | #9 | 39,482 (+38) | 1,253 | 208,434 | 964 | 6.7% | 4.05% | D 53.5 | d55a55d |
Want this for your own project? Install jscpd and run jscpd ., or measure it the way the baselines were measured.