dmenu

[fork] X11 menuing
Log | Files | Refs | README | LICENSE

commit ffd73c9ec6881485fa848d0023ae498b1db3982f
parent 400d7aec29ea1e7484dc65987b388fb8c56aa040
Author: Hayden Hamilton <hayden@haydenvh.com>
Date:   Mon, 21 Sep 2020 16:22:23 +0100

make some changes for compatiblity with surf

Diffstat:
A.gitignore | 3+++
Mconfig.h | 2+-
Mdmenu.c | 6+++---
3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/.gitignore b/.gitignore @@ -0,0 +1,3 @@ +dmenu +stest +*.o diff --git a/config.h b/config.h @@ -5,7 +5,7 @@ static int topbar = 1; /* -b option; if 0, dmenu appears a static int centered = 1; /* -c option; centers dmenu on screen */ static int fuzzy = 1; static int lineheight = 20; -static unsigned int dmw = 1000; +static unsigned int dmw = 600; /* -fn option overrides fonts[0]; default X11 font or font set */ static const char *fonts[] = { "monospace:size=8" diff --git a/dmenu.c b/dmenu.c @@ -871,7 +871,7 @@ main(int argc, char *argv[]) else if (!strcmp(argv[i], "-f")) /* grabs keyboard before reading stdin */ fast = 1; else if (!strcmp(argv[i], "-c")) /* centers dmenu on screen */ - centered = 1; + centered = 0; else if (!strcmp(argv[i], "-i")) { /* case-insensitive item matching */ fstrncmp = strncasecmp; fstrstr = cistrstr; @@ -882,8 +882,8 @@ main(int argc, char *argv[]) /* these options take one argument */ else if (!strcmp(argv[i], "-l")) /* number of lines in vertical list */ lines = atoi(argv[++i]); - else if (!strcmp(argv[i], "-w")) /* make dmenu this wide */ - dmw = atoi(argv[++i]); + else if (!strcmp(argv[i], "-w")) + embed = argv[++i]; else if (!strcmp(argv[i], "-m")) mon = atoi(argv[++i]); else if (!strcmp(argv[i], "-p")) /* adds prompt to left of input field */