Add .Xresources toggle

This commit is contained in:
speediegq 2022-08-18 22:16:43 +02:00
parent f9dedc8b35
commit f0621ca873
2 changed files with 9 additions and 0 deletions

View file

@ -215,3 +215,6 @@ char *termname = "st-256color"; /* $TERM value */
/* Tab space options */
unsigned int tabspaces = 8;
/* Misc */
#define USEXRESOURCES /* Use .Xresources. Comment this line if you do not want .Xresources support. */

6
x.c
View file

@ -92,7 +92,11 @@ static void ttysend(const Arg *);
#include "options.h" /* include user configuration */
#include "char.h" /* include misc chars */
#ifdef USEXRESOURCES
#include "xresources.h" /* include .xresources/xrdb options */
#endif
#include "keybinds.h" /* include keybinds */
#include "mouse.h" /* include mouse binds */
#include "mapped.h" /* include list of mapped keys */
@ -2745,8 +2749,10 @@ config_init(void)
return;
db = XrmGetStringDatabase(resm);
#ifdef USEXRESOURCES
for (p = resources; p < resources + LEN(resources); p++)
resource_load(db, p->name, p->type, p->dst);
#endif
}
void