Functions
Wayland Library Input Functions

Functions that deal with creating, destroying, or interacting with Wayland Input. More...

Functions

EAPI struct wl_seat * ecore_wl2_input_seat_get (Ecore_Wl2_Input *input)
 Get the wl_seat that an input is using. More...
 
EAPI Ecore_Wl2_Seat_Capabilities ecore_wl2_input_seat_capabilities_get (Ecore_Wl2_Input *input)
 Get the seat capabilities for a given input. More...
 
EAPI unsigned int ecore_wl2_input_seat_id_get (Ecore_Wl2_Input *input)
 Get the wayland's seat id from an input. More...
 
EAPI Ecore_Wl2_Display * ecore_wl2_input_display_get (const Ecore_Wl2_Input *input)
 Get the display object of an input. More...
 
EAPI struct xkb_keymap * ecore_wl2_input_keymap_get (const Ecore_Wl2_Input *input)
 Get the xkb_keymap object of an input. More...
 
EAPI Eina_Stringshareecore_wl2_input_name_get (Ecore_Wl2_Input *input)
 Get the name of an input. More...
 
EAPI Eina_Bool ecore_wl2_input_keyboard_repeat_get (const Ecore_Wl2_Input *input, double *rate, double *delay)
 Get the keyboard repeat rate and delay of an input. More...
 
EAPI Eina_Bool ecore_wl2_input_keyboard_repeat_set (Ecore_Wl2_Input *input, double rate, double delay)
 Set the keyboard repeat rate and delay of an input. More...
 
EAPI Eina_Bool ecore_wl2_input_pointer_xy_get (const Ecore_Wl2_Input *input, int *x, int *y)
 Retrieves the mouse position of the seat. More...
 
EAPI void ecore_wl2_input_pointer_set (Ecore_Wl2_Input *input, struct wl_surface *surface, int hot_x, int hot_y)
 Set a given wl_surface to use as the pointer on a seat. More...
 
EAPI void ecore_wl2_input_cursor_from_name_set (Ecore_Wl2_Input *input, const char *cursor)
 Set a specific cursor on a given seat. More...
 
EAPI Ecore_Wl2_Input * ecore_wl2_input_default_input_get (const Ecore_Wl2_Display *ewd)
 Gets default input of a given display. More...
 

Detailed Description

Functions that deal with creating, destroying, or interacting with Wayland Input.

Function Documentation

◆ ecore_wl2_input_seat_get()

EAPI struct wl_seat* ecore_wl2_input_seat_get ( Ecore_Wl2_Input *  input)

Get the wl_seat that an input is using.

Parameters
inputThe Ecore_Wl2_Input to get the seat of
Returns
The wl_seat of this input, or NULL otherwise
Since
1.17

References EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_seat_capabilities_get()

EAPI Ecore_Wl2_Seat_Capabilities ecore_wl2_input_seat_capabilities_get ( Ecore_Wl2_Input *  input)

Get the seat capabilities for a given input.

Parameters
inputThe input
Since
1.19

◆ ecore_wl2_input_seat_id_get()

EAPI unsigned int ecore_wl2_input_seat_id_get ( Ecore_Wl2_Input *  input)

Get the wayland's seat id from an input.

Parameters
inputThe input
Returns
The seat id
Since
1.19

References EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_display_get()

EAPI Ecore_Wl2_Display* ecore_wl2_input_display_get ( const Ecore_Wl2_Input *  input)

Get the display object of an input.

Parameters
inputThe input
Returns
The display
Since
1.20

References EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_keymap_get()

EAPI struct xkb_keymap* ecore_wl2_input_keymap_get ( const Ecore_Wl2_Input *  input)

Get the xkb_keymap object of an input.

Parameters
inputThe input
Returns
The xkb_keymap object
Since
1.20

References EINA_SAFETY_ON_FALSE_RETURN_VAL, and EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_name_get()

EAPI Eina_Stringshare* ecore_wl2_input_name_get ( Ecore_Wl2_Input *  input)

Get the name of an input.

Parameters
inputThe input
Returns
The name
Since
1.20

References EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_keyboard_repeat_get()

EAPI Eina_Bool ecore_wl2_input_keyboard_repeat_get ( const Ecore_Wl2_Input *  input,
double *  rate,
double *  delay 
)

Get the keyboard repeat rate and delay of an input.

Parameters
inputThe input
ratePointer to store the repeat rate (in seconds)
ratePointer to store the repeat delay (in seconds)
Returns
True if repeat is enabled
Since
1.20

References EINA_FALSE, EINA_SAFETY_ON_FALSE_RETURN_VAL, and EINA_SAFETY_ON_NULL_RETURN_VAL.

◆ ecore_wl2_input_keyboard_repeat_set()

EAPI Eina_Bool ecore_wl2_input_keyboard_repeat_set ( Ecore_Wl2_Input *  input,
double  rate,
double  delay 
)

Set the keyboard repeat rate and delay of an input.

Parameters
inputThe input
ratePointer to store the repeat rate (in seconds)
ratePointer to store the repeat delay (in seconds)
Returns
True if repeat is enabled
Since
1.24

References EINA_FALSE, EINA_SAFETY_ON_FALSE_RETURN_VAL, EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_TRUE.

◆ ecore_wl2_input_pointer_xy_get()

EAPI Eina_Bool ecore_wl2_input_pointer_xy_get ( const Ecore_Wl2_Input *  input,
int *  x,
int *  y 
)

Retrieves the mouse position of the seat.

Parameters
inputThe seat
xwhere to return the horizontal position. May be NULL. Returns 0 on error.
ywhere to return the vertical position. May be NULL. Returns 0 on error.
Returns
EINA_TRUE if coords were successfully retrieved
Since
1.20

References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_TRUE.

◆ ecore_wl2_input_pointer_set()

EAPI void ecore_wl2_input_pointer_set ( Ecore_Wl2_Input *  input,
struct wl_surface *  surface,
int  hot_x,
int  hot_y 
)

Set a given wl_surface to use as the pointer on a seat.

Parameters
inputThe seat to set this surface as the pointer on
surfaceThe surface to use as the pointer
hot_xThe x coordinate to use as the cursor hot spot
hot_yThe y coordinate to use as the cursor hot spot
Since
1.20

References EINA_SAFETY_ON_NULL_RETURN.

◆ ecore_wl2_input_cursor_from_name_set()

EAPI void ecore_wl2_input_cursor_from_name_set ( Ecore_Wl2_Input *  input,
const char *  cursor 
)

Set a specific cursor on a given seat.

This function will try to find a matching cursor inside the existing cursor theme and set the pointer for the specified seat to be the specified cursor

Parameters
inputThe seat to set the cursor on
cursorThe name of the cursor to try and set
Since
1.20

References EINA_SAFETY_ON_NULL_RETURN.

Referenced by ecore_wl2_dnd_drag_start().

◆ ecore_wl2_input_default_input_get()

EAPI Ecore_Wl2_Input* ecore_wl2_input_default_input_get ( const Ecore_Wl2_Display *  ewd)

Gets default input of a given display.

Parameters
ewdThe display
Since
1.24

References ecore_wl2_display_input_find_by_name(), and EINA_SAFETY_ON_NULL_RETURN_VAL.