From 4e7a12053d64b5e6471d93072312cf7044657afc Mon Sep 17 00:00:00 2001 From: Sascha Kruse Date: Mon, 14 Nov 2011 23:59:32 +0100 Subject: [PATCH] added keybindings to config.def.h --- config.def.h | 7 ++++++- dunst.c | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/config.def.h b/config.def.h index 01c02c7..cd41ea7 100644 --- a/config.def.h +++ b/config.def.h @@ -5,7 +5,7 @@ /* appearance */ -const char *font = NULL; +const char *font = "-*-terminus-medium-r-*-*-16-*-*-*-*-*-*-*"; const char *normbgcolor = "#1793D1"; const char *normfgcolor = "#DDDDDD"; const char *critbgcolor = "#ffaaaa"; @@ -17,6 +17,11 @@ int timeouts[] = { 10, 10, 0 }; /* low, normal, critical */ const char *geom = "0x4-10+10"; /* geometry */ +char *key_string = "space"; /* set to NULL for no keybinging */ +KeySym mask = ControlMask; +/* KeySym mask = ControlMask || Mod4Mask */ + + int verbose = True; /* print info to stdout? */ diff --git a/dunst.c b/dunst.c index 657d0c4..19c6ccc 100644 --- a/dunst.c +++ b/dunst.c @@ -42,7 +42,6 @@ static msg_queue_t *msgqueue = NULL; static time_t now; static int visible = False; static KeySym key = NoSymbol; -static KeySym mask = 0; static screen_info scr; static dimension_t geometry; static int font_h; @@ -540,6 +539,7 @@ main(int argc, char *argv[]) { geometry.mask = XParseGeometry(geom, &geometry.x, &geometry.y, &geometry.w, &geometry.h); + key = key_string ? XStringToKeysym(key_string) : NoSymbol; while(1) { static struct option long_options[] = {