Adding X resource for gaps

This commit is contained in:
phillbush 2020-06-29 12:32:02 -03:00
parent a3a7383740
commit eecf9b25ff

View File

@ -198,6 +198,9 @@ initresources(void)
if (XrmGetResource(xdb, "xmenu.width", "*", &type, &xval) == True) if (XrmGetResource(xdb, "xmenu.width", "*", &type, &xval) == True)
if ((n = strtol(xval.addr, NULL, 10)) > 0) if ((n = strtol(xval.addr, NULL, 10)) > 0)
config.width_pixels = n; config.width_pixels = n;
if (XrmGetResource(xdb, "xmenu.gap", "*", &type, &xval) == True)
if ((n = strtol(xval.addr, NULL, 10)) > 0)
config.gap_pixels = n;
if (XrmGetResource(xdb, "xmenu.background", "*", &type, &xval) == True) if (XrmGetResource(xdb, "xmenu.background", "*", &type, &xval) == True)
config.background_color = strdup(xval.addr); config.background_color = strdup(xval.addr);
if (XrmGetResource(xdb, "xmenu.foreground", "*", &type, &xval) == True) if (XrmGetResource(xdb, "xmenu.foreground", "*", &type, &xval) == True)