lv_x11.h

Typedefs

typedef void (*lv_x11_close_cb)(void *user_data)

optional window close callback function type

See also

lv_x11_window_set_close_cb

Functions

void lv_x11_inputs_create(lv_display_t *disp, lv_image_dsc_t const *mouse_img)

create and add keyboard, mouse and scrollwheel objects and connect them to x11 display.

This is a convenience method handling the typical input initialisation of an X11 window:

  • create keyboard (lv_x11_keyboard_create)

  • create mouse (with scrollwheel, lv_x11_mouse_create lv_x11_mousewheel_create)

Parameters:
  • disp -- [in] the created X11 display object from lv_x11_window_create

  • mouse_img -- [in] optional image description for the mouse cursor (NULL for no/invisible mouse cursor)

lv_display_t *lv_x11_window_create(char const *title, int32_t hor_res, int32_t ver_res)

create the X11 display

The minimal initialisation for initializing the X11 display driver with keyboard/mouse support:

lv_display_t* disp = lv_x11_window_create("My Window Title", window_width, window_width);
lv_x11_inputs_create(disp, NULL);
or with mouse cursor icon:
lv_image_dsc_t mouse_symbol = {.....};
lv_display_t* disp = lv_x11_window_create("My Window Title", window_width, window_width);
lv_x11_inputs_create(disp, &mouse_symbol);

Parameters:
  • title -- [in] title of the created X11 window

  • hor_res -- [in] horizontal resolution (=width) of the X11 window

  • ver_res -- [in] vertical resolution (=height) of the X11 window

Returns:

pointer to the display object

struct _x11_user_hdr_t
#include <lv_x11.h>

Header of private display driver user data - for internal use only

Public Members

struct _XDisplay *display

X11 display object

struct _x11_inp_data *inp_data

input user data object