labwc/include/input/tablet.h

36 lines
786 B
C
Raw Normal View History

/* SPDX-License-Identifier: GPL-2.0-only */
2023-12-29 10:10:41 +01:00
#ifndef LABWC_TABLET_H
#define LABWC_TABLET_H
#include <wayland-server-core.h>
2024-04-20 11:40:23 +02:00
#include <wlr/types/wlr_tablet_v2.h>
2024-01-07 22:15:25 +01:00
struct seat;
struct wlr_device;
struct wlr_input_device;
struct drawing_tablet {
2024-04-20 11:40:23 +02:00
struct wlr_input_device *wlr_input_device;
struct seat *seat;
struct wlr_tablet *tablet;
2024-04-20 11:40:23 +02:00
struct wlr_tablet_v2_tablet *tablet_v2;
double x, y;
double distance;
double pressure;
double tilt_x, tilt_y;
double rotation;
double slider;
double wheel_delta;
struct {
struct wl_listener proximity;
struct wl_listener axis;
struct wl_listener tip;
struct wl_listener button;
struct wl_listener destroy;
} handlers;
};
void tablet_init(struct seat *seat, struct wlr_input_device *wlr_input_device);
2023-12-29 10:10:41 +01:00
#endif /* LABWC_TABLET_H */