diff options
author | Connor Lane Smith <cls@lubutu.com> | 2010-08-05 15:41:56 +0100 |
---|---|---|
committer | Connor Lane Smith <cls@lubutu.com> | 2010-08-05 15:41:56 +0100 |
commit | 31ffcd3b9a2beccb8b8830055748e52e07b3b258 (patch) | |
tree | 4194d4eba50bfd9a34e8a577f1ccff242a457cab | |
parent | 9cf07b4b9b0d8feb53492ac11aa97a1405246cb4 (diff) |
new libdraw, typo fixes
-rw-r--r-- | dmenu.1 | 2 | ||||
-rw-r--r-- | dmenu.c | 10 |
2 files changed, 6 insertions, 6 deletions
@@ -52,7 +52,7 @@ dmenu matches menu items case insensitively. | |||
52 | dmenu lists items vertically, with the given number of lines. | 52 | dmenu lists items vertically, with the given number of lines. |
53 | .TP | 53 | .TP |
54 | .BI \-p " prompt" | 54 | .BI \-p " prompt" |
55 | defines the prompt to be displayed to the left of the input area. | 55 | defines the prompt to be displayed to the left of the input field. |
56 | .TP | 56 | .TP |
57 | .BI \-fn " font" | 57 | .BI \-fn " font" |
58 | defines the font set used. | 58 | defines the font set used. |
@@ -119,7 +119,7 @@ drawmenu(void) { | |||
119 | dc->x = dc->w; | 119 | dc->x = dc->w; |
120 | } | 120 | } |
121 | dc->w = mw - dc->x; | 121 | dc->w = mw - dc->x; |
122 | /* print input area */ | 122 | /* print input field */ |
123 | if(matches && lines == 0 && textw(dc, text) <= inputw) | 123 | if(matches && lines == 0 && textw(dc, text) <= inputw) |
124 | dc->w = inputw; | 124 | dc->w = inputw; |
125 | drawtext(dc, text, normcol); | 125 | drawtext(dc, text, normcol); |
@@ -339,7 +339,7 @@ keypress(XKeyEvent *e) { | |||
339 | 339 | ||
340 | void | 340 | void |
341 | match(void) { | 341 | match(void) { |
342 | unsigned int len; | 342 | size_t len; |
343 | Item *item, *itemend, *lexact, *lprefix, *lsubstr, *exactend, *prefixend, *substrend; | 343 | Item *item, *itemend, *lexact, *lprefix, *lsubstr, *exactend, *prefixend, *substrend; |
344 | 344 | ||
345 | len = strlen(text); | 345 | len = strlen(text); |
@@ -454,7 +454,7 @@ setup(void) { | |||
454 | selcol[ColBG] = getcolor(dc, selbgcolor); | 454 | selcol[ColBG] = getcolor(dc, selbgcolor); |
455 | selcol[ColFG] = getcolor(dc, selfgcolor); | 455 | selcol[ColFG] = getcolor(dc, selfgcolor); |
456 | 456 | ||
457 | /* input window geometry */ | 457 | /* menu geometry */ |
458 | mh = (dc->font.height + 2) * (lines + 1); | 458 | mh = (dc->font.height + 2) * (lines + 1); |
459 | #ifdef XINERAMA | 459 | #ifdef XINERAMA |
460 | if((info = XineramaQueryScreens(dc->dpy, &n))) { | 460 | if((info = XineramaQueryScreens(dc->dpy, &n))) { |
@@ -478,7 +478,7 @@ setup(void) { | |||
478 | y = topbar ? 0 : DisplayHeight(dc->dpy, screen) - mh; | 478 | y = topbar ? 0 : DisplayHeight(dc->dpy, screen) - mh; |
479 | mw = DisplayWidth(dc->dpy, screen); | 479 | mw = DisplayWidth(dc->dpy, screen); |
480 | } | 480 | } |
481 | /* input window */ | 481 | /* menu window */ |
482 | wa.override_redirect = True; | 482 | wa.override_redirect = True; |
483 | wa.background_pixmap = ParentRelative; | 483 | wa.background_pixmap = ParentRelative; |
484 | wa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask; | 484 | wa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask; |
@@ -488,7 +488,7 @@ setup(void) { | |||
488 | CWOverrideRedirect | CWBackPixmap | CWEventMask, &wa); | 488 | CWOverrideRedirect | CWBackPixmap | CWEventMask, &wa); |
489 | 489 | ||
490 | grabkeyboard(); | 490 | grabkeyboard(); |
491 | setcanvas(dc, win, mw, mh); | 491 | setcanvas(dc, mw, mh); |
492 | inputw = MIN(inputw, mw/3); | 492 | inputw = MIN(inputw, mw/3); |
493 | promptw = prompt ? MIN(textw(dc, prompt), mw/5) : 0; | 493 | promptw = prompt ? MIN(textw(dc, prompt), mw/5) : 0; |
494 | XMapRaised(dc->dpy, win); | 494 | XMapRaised(dc->dpy, win); |