Clamps the pending wp_viewport source rect back inside the attached buffer when it misses by <= 1 px, so if clients request something that falls within the 256-increment wl_fixed_from_double precision error it’s still treated as valid.
* config: fix gesture dispatcher parsing with whitespaces
Some dispatcher functions (e.g., `moveFocusTo`) expect the given string to be
stripped of whitepsaces.
This fixes `gesture` line parsing: rather than calling dispatcher functions
with the original string, we reuse words parsed by `CConstVarList` and join
them with a comma.
* tests/gestures: Add a test for `movecursortocorner`
use unique pointers and rvalue references where applicable, buffer is
still a shared pointer because CHLBufferReference uses it to hold it
locked.
in CSHMPool destructor add a check for m_data != MAP_FAILED same in
resize, because mmap returns (void *) -1 on failure and that is not
comparable to nullptr. delete default constructor so we dont end up in
weird states with m_data.
running Hyprland --systeminfo from a console/tty calls systemInfoRequest
without us having a g_pCompositor or g_pHyprOpengl, so just if check them
and make --systeminfo not segfault and atleast print what info we can.
* exec: Spawn processes as direct children
Spawn processes as children rather than grandchildren.
This way, spawned processes may track Hyprland's state
by watching their parent, either directly or indirectly
(e.g., Linux's `PR_SET_PDEATH_SIG`).
Fixes#11728
* tests/exec: Add the test on process spawning
Add a test that ensures that:
- A spawned process remains a direct child of Hyprland;
- Upon termination, the process does not become a zombie.
* config: Fix multi-argument gesture dispatchers parsing
The `dispatcher` gesture handler used to only handle
the first argument to the dispatcher, while some dispatchers
(e.g., `sendshortcut`) want multiple arguments.
This fixes `ConfigManager` to handle all the arguments
provided to the dispatcher gesture handler.
Fixes#11684.
* test/gestures: Add a test for a gesture with a multi-argument dispatcher
* test/gestures: Factor out `waitForWindowCount`
Reduce code duplication in the gestures test.
Some tablet rotation modes (90°, 270°, and flipped variants) swap the X and Y axes.
This change adjusts the effective physical size based on axis orientation
to ensure tablet active area coordinates are normalized correctly.