No description
- C 66.2%
- CMake 30.9%
- Shell 2.9%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| protocol | ||
| .gitignore | ||
| CMakeLists.txt | ||
| crosshair.png | ||
| main.c | ||
| README.md | ||
| shm.c | ||
| shm.h | ||
| toggle-crosshair | ||
Wayland-Crosshair
A simple crosshair overlay for wayland using wlroots zwlr_layer_shell_v1. This code is an adaptation of wlroots examples/layer-shell.c and hello-wayland.
Requirements
Build: cmake pkgconf imagemagick wayland wayland-protocols wlroots
Run: wayland wlroots
Building
mkdir cmake-build
cd cmake-build
cmake ..
make
Installation
Copy wayland_crosshair and toggle-crosshair into the PATH, e.g. ~/bin.
On KDE, go to System Settings -> Shortcuts -> Add Command, enter toggle-crosshair and add a custom shortcut.
Note
I only tested this on KDE Plasma 5. For me, the crosshair is always in the center of the currently active screen. I don't know how it behaves on different window managers or scaling options.