sites

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 43c8ef6b4ecd55759e123c7fb72f4dacf21b80d4
parent 1ef81ad750f0f98648572bae57206cd3480981aa
Author: = <harry.gindi@live.com>
Date:   Mon, 26 Jun 2017 12:35:34 -0400

Updated outdated solarized-both patch to latest git edition, added my credits

Diffstat:
Mst.suckless.org/patches/solarized.md | 9++++-----
Dst.suckless.org/patches/st-solarized-both-20160727-308bfbf.diff | 189-------------------------------------------------------------------------------
Dst.suckless.org/patches/st-solarized-both-20160727-745c40f.diff | 226-------------------------------------------------------------------------------
Ast.suckless.org/patches/st-solarized-both-20170626-b331da5.diff | 216+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 220 insertions(+), 420 deletions(-)

diff --git a/st.suckless.org/patches/solarized.md b/st.suckless.org/patches/solarized.md @@ -53,14 +53,13 @@ or the dark color scheme: *Both (swap between light/dark with F6)*: - * [st-solarized-both-20160727-308bfbf.diff](st-solarized-both-20160727-308bfbf.diff) - * [st-solarized-both-20160727-745c40f.diff](st-solarized-both-20160727-745c40f.diff) + * [st-solarized-both-20170626-b331da5.diff](st-solarized-both-20170626-b331da5.diff) Authors ------- - * Nils Reuße - <nilsreusse@gmail.com> - * Laslo Hunhold - <dev@frign.de> (0.5, 0.6, git ports) + * Laslo Hunhold - <dev@frign.de> (0.5, 0.6) * Ryan Roden-Corrent - <ryan@rcorre.net> (both) - * Marcel Krüger - <zauguin@gmail.com> (both git port) + * Marcel Krüger - <zauguin@gmail.com> (oudated git ports) + * Harry Gindi - <harry.gindi@live.com> (git ports for light, dark, and swap versions) diff --git a/st.suckless.org/patches/st-solarized-both-20160727-308bfbf.diff b/st.suckless.org/patches/st-solarized-both-20160727-308bfbf.diff @@ -1,189 +0,0 @@ -diff --git a/config.def.h b/config.def.h -index b41747f..adaa9b8 100644 ---- a/config.def.h -+++ b/config.def.h -@@ -84,42 +84,54 @@ static unsigned int tabspaces = 8; - - /* Terminal colors (16 first used in escape sequence) */ - static const char *colorname[] = { -- /* 8 normal colors */ -- "black", -- "red3", -- "green3", -- "yellow3", -- "blue2", -- "magenta3", -- "cyan3", -- "gray90", -- -- /* 8 bright colors */ -- "gray50", -- "red", -- "green", -- "yellow", -- "#5c5cff", -- "magenta", -- "cyan", -- "white", -- -- [255] = 0, -- -- /* more colors can be added after 255 to use with DefaultXX */ -- "#cccccc", -- "#555555", -+ /* solarized dark */ -+ "#073642", /* 0: black */ -+ "#dc322f", /* 1: red */ -+ "#859900", /* 2: green */ -+ "#b58900", /* 3: yellow */ -+ "#268bd2", /* 4: blue */ -+ "#d33682", /* 5: magenta */ -+ "#2aa198", /* 6: cyan */ -+ "#eee8d5", /* 7: white */ -+ "#002b36", /* 8: brblack */ -+ "#cb4b16", /* 9: brred */ -+ "#586e75", /* 10: brgreen */ -+ "#657b83", /* 11: bryellow */ -+ "#839496", /* 12: brblue */ -+ "#6c71c4", /* 13: brmagenta*/ -+ "#93a1a1", /* 14: brcyan */ -+ "#fdf6e3", /* 15: brwhite */ - }; - -+/* Terminal colors for alternate (light) palette */ -+static const char *altcolorname[] = { -+ /* solarized light */ -+ "#eee8d5", /* 0: black */ -+ "#dc322f", /* 1: red */ -+ "#859900", /* 2: green */ -+ "#b58900", /* 3: yellow */ -+ "#268bd2", /* 4: blue */ -+ "#d33682", /* 5: magenta */ -+ "#2aa198", /* 6: cyan */ -+ "#073642", /* 7: white */ -+ "#fdf6e3", /* 8: brblack */ -+ "#cb4b16", /* 9: brred */ -+ "#93a1a1", /* 10: brgreen */ -+ "#839496", /* 11: bryellow */ -+ "#657b83", /* 12: brblue */ -+ "#6c71c4", /* 13: brmagenta*/ -+ "#586e75", /* 14: brcyan */ -+ "#002b36", /* 15: brwhite */ -+}; - - /* - * Default colors (colorname index) - * foreground, background, cursor, reverse cursor - */ --static unsigned int defaultfg = 7; --static unsigned int defaultbg = 0; --static unsigned int defaultcs = 256; --static unsigned int defaultrcs = 257; -+static unsigned int defaultfg = 12; -+static unsigned int defaultbg = 8; -+static unsigned int defaultcs = 14; -+static unsigned int defaultrcs = 15; - - /* - * Default shape of cursor -@@ -172,6 +184,7 @@ static Shortcut shortcuts[] = { - { MODKEY|ShiftMask, XK_C, clipcopy, {.i = 0} }, - { MODKEY|ShiftMask, XK_V, clippaste, {.i = 0} }, - { MODKEY, XK_Num_Lock, numlock, {.i = 0} }, -+ { XK_ANY_MOD, XK_F6, swapcolors, {.i = 0} }, - }; - - /* -diff --git a/st.c b/st.c -index 2594c65..b4a3089 100644 ---- a/st.c -+++ b/st.c -@@ -328,6 +328,7 @@ typedef struct { - static void clipcopy(const Arg *); - static void clippaste(const Arg *); - static void numlock(const Arg *); -+static void swapcolors(const Arg *); - static void selpaste(const Arg *); - static void xzoom(const Arg *); - static void xzoomabs(const Arg *); -@@ -355,7 +356,7 @@ typedef struct { - - /* Drawing Context */ - typedef struct { -- Color col[MAX(LEN(colorname), 256)]; -+ Color col[MAX(MAX(LEN(colorname), LEN(altcolorname)), 256)]; - Font font, bfont, ifont, ibfont; - GC gc; - } DC; -@@ -533,6 +534,8 @@ static char *opt_name = NULL; - static char *opt_title = NULL; - static int oldbutton = 3; /* button event on startup: 3 = release */ - -+static int usealtcolors = 0; /* 1 to use alternate palette */ -+ - static char *usedfont = NULL; - static double usedfontsize = 0; - static double defaultfontsize = 0; -@@ -3148,6 +3151,11 @@ sixd_to_16bit(int x) - return x == 0 ? 0 : 0x3737 + 0x2828 * x; - } - -+const char* getcolorname(int i) -+{ -+ return (usealtcolors) ? altcolorname[i] : colorname[i]; -+} -+ - int - xloadcolor(int i, const char *name, Color *ncolor) - { -@@ -3166,7 +3174,7 @@ xloadcolor(int i, const char *name, Color *ncolor) - return XftColorAllocValue(xw.dpy, xw.vis, - xw.cmap, &color, ncolor); - } else -- name = colorname[i]; -+ name = getcolorname(i); - } - - return XftColorAllocName(xw.dpy, xw.vis, xw.cmap, name, ncolor); -@@ -3186,8 +3194,8 @@ xloadcols(void) - - for (i = 0; i < LEN(dc.col); i++) - if (!xloadcolor(i, NULL, &dc.col[i])) { -- if (colorname[i]) -- die("Could not allocate color '%s'\n", colorname[i]); -+ if (getcolorname(i)) -+ die("Could not allocate color '%s'\n", getcolorname(i)); - else - die("Could not allocate color %d\n", i); - } -@@ -3514,13 +3522,13 @@ xinit(void) - cursor = XCreateFontCursor(xw.dpy, mouseshape); - XDefineCursor(xw.dpy, xw.win, cursor); - -- if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) { -+ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousefg), &xmousefg) == 0) { - xmousefg.red = 0xffff; - xmousefg.green = 0xffff; - xmousefg.blue = 0xffff; - } - -- if (XParseColor(xw.dpy, xw.cmap, colorname[mousebg], &xmousebg) == 0) { -+ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousebg), &xmousebg) == 0) { - xmousebg.red = 0x0000; - xmousebg.green = 0x0000; - xmousebg.blue = 0x0000; -@@ -4074,6 +4082,14 @@ numlock(const Arg *dummy) - term.numlock ^= 1; - } - -+void -+swapcolors(const Arg *dummy) -+{ -+ usealtcolors = !usealtcolors; -+ xloadcols(); -+ redraw(); -+} -+ - char* - kmap(KeySym k, uint state) - { diff --git a/st.suckless.org/patches/st-solarized-both-20160727-745c40f.diff b/st.suckless.org/patches/st-solarized-both-20160727-745c40f.diff @@ -1,226 +0,0 @@ -From d76c18a7214d47b64ace4a23893de3dde23cb1d1 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Marcel=20Kr=C3=BCger?= <zauguin@gmail.com> -Date: Sat, 8 Apr 2017 18:57:22 +0200 -Subject: [PATCH] Solarized - ---- - config.def.h | 71 +++++++++++++++++++++++++++++++++++------------------------- - st.c | 13 ++++++++++- - st.h | 3 +++ - x.c | 15 ++++++++----- - 4 files changed, 67 insertions(+), 35 deletions(-) - -diff --git a/config.def.h b/config.def.h -index 877afab..7ad0b44 100644 ---- a/config.def.h -+++ b/config.def.h -@@ -84,42 +84,54 @@ static unsigned int tabspaces = 8; - - /* Terminal colors (16 first used in escape sequence) */ - const char *colorname[] = { -- /* 8 normal colors */ -- "black", -- "red3", -- "green3", -- "yellow3", -- "blue2", -- "magenta3", -- "cyan3", -- "gray90", -- -- /* 8 bright colors */ -- "gray50", -- "red", -- "green", -- "yellow", -- "#5c5cff", -- "magenta", -- "cyan", -- "white", -- -- [255] = 0, -- -- /* more colors can be added after 255 to use with DefaultXX */ -- "#cccccc", -- "#555555", -+ /* solarized dark */ -+ "#073642", /* 0: black */ -+ "#dc322f", /* 1: red */ -+ "#859900", /* 2: green */ -+ "#b58900", /* 3: yellow */ -+ "#268bd2", /* 4: blue */ -+ "#d33682", /* 5: magenta */ -+ "#2aa198", /* 6: cyan */ -+ "#eee8d5", /* 7: white */ -+ "#002b36", /* 8: brblack */ -+ "#cb4b16", /* 9: brred */ -+ "#586e75", /* 10: brgreen */ -+ "#657b83", /* 11: bryellow */ -+ "#839496", /* 12: brblue */ -+ "#6c71c4", /* 13: brmagenta*/ -+ "#93a1a1", /* 14: brcyan */ -+ "#fdf6e3", /* 15: brwhite */ - }; - -+/* Terminal colors for alternate (light) palette */ -+const char *altcolorname[] = { -+ /* solarized light */ -+ "#eee8d5", /* 0: black */ -+ "#dc322f", /* 1: red */ -+ "#859900", /* 2: green */ -+ "#b58900", /* 3: yellow */ -+ "#268bd2", /* 4: blue */ -+ "#d33682", /* 5: magenta */ -+ "#2aa198", /* 6: cyan */ -+ "#073642", /* 7: white */ -+ "#fdf6e3", /* 8: brblack */ -+ "#cb4b16", /* 9: brred */ -+ "#93a1a1", /* 10: brgreen */ -+ "#839496", /* 11: bryellow */ -+ "#657b83", /* 12: brblue */ -+ "#6c71c4", /* 13: brmagenta*/ -+ "#586e75", /* 14: brcyan */ -+ "#002b36", /* 15: brwhite */ -+}; - - /* - * Default colors (colorname index) - * foreground, background, cursor, reverse cursor - */ --unsigned int defaultfg = 7; --unsigned int defaultbg = 0; --unsigned int defaultcs = 256; --unsigned int defaultrcs = 257; -+unsigned int defaultfg = 12; -+unsigned int defaultbg = 8; -+unsigned int defaultcs = 14; -+unsigned int defaultrcs = 15; - - /* - * Default shape of cursor -@@ -178,6 +190,7 @@ Shortcut shortcuts[] = { - { TERMMOD, XK_Y, selpaste, {.i = 0} }, - { TERMMOD, XK_Num_Lock, numlock, {.i = 0} }, - { TERMMOD, XK_I, iso14755, {.i = 0} }, -+ { XK_ANY_MOD, XK_F6, swapcolors, {.i = 0} }, - }; - - /* -diff --git a/st.c b/st.c -index ae93ade..31e383b 100644 ---- a/st.c -+++ b/st.c -@@ -129,6 +129,7 @@ typedef struct { - static void clipcopy(const Arg *); - static void clippaste(const Arg *); - static void numlock(const Arg *); -+static void swapcolors(const Arg *); - static void selpaste(const Arg *); - static void zoom(const Arg *); - static void zoomabs(const Arg *); -@@ -219,6 +220,8 @@ char *opt_name = NULL; - char *opt_title = NULL; - int oldbutton = 3; /* button event on startup: 3 = release */ - -+int usealtcolors = 0; /* 1 to use alternate palette */ -+ - static CSIEscape csiescseq; - static STREscape strescseq; - static int iofd = 1; -@@ -233,7 +236,7 @@ static Rune utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000}; - static Rune utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF}; - - /* config.h array lengths */ --size_t colornamelen = LEN(colorname); -+size_t colornamelen = MAX(LEN(colorname), LEN(altcolorname)); - size_t mshortcutslen = LEN(mshortcuts); - size_t shortcutslen = LEN(shortcuts); - size_t selmaskslen = LEN(selmasks); -@@ -2628,6 +2631,14 @@ numlock(const Arg *dummy) - term.numlock ^= 1; - } - -+void -+swapcolors(const Arg *dummy) -+{ -+ usealtcolors = !usealtcolors; -+ xloadcols(); -+ redraw(); -+} -+ - char* - kmap(KeySym k, uint state) - { -diff --git a/st.h b/st.h -index 44d4938..ff74cc6 100644 ---- a/st.h -+++ b/st.h -@@ -232,6 +232,8 @@ extern char *opt_name; - extern char *opt_title; - extern int oldbutton; - -+extern int usealtcolors; -+ - extern char *usedfont; - extern double usedfontsize; - extern double defaultfontsize; -@@ -250,6 +252,7 @@ extern unsigned int cursorthickness; - extern unsigned int blinktimeout; - extern char termname[]; - extern const char *colorname[]; -+extern const char *altcolorname[]; - extern size_t colornamelen; - extern unsigned int defaultfg; - extern unsigned int defaultbg; -diff --git a/x.c b/x.c -index fbfd350..123131c 100644 ---- a/x.c -+++ b/x.c -@@ -573,6 +573,11 @@ sixd_to_16bit(int x) - return x == 0 ? 0 : 0x3737 + 0x2828 * x; - } - -+const char* getcolorname(int i) -+{ -+ return (usealtcolors) ? altcolorname[i] : colorname[i]; -+} -+ - int - xloadcolor(int i, const char *name, Color *ncolor) - { -@@ -591,7 +596,7 @@ xloadcolor(int i, const char *name, Color *ncolor) - return XftColorAllocValue(xw.dpy, xw.vis, - xw.cmap, &color, ncolor); - } else -- name = colorname[i]; -+ name = getcolorname(i); - } - - return XftColorAllocName(xw.dpy, xw.vis, xw.cmap, name, ncolor); -@@ -614,8 +619,8 @@ xloadcols(void) - - for (i = 0; i < dc.collen; i++) - if (!xloadcolor(i, NULL, &dc.col[i])) { -- if (colorname[i]) -- die("Could not allocate color '%s'\n", colorname[i]); -+ if (getcolorname(i)) -+ die("Could not allocate color '%s'\n", getcolorname(i)); - else - die("Could not allocate color %d\n", i); - } -@@ -950,13 +955,13 @@ xinit(void) - cursor = XCreateFontCursor(xw.dpy, mouseshape); - XDefineCursor(xw.dpy, xw.win, cursor); - -- if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) { -+ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousefg), &xmousefg) == 0) { - xmousefg.red = 0xffff; - xmousefg.green = 0xffff; - xmousefg.blue = 0xffff; - } - -- if (XParseColor(xw.dpy, xw.cmap, colorname[mousebg], &xmousebg) == 0) { -+ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousebg), &xmousebg) == 0) { - xmousebg.red = 0x0000; - xmousebg.green = 0x0000; - xmousebg.blue = 0x0000; diff --git a/st.suckless.org/patches/st-solarized-both-20170626-b331da5.diff b/st.suckless.org/patches/st-solarized-both-20170626-b331da5.diff @@ -0,0 +1,216 @@ +diff --git a/config.def.h b/config.def.h +index 877afab..7305ec9 100644 +--- a/config.def.h ++++ b/config.def.h +@@ -84,42 +84,54 @@ static unsigned int tabspaces = 8; + + /* Terminal colors (16 first used in escape sequence) */ + const char *colorname[] = { +- /* 8 normal colors */ +- "black", +- "red3", +- "green3", +- "yellow3", +- "blue2", +- "magenta3", +- "cyan3", +- "gray90", +- +- /* 8 bright colors */ +- "gray50", +- "red", +- "green", +- "yellow", +- "#5c5cff", +- "magenta", +- "cyan", +- "white", +- +- [255] = 0, +- +- /* more colors can be added after 255 to use with DefaultXX */ +- "#cccccc", +- "#555555", ++ /* solarized dark */ ++ "#073642", /* 0: black */ ++ "#dc322f", /* 1: red */ ++ "#859900", /* 2: green */ ++ "#b58900", /* 3: yellow */ ++ "#268bd2", /* 4: blue */ ++ "#d33682", /* 5: magenta */ ++ "#2aa198", /* 6: cyan */ ++ "#eee8d5", /* 7: white */ ++ "#002b36", /* 8: brblack */ ++ "#cb4b16", /* 9: brred */ ++ "#586e75", /* 10: brgreen */ ++ "#657b83", /* 11: bryellow */ ++ "#839496", /* 12: brblue */ ++ "#6c71c4", /* 13: brmagenta*/ ++ "#93a1a1", /* 14: brcyan */ ++ "#fdf6e3", /* 15: brwhite */ + }; +- ++ ++/* Terminal colors for alternate (light) palette */ ++const char *altcolorname[] = { ++ /* solarized light */ ++ "#eee8d5", /* 0: black */ ++ "#dc322f", /* 1: red */ ++ "#859900", /* 2: green */ ++ "#b58900", /* 3: yellow */ ++ "#268bd2", /* 4: blue */ ++ "#d33682", /* 5: magenta */ ++ "#2aa198", /* 6: cyan */ ++ "#073642", /* 7: white */ ++ "#fdf6e3", /* 8: brblack */ ++ "#cb4b16", /* 9: brred */ ++ "#93a1a1", /* 10: brgreen */ ++ "#839496", /* 11: bryellow */ ++ "#657b83", /* 12: brblue */ ++ "#6c71c4", /* 13: brmagenta*/ ++ "#586e75", /* 14: brcyan */ ++ "#002b36", /* 15: brwhite */ ++ }; + + /* + * Default colors (colorname index) + * foreground, background, cursor, reverse cursor + */ +-unsigned int defaultfg = 7; +-unsigned int defaultbg = 0; +-unsigned int defaultcs = 256; +-unsigned int defaultrcs = 257; ++unsigned int defaultfg = 12; ++unsigned int defaultbg = 8; ++unsigned int defaultcs = 14; ++unsigned int defaultrcs = 15; + + /* + * Default shape of cursor +@@ -178,6 +190,7 @@ Shortcut shortcuts[] = { + { TERMMOD, XK_Y, selpaste, {.i = 0} }, + { TERMMOD, XK_Num_Lock, numlock, {.i = 0} }, + { TERMMOD, XK_I, iso14755, {.i = 0} }, ++ { XK_ANY_MOD, XK_F6, swapcolors, {.i = 0} }, + }; + + /* +diff --git a/st.c b/st.c +index 8d4a9f2..fc7d9a6 100644 +--- a/st.c ++++ b/st.c +@@ -129,6 +129,7 @@ typedef struct { + static void clipcopy(const Arg *); + static void clippaste(const Arg *); + static void numlock(const Arg *); ++static void swapcolors(const Arg *); + static void selpaste(const Arg *); + static void zoom(const Arg *); + static void zoomabs(const Arg *); +@@ -219,6 +220,8 @@ char *opt_name = NULL; + char *opt_title = NULL; + int oldbutton = 3; /* button event on startup: 3 = release */ + ++int usealtcolors = 0; /* 1 to use alternate palette */ ++ + static CSIEscape csiescseq; + static STREscape strescseq; + static int iofd = 1; +@@ -233,7 +236,7 @@ static Rune utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000}; + static Rune utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF}; + + /* config.h array lengths */ +-size_t colornamelen = LEN(colorname); ++size_t colornamelen = MAX(LEN(colorname), LEN(altcolorname)); + size_t mshortcutslen = LEN(mshortcuts); + size_t shortcutslen = LEN(shortcuts); + size_t selmaskslen = LEN(selmasks); +@@ -2631,6 +2634,14 @@ numlock(const Arg *dummy) + term.numlock ^= 1; + } + ++void ++swapcolors(const Arg *dummy) ++{ ++ usealtcolors = !usealtcolors; ++ xloadcols(); ++ redraw(); ++} ++ + char* + kmap(KeySym k, uint state) + { +diff --git a/st.h b/st.h +index 44d4938..c464dd3 100644 +--- a/st.h ++++ b/st.h +@@ -250,7 +250,9 @@ extern unsigned int cursorthickness; + extern unsigned int blinktimeout; + extern char termname[]; + extern const char *colorname[]; ++extern const char *altcolorname[]; + extern size_t colornamelen; ++extern int usealtcolors; + extern unsigned int defaultfg; + extern unsigned int defaultbg; + extern unsigned int defaultcs; +diff --git a/x.c b/x.c +index fbfd350..886918b 100644 +--- a/x.c ++++ b/x.c +@@ -138,6 +138,7 @@ static void (*handler[LASTEvent])(XEvent *) = { + /* Globals */ + static DC dc; + static XWindow xw; ++ + static XSelection xsel; + + /* Font Ring Cache */ +@@ -573,6 +574,11 @@ sixd_to_16bit(int x) + return x == 0 ? 0 : 0x3737 + 0x2828 * x; + } + ++const char* getcolorname(int i) ++{ ++ return (usealtcolors) ? altcolorname[i] : colorname[i]; ++} ++ + int + xloadcolor(int i, const char *name, Color *ncolor) + { +@@ -591,7 +597,7 @@ xloadcolor(int i, const char *name, Color *ncolor) + return XftColorAllocValue(xw.dpy, xw.vis, + xw.cmap, &color, ncolor); + } else +- name = colorname[i]; ++ name = getcolorname(i); + } + + return XftColorAllocName(xw.dpy, xw.vis, xw.cmap, name, ncolor); +@@ -614,8 +620,8 @@ xloadcols(void) + + for (i = 0; i < dc.collen; i++) + if (!xloadcolor(i, NULL, &dc.col[i])) { +- if (colorname[i]) +- die("Could not allocate color '%s'\n", colorname[i]); ++ if (getcolorname(i)) ++ die("Could not allocate color '%s'\n", getcolorname(i)); + else + die("Could not allocate color %d\n", i); + } +@@ -950,13 +956,13 @@ xinit(void) + cursor = XCreateFontCursor(xw.dpy, mouseshape); + XDefineCursor(xw.dpy, xw.win, cursor); + +- if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) { ++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousefg), &xmousefg) == 0) { + xmousefg.red = 0xffff; + xmousefg.green = 0xffff; + xmousefg.blue = 0xffff; + } + +- if (XParseColor(xw.dpy, xw.cmap, colorname[mousebg], &xmousebg) == 0) { ++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousebg), &xmousebg) == 0) { + xmousebg.red = 0x0000; + xmousebg.green = 0x0000; + xmousebg.blue = 0x0000;