xresource
authorDaniel Liu <mr.picklepinosaur@gmail.com>
Fri, 18 Sep 2020 03:06:57 +0000 (23:06 -0400)
committerDaniel Liu <mr.picklepinosaur@gmail.com>
Fri, 18 Sep 2020 03:06:57 +0000 (23:06 -0400)
1  2 
config.def.h

diff --combined config.def.h
@@@ -1,6 -1,6 +1,6 @@@
  /* user and group to drop privileges to */
 -static const char *user  = "nobody";
 -static const char *group = "nogroup";
 +static const char *user  = "pinosaur";
 +static const char *group = "pinosaur";
  
  static const char *colorname[NUMCOLS] = {
        [INIT] =   "black",     /* after initialization */
@@@ -8,5 -8,16 +8,16 @@@
        [FAILED] = "#CC3333",   /* wrong password */
  };
  
+ /*
+  * Xresources preferences to load at startup
+  */
+ ResourcePref resources[] = {
+               { "color0",       STRING,  &colorname[INIT] },
+               { "color4",       STRING,  &colorname[INPUT] },
+               { "color1",       STRING,  &colorname[FAILED] },
+               { "color3",       STRING,  &colorname[CAPS] },
+ };
  /* treat a cleared input like a wrong password (color) */
  static const int failonclear = 1;