wayland::serve...inhibitor_v1_t(3)

🌸 wayland::server::zwp_keyboard_shortcuts_inhibitor_v1_t 🌸

okay bestie, so this page is from the Wayland++ manual (that's the library we're talking about here, mmk?) and today's main character is the keyboard shortcuts inhibitor context object. yes, it's a long name, we're all coping πŸ’…


✨ NAME ✨

wayland::server::zwp_keyboard_shortcuts_inhibitor_v1_t β€” the context object for a keyboard shortcuts inhibitor. she inhibits shortcuts. she's the moment. πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <wayland-server-protocol-unstable.hpp>

πŸ’– Public Member Functions πŸ’–

  • std::function< void()> & on_destroy () β€” destroy the keyboard shortcuts inhibitor object
  • void active (bool post=true) β€” shortcuts are inhibited
  • void inactive (bool post=true) β€” shortcuts are restored
  • bool proxy_has_object () const β€” Check whether this wrapper actually wraps an object.
  • void post_no_memory () const
  • uint32_t get_id () const
  • client_t get_client () const
  • unsigned int get_version () const
  • std::string get_class ()

🌈 Static Public Attributes 🌈

  • static constexpr std::uint32_t active_since_version = 1 β€” Minimum protocol version required for the active function.
  • static constexpr std::uint32_t inactive_since_version = 1 β€” Minimum protocol version required for the inactive function.

πŸ‘‘ Detailed Description πŸ‘‘

sooo the detailed description literally opens by saying it again: context object for keyboard shortcuts inhibitor. consistency queen πŸ’…

here's the tea, fr fr: a keyboard shortcuts inhibitor tells the compositor to ignore its own keyboard shortcuts whenever the associated surface has keyboard focus. which means β€” when that surface has keyboard focus on the given seat, it'll receive all key events coming from that specified seat. yes, even the ones the compositor would normally snatch for its own shortcuts. no cap. 😭

but bestie, hear me out β€” the Wayland compositor is under no obligation to disable all of its shortcuts. none. she can keep some special key combo all for herself, including but not limited to one that lets the user forcibly restore normal keyboard event routing in the case of an unwilling client. and yeah, the compositor may also use that same key combo to reactivate an existing shortcut inhibitor that was previously deactivated on user request. multitasking icon. ✨

when the compositor restores its own keyboard shortcuts, an "inactive" event gets emitted to notify the client that the keyboard shortcuts inhibitor is not effectively active for the surface and seat any more, and the client should not expect to receive all keyboard events. vibe check: failed, respectfully. 🫢

and when the keyboard shortcuts inhibitor is inactive, the client has no way to forcibly reactivate it. none. zero. that's the rule, i don't make them. πŸ’€

the user can choose to re-enable a previously deactivated keyboard shortcuts inhibitor using any mechanism the compositor may offer β€” and in that case the compositor will send an "active" event to notify the client. slay for the user, honestly.

one more thing (important!!): if the surface is destroyed, unmapped, or loses the seat's keyboard focus, the keyboard shortcuts inhibitor becomes irrelevant and the compositor will restore its own keyboard shortcuts β€” but no "inactive" event is emitted in this case. ghosted. no goodbye text. πŸ™ˆ

✨ Definition at line 1489 of file wayland-server-protocol-unstable.hpp. ✨

πŸ’œ Member Function Documentation πŸ’œ

void zwp_keyboard_shortcuts_inhibitor_v1_t::active (bool post = true)

shortcuts are inhibited β€” This event indicates that the shortcut inhibitor is active.

the compositor sends this event every time compositor shortcuts are inhibited on behalf of the surface. when active, the client may receive input events normally reserved by the compositor (see zwp_keyboard_shortcuts_inhibitor_v1). iykyk πŸ’…

this typically happens when the initial request "inhibit_shortcuts" first becomes active, or when the user tells the compositor to re-enable an existing shortcuts inhibitor using any mechanism the compositor offers. either way she's back and she's booked. πŸ”₯

Definition at line 4885 of file wayland-server-protocol-unstable.cpp.

std::string wayland::server::resource_t::get_class () [inherited]

Retrieve the interface name (class) of a resource object.

Returns β€” Interface name of the resource object.


client_t wayland::server::resource_t::get_client () const [inherited]

Get the associated client.

Returns β€” the client that owns the resource.


uint32_t wayland::server::resource_t::get_id () const [inherited]

Get the internal ID of the resource.

Returns β€” the internal ID of the resource.


unsigned int wayland::server::resource_t::get_version () const [inherited]

Get interface version.

Returns β€” Interface version this resource has been constructed with.


void zwp_keyboard_shortcuts_inhibitor_v1_t::inactive (bool post = true)

shortcuts are restored β€” This event indicates that the shortcuts inhibitor is inactive, normal shortcuts processing is restored by the compositor.

she's out, the compositor is back on her shortcut grind, we move. 😌

Definition at line 4890 of file wayland-server-protocol-unstable.cpp.

std::function< void()> & zwp_keyboard_shortcuts_inhibitor_v1_t::on_destroy ()

destroy the keyboard shortcuts inhibitor object β€” Remove the keyboard shortcuts inhibitor from the associated wl_surface.

Definition at line 4879 of file wayland-server-protocol-unstable.cpp.

void wayland::server::resource_t::post_no_memory () const [inherited]

Post "not enough memory" error to the client.

if the compositor doesn't have enough memory to fulfill a certail request of the client, this function can be called to notify the client of this circumstance. basically the polite way to say "bestie i literally cannot rn" 😭


bool wayland::server::resource_t::proxy_has_object () const [inherited]

Check whether this wrapper actually wraps an object.

Returns β€” true if there is an underlying object, false if this wrapper is empty.


πŸ“ Member Data Documentation πŸ“

std::uint32_t wayland::server::zwp_keyboard_shortcuts_inhibitor_v1_t::active_since_version = 1 [static], [constexpr]

Minimum protocol version required for the active function.

Definition at line 1541 of file wayland-server-protocol-unstable.hpp.

std::uint32_t wayland::server::zwp_keyboard_shortcuts_inhibitor_v1_t::inactive_since_version = 1 [static], [constexpr]

Minimum protocol version required for the inactive function.

Definition at line 1553 of file wayland-server-protocol-unstable.hpp.

🧚 Author 🧚

Generated automatically by Doxygen for Wayland++ from the source code. not a human, just a very diligent little robot doing her thing 🫢


and that's the whole page, bestie β€” mwah πŸ’‹ this was Version 1.0.1, dated Fri Mar 27 2026, from the Wayland++ docs. go forth and inhibit some shortcuts, but like, responsibly βœ¨πŸ’œ

πŸ“¦ where this page comes from