Xresources
Runtime configuration using X resources.
Description
This patch adds X resources support to dwm. At startup, dwm reads the configured X resources and applies them.
This patch also adds a hotkey (Modkey + F5 by default) which reloads the
configured resources during runtime.
Configuration
The resources array contains list of settings to load from X resources:
/* X resources to update */
static const XResPref resources[] = {
/* name type address */
{ "dwm.font", STRING, &fonts[0] },
{ "dwm.foreground", STRING, &colors[SchemeNorm][ColFg] },
{ "dwm.borderpx", INTEGER, &borderpx },
{ "dwm.mfact", FLOAT, &mfact },
};
Each entry contains the name of resource, the variable type, and the variable address.
Download
- dwm-xresources-6.2.diff (11/06/2020)
- dwm-xresources-20210314.diff
- dwm-xresources-20210827-138b405.diff
- dwm-xresources-20260524-44dbc68.diff
Author
- MLquest8 (miskuzius at gmail.com)
- Justinas Grigas dev@jstnas.com (20260524)