summaryrefslogtreecommitdiff
path: root/src/actions.c
diff options
context:
space:
mode:
authorsabetts <sabetts>2001-12-21 10:13:51 +0000
committersabetts <sabetts>2001-12-21 10:13:51 +0000
commit23f9dc31a7bba68e275c0a00775f59bc04e0bb18 (patch)
treed35d2894efa7bcf64921aa8a3d60f2e5e4cedde1 /src/actions.c
parent2a67d86985a3d67d707d7d6c46a3b7e5b7d11435 (diff)
downloadratpoison-23f9dc31a7bba68e275c0a00775f59bc04e0bb18.zip
* src/input.c (update_input_window): Draw the cursor in the right place.
* src/actions.h (cmd_defbarpadding): new prototype * src/actions.c (user_commands): new command entry "defbarpadding" (cmd_defbarpadding): new function
Diffstat (limited to 'src/actions.c')
-rw-r--r--src/actions.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/actions.c b/src/actions.c
index acc6398..48e9179 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -97,6 +97,7 @@ static user_command user_commands[] =
{"defwingravity", cmd_defwingravity, arg_STRING},
{"deffgcolor", cmd_deffgcolor, arg_STRING},
{"defbgcolor", cmd_defbgcolor, arg_STRING},
+ {"defbarpadding", cmd_defbarpadding, arg_STRING},
/* Commands to help debug ratpoison. */
#ifdef DEBUG
@@ -2040,3 +2041,26 @@ cmd_link (int interactive, void *data)
return NULL;
}
+
+char *
+cmd_defbarpadding (int interactive, void *data)
+{
+ int x, y;
+
+ if (data == NULL || sscanf (data, "%d %d", &x, &y) < 2)
+ {
+ message (" defbarpadding: Two arguments required ");
+ return NULL;
+ }
+
+ if (x >= 0 && y >= 0)
+ {
+ defaults.bar_x_padding = x;
+ defaults.bar_y_padding = y;
+ }
+ else
+ {
+ message (" defbarpadding: Bad argument ");
+ }
+ return NULL;
+}