wayland::zwp_r...e_pointer_v1_t(3)
πΈ NAME πΈ
Okay bestie, welcome to wayland::zwp_r...e_pointer_v1_t(3) from Wayland++ β this page is all about the relative pointer object, and itβs lowkey iconic.
wayland::zwp_relative_pointer_v1_tβ relative pointer object
β¨ SYNOPSIS β¨
#include <wayland-client-protocol-unstable.hpp>
It inherits wayland::proxy_t, because of course it does π
.
π Public Types
enum class wrapper_type { standard, display, foreign, proxy_wrapper }
π Public Member Functions
std::function< void(uint32_t, uint32_t, double, double, double, double)> & on_relative_motion ()β relative pointer motionuint32_t get_id () constβ get the id of a proxy objectstd::string get_class () constβ get the interface name (class) of a proxy objectuint32_t get_version () constβ get the protocol object version of a proxy objectwrapper_type get_wrapper_type () constβ get the type of a proxy objectvoid set_queue (event_queue_t queue)β assign a proxy to an event queuewl_proxy * c_ptr () constβ get a pointer to the underlying C structbool proxy_has_object () constβ check whether this wrapper actually wraps an objectoperator bool () constβ check whether this wrapper actually wraps an objectbool operator== (const proxy_t &right) constβ check whether two wrappers refer to the same objectbool operator!= (const proxy_t &right) constβ check whether two wrappers refer to different objectsvoid proxy_release ()β release the wrapped object (if any), making this an empty wrapper
π Detailed Description π
This is the relative pointer object, and itβs giving very specific main-character energy.
A wp_relative_pointer object is an extension to the wl_pointer interface used for emitting relative pointer events. It shares the same focus as wl_pointer objects of the same seat and will only emit events when it has focus. No cap. π«Ά
Definition at line 3475 of file wayland-client-protocol-unstable.hpp.
π Member Enumeration Documentation π
enum class wayland::proxy_t::wrapper_type [strong], [inherited]
This enum describes the underlying wl_proxy type and properties of a proxy_t that affect construction, destruction, and event handling. Itβs basically the wrapperβs whole personality profile β¨.
Enumerator vibes:
standardβ C pointer is a standard type compatible withwl_proxy*. Events are dispatched and it is destructed when theproxy_tis destructed. User data is set.displayβ C pointer is awl_display*. No events are dispatched,wl_display_disconnectis called when theproxy_tis destructed. User data is set.foreignβ C pointer is a standard type compatible withwl_proxy*, but another library owns it and it should not be touched in a way that could affect the operation of the other library. No events are dispatched,wl_proxy_destroyis not called when theproxy_tis destructed, user data is not touched. Consequently, there is no reference counting for theproxy_t. Lifetime of such wrappers should preferably be short to minimize the chance that the owning library decides to destroy thewl_proxy.proxy_wrapperβ C pointer is awl_proxy*that was constructed withwl_proxy_create_wrapper. No events are dispatched,wl_proxy_wrapper_destroyis called when theproxy_tis destroyed. Reference counting is active. A reference to theproxy_tcreating this proxy wrapper is held to extend its lifetime until after the proxy wrapper is destroyed.
Definition at line 117 of file wayland-client.hpp.
π¦ Member Function Documentation π¦
wl_proxy * wayland::proxy_t::c_ptr () const [inherited]
Get a pointer to the underlying C struct. Very βlet me see the real youβ energy π.
Returns: the underlying wl_proxy wrapped by this proxy_t if it exists, otherwise an exception is thrown.
std::string wayland::proxy_t::get_class () const [inherited]
Get the interface name (class) of a proxy object.
Returns: the interface name of the object associated with the proxy.
uint32_t wayland::proxy_t::get_id () const [inherited]
Get the id of a proxy object.
Returns: the id the object associated with the proxy.
uint32_t wayland::proxy_t::get_version () const [inherited]
Get the protocol object version of a proxy object. Gets the protocol object version of a proxy object, or 0 if the proxy was created with unversioned API.
A returned value of 0 means that no version information is available, so the caller must make safe assumptions about the object's real version.
display_t will always return version 0.
Returns: the protocol object version of the proxy or 0.
wrapper_type wayland::proxy_t::get_wrapper_type () const [inline], [inherited]
Get the type of a proxy object. Itβs the wrapper-type reveal moment β¨.
Definition at line 303 of file wayland-client.hpp.
std::function< void(uint32_t, uint32_t, double, double, double, double)> & zwp_relative_pointer_v1_t::on_relative_motion ()
Relative pointer motion. This is the event callback, and it is literally carrying the motion deltas π.
Parameters:
utime_hiβ high 32 bits of a 64 bit timestamp with microsecond granularityutime_loβ low 32 bits of a 64 bit timestamp with microsecond granularitydxβ the x component of the motion vectordyβ the y component of the motion vectordx_unaccelβ the x component of the unaccelerated motion vectordy_unaccelβ the y component of the unaccelerated motion vector
Relative x/y pointer motion from the pointer of the seat associated with this object.
A relative motion is in the same dimension as regular wl_pointer motion events, except they do not represent an absolute position. For example, moving a pointer from (x, y) to (x', y') would have the equivalent relative motion (x' - x, y' - y). If a pointer motion caused the absolute pointer position to be clipped by for example the edge of the monitor, the relative motion is unaffected by the clipping and will represent the unclipped motion.
This event also contains non-accelerated motion deltas. The non-accelerated delta is, when applicable, the regular pointer motion delta as it was before having applied motion acceleration and other transformations such as normalization.
Note that the non-accelerated delta does not represent 'raw' events as they were read from some device. Pointer motion acceleration is device- and configuration-specific and non-accelerated deltas and accelerated deltas may have the same value on some devices.
Relative motions are not coupled to wl_pointer.motion events, and can be sent in combination with such events, but also independently. There may also be scenarios where wl_pointer.motion is sent, but there is no relative motion. The order of an absolute and relative motion event originating from the same physical motion is not guaranteed.
If the client needs button events or focus state, it can receive them from a wl_pointer object of the same seat that the wp_relative_pointer object is associated with.
Definition at line 6703 of file wayland-client-protocol-unstable.cpp.
wayland::proxy_t::operator bool () const [inherited]
Check whether this wrapper actually wraps an object.
Returns: true if there is an underlying object, false if this wrapper is empty.
bool wayland::proxy_t::operator!= (const proxy_t & right) const [inherited]
Check whether two wrappers refer to different objects. Not the same bestie, periodt.
bool wayland::proxy_t::operator== (const proxy_t & right) const [inherited]
Check whether two wrappers refer to the same object. Same object energy π.
bool wayland::proxy_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.
void wayland::proxy_t::proxy_release () [inherited]
Release the wrapped object (if any), making this an empty wrapper. Note that display_t instances cannot be released this way. Attempts to do so are ignored.
Examples: foreign_display.cpp.
void wayland::proxy_t::set_queue (event_queue_t queue) [inherited]
Assign a proxy to an event queue.
Parameters: queue β the event queue that will handle this proxy.
Assign proxy to event queue. Events coming from proxy will be queued in queue instead of the display's main queue.
See also: display_t::dispatch_queue().
Examples: proxy_wrapper.cpp.
π Author π
Generated automatically by Doxygen for Wayland++ from the source code. Very βthe documentation wrote itselfβ behavior, honestly.
xoxo, your Wayland++ bestie π
β Version 1.0.1, dated Fri Mar 27 2026, and this whole page lives in the wayland::zwp_r...e_pointer_v1_t(3) manual. Bye bestie! π
π¦ where this page comes from
- ubuntu stonking: waylandpp-dev 1.0.1-2 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms