summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--config.def.h3
-rw-r--r--dwl.c2
2 files changed, 5 insertions, 0 deletions
diff --git a/config.def.h b/config.def.h
index 4e30885..db0babc 100644
--- a/config.def.h
+++ b/config.def.h
@@ -154,6 +154,9 @@ static const Key keys[] = {
/* Ctrl-Alt-Backspace and Ctrl-Alt-Fx used to be handled by X server */
{ WLR_MODIFIER_CTRL|WLR_MODIFIER_ALT,XKB_KEY_Terminate_Server, quit, {0} },
+ /* Ctrl-Alt-Fx is used to switch to another VT, if you don't know what a VT is
+ * do not remove them.
+ */
#define CHVT(n) { WLR_MODIFIER_CTRL|WLR_MODIFIER_ALT,XKB_KEY_XF86Switch_VT_##n, chvt, {.ui = (n)} }
CHVT(1), CHVT(2), CHVT(3), CHVT(4), CHVT(5), CHVT(6),
CHVT(7), CHVT(8), CHVT(9), CHVT(10), CHVT(11), CHVT(12),
diff --git a/dwl.c b/dwl.c
index 762f147..ef27a1d 100644
--- a/dwl.c
+++ b/dwl.c
@@ -775,6 +775,8 @@ createkeyboard(struct wlr_keyboard *keyboard)
context = xkb_context_new(XKB_CONTEXT_NO_FLAGS);
keymap = xkb_keymap_new_from_names(context, &xkb_rules,
XKB_KEYMAP_COMPILE_NO_FLAGS);
+ if (!keymap)
+ die("createkeyboard: failed to compile keymap");
wlr_keyboard_set_keymap(keyboard, keymap);
xkb_keymap_unref(keymap);