aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/idle.c2
-rw-r--r--examples/multi-pointer.c1
-rw-r--r--examples/output-layout.c1
-rw-r--r--examples/pointer.c1
-rw-r--r--examples/rotation.c1
-rw-r--r--examples/screenshot.c2
-rw-r--r--examples/simple.c1
-rw-r--r--examples/tablet.c1
-rw-r--r--examples/touch.c1
9 files changed, 11 insertions, 0 deletions
diff --git a/examples/idle.c b/examples/idle.c
index e5e01f63..57c366d1 100644
--- a/examples/idle.c
+++ b/examples/idle.c
@@ -7,6 +7,7 @@
#include <wayland-client.h>
#include <wayland-client-protocol.h>
#include <idle-client-protocol.h>
+#include <wlr/util/log.h>
static struct org_kde_kwin_idle *idle_manager = NULL;
static struct wl_seat *seat = NULL;
@@ -108,6 +109,7 @@ void *main_loop(void *data) {
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
if (parse_args(argc, argv) != 0) {
return -1;
diff --git a/examples/multi-pointer.c b/examples/multi-pointer.c
index 3f8b2415..62aa1bac 100644
--- a/examples/multi-pointer.c
+++ b/examples/multi-pointer.c
@@ -176,6 +176,7 @@ static void handle_input_remove(struct compositor_state *state,
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {
.default_color = { 0.25f, 0.25f, 0.25f, 1 },
.clear_color = { 0.25f, 0.25f, 0.25f, 1 },
diff --git a/examples/output-layout.c b/examples/output-layout.c
index d9325838..35ed22a8 100644
--- a/examples/output-layout.c
+++ b/examples/output-layout.c
@@ -181,6 +181,7 @@ static void handle_keyboard_key(struct keyboard_state *kbstate,
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {0};
state.x_vel = 500;
diff --git a/examples/pointer.c b/examples/pointer.c
index 280372e0..9894e311 100644
--- a/examples/pointer.c
+++ b/examples/pointer.c
@@ -257,6 +257,7 @@ static void handle_tablet_tool_axis(struct wl_listener *listener, void *data) {
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {
.default_color = { 0.25f, 0.25f, 0.25f, 1 },
.clear_color = { 0.25f, 0.25f, 0.25f, 1 },
diff --git a/examples/rotation.c b/examples/rotation.c
index f9307ed3..1d974025 100644
--- a/examples/rotation.c
+++ b/examples/rotation.c
@@ -123,6 +123,7 @@ static void handle_keyboard_key(struct keyboard_state *kbstate,
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {0};
state.config = parse_args(argc, argv);
diff --git a/examples/screenshot.c b/examples/screenshot.c
index 77652805..441d8684 100644
--- a/examples/screenshot.c
+++ b/examples/screenshot.c
@@ -36,6 +36,7 @@
#include <sys/param.h>
#include <screenshooter-client-protocol.h>
#include "util/os-compatibility.h"
+#include <wlr/util/log.h>
static struct wl_shm *shm = NULL;
static struct orbital_screenshooter *screenshooter = NULL;
@@ -242,6 +243,7 @@ static int set_buffer_size(int *width, int *height) {
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct wl_display * display = wl_display_connect(NULL);
if (display == NULL) {
fprintf(stderr, "failed to create display: %m\n");
diff --git a/examples/simple.c b/examples/simple.c
index ad1b0792..95c056c8 100644
--- a/examples/simple.c
+++ b/examples/simple.c
@@ -44,6 +44,7 @@ void handle_output_frame(struct output_state *output, struct timespec *ts) {
}
int main() {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {
.color = { 1.0, 0.0, 0.0 },
.dec = 0,
diff --git a/examples/tablet.c b/examples/tablet.c
index 4eaa204a..f3cd5339 100644
--- a/examples/tablet.c
+++ b/examples/tablet.c
@@ -139,6 +139,7 @@ static void handle_pad_button(struct tablet_pad_state *pstate,
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state = {
.tool_color = { 1, 1, 1, 1 },
.pad_color = { 0.75, 0.75, 0.75, 1.0 }
diff --git a/examples/touch.c b/examples/touch.c
index f18b5d26..4c1f97b6 100644
--- a/examples/touch.c
+++ b/examples/touch.c
@@ -94,6 +94,7 @@ static void handle_touch_motion(struct touch_state *tstate, int32_t touch_id,
}
int main(int argc, char *argv[]) {
+ wlr_log_init(L_DEBUG, NULL);
struct sample_state state;
wl_list_init(&state.touch_points);