about summary refs log tree commit diff
path: root/parse.y
diff options
context:
space:
mode:
authormartynas <martynas>2009-02-07 21:07:00 +0000
committermartynas <martynas>2009-02-07 21:07:00 +0000
commit17ae65adc59532b77d845c823b9902f7feff1f23 (patch)
tree2b7024ed1a372ee17d422ecb477b78653cdde660 /parse.y
parent507b65a27fedf439cdba086c4f918d3efaeae8dd (diff)
downloadcwm-17ae65adc59532b77d845c823b9902f7feff1f23.tar.gz
cwm-17ae65adc59532b77d845c823b9902f7feff1f23.tar.xz
cwm-17ae65adc59532b77d845c823b9902f7feff1f23.zip
add 'moveamount' to cwmrc; it sets keyboard movement amount, making
it more useful on large screens
manpage tweak & ok jmc@
ok okan@, oga@
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y7
1 files changed, 6 insertions, 1 deletions
diff --git a/parse.y b/parse.y
index 6dd1fab..2554ed3 100644
--- a/parse.y
+++ b/parse.y
@@ -66,7 +66,7 @@ typedef struct {
 
 %token	FONTNAME STICKY GAP MOUSEBIND
 %token	AUTOGROUP BIND COMMAND IGNORE
-%token	YES NO BORDERWIDTH
+%token	YES NO BORDERWIDTH MOVEAMOUNT
 %token	ERROR
 %token	<v.string>		STRING
 %token	<v.number>		NUMBER
@@ -110,6 +110,9 @@ main		: FONTNAME STRING		{
 		| BORDERWIDTH NUMBER {
 			conf->bwidth = $2;
 		}
+		| MOVEAMOUNT NUMBER {
+			conf->mamount = $2;
+		}
 		| COMMAND STRING string		{
 			conf_cmd_add(conf, $3, $2, 0);
 			free($2);
@@ -207,6 +210,7 @@ lookup(char *s)
 		{ "gap",		GAP},
 		{ "ignore",		IGNORE},
 		{ "mousebind",		MOUSEBIND},
+		{ "moveamount",		MOVEAMOUNT},
 		{ "no",			NO},
 		{ "sticky",		STICKY},
 		{ "yes",		YES}
@@ -499,6 +503,7 @@ parse_config(const char *filename, struct conf *xconf)
 
 		xconf->flags = conf->flags;
 		xconf->bwidth = conf->bwidth;
+		xconf->mamount = conf->mamount;
 
 		while ((cmd = TAILQ_FIRST(&conf->cmdq)) != NULL) {
 			TAILQ_REMOVE(&conf->cmdq, cmd, entry);