diff options
| author | Luke Smith <luke@lukesmith.xyz> | 2022-10-01 08:16:18 -0400 |
|---|---|---|
| committer | Luke Smith <luke@lukesmith.xyz> | 2022-10-01 08:16:18 -0400 |
| commit | 8d6175da851a63199530d7214c0b3ebfc3a4c45c (patch) | |
| tree | b7b40632625e1c97a2f59c9b64dd39a48eba55de | |
| parent | ee8871c046700b0eb21b8cf97db0c8e0b4f0ba0a (diff) | |
| parent | 705b3c7c9f74fd1c370c6ed994e821135bb7acd4 (diff) | |
Merge branch 'master' of github.com:LukeSmithxyz/dmenu
| -rw-r--r-- | config.h | 3 | ||||
| -rw-r--r-- | dmenu.c | 30 | ||||
| -rw-r--r-- | drw.c | 1 |
3 files changed, 18 insertions, 16 deletions
@@ -5,7 +5,7 @@ static int topbar = 1; /* -b option; if 0, dmenu appears a /* -fn option overrides fonts[0]; default X11 font or font set */ static const char *fonts[] = { "monospace:size=10", - "JoyPixels:pixelsize=8:antialias=true:autohint=true" + "NotoColorEmoji:pixelsize=8:antialias=true:autohint=true" }; static const unsigned int bgalpha = 0xe0; static const unsigned int fgalpha = OPAQUE; @@ -31,3 +31,4 @@ static unsigned int lines = 0; * for example: " /?\"&[]" */ static const char worddelimiters[] = " "; + @@ -918,6 +918,21 @@ main(int argc, char *argv[]) XWindowAttributes wa; int i, fast = 0; + if (!setlocale(LC_CTYPE, "") || !XSupportsLocale()) + fputs("warning: no locale support\n", stderr); + if (!(dpy = XOpenDisplay(NULL))) + die("cannot open display"); + screen = DefaultScreen(dpy); + root = RootWindow(dpy, screen); + if (!embed || !(parentwin = strtol(embed, NULL, 0))) + parentwin = root; + if (!XGetWindowAttributes(dpy, parentwin, &wa)) + die("could not get embedding window attributes: 0x%lx", + parentwin); + xinitvisual(); + drw = drw_create(dpy, screen, root, wa.width, wa.height, visual, depth, cmap); + read_Xresources(); + for (i = 1; i < argc; i++) /* these options take no arguments */ if (!strcmp(argv[i], "-v")) { /* prints version information */ @@ -958,20 +973,6 @@ main(int argc, char *argv[]) else usage(); - if (!setlocale(LC_CTYPE, "") || !XSupportsLocale()) - fputs("warning: no locale support\n", stderr); - if (!(dpy = XOpenDisplay(NULL))) - die("cannot open display"); - screen = DefaultScreen(dpy); - root = RootWindow(dpy, screen); - if (!embed || !(parentwin = strtol(embed, NULL, 0))) - parentwin = root; - if (!XGetWindowAttributes(dpy, parentwin, &wa)) - die("could not get embedding window attributes: 0x%lx", - parentwin); - xinitvisual(); - drw = drw_create(dpy, screen, root, wa.width, wa.height, visual, depth, cmap); - read_Xresources(); if (!drw_fontset_create(drw, fonts, LENGTH(fonts))) die("no fonts could be loaded."); lrpad = drw->fonts->h; @@ -993,3 +994,4 @@ main(int argc, char *argv[]) return 1; /* unreachable */ } + @@ -339,7 +339,6 @@ drw_text(Drw *drw, int x, int y, unsigned int w, unsigned int h, unsigned int lp fcpattern = FcPatternDuplicate(drw->fonts->pattern); FcPatternAddCharSet(fcpattern, FC_CHARSET, fccharset); FcPatternAddBool(fcpattern, FC_SCALABLE, FcTrue); - FcPatternAddBool(fcpattern, FC_COLOR, FcFalse); FcConfigSubstitute(NULL, fcpattern, FcMatchPattern); FcDefaultSubstitute(fcpattern); |
