NMASTER PATCH

Description

This patch restores the ability to have multiple clients in the master area of the tiled layout. This feature was dropped from vanilla dwm in version 4.4.

ntile         (-|=)
+----------+------+
|          |      |
|          +------+
|----------|      |
|          +------+
|          |      |
+----------+------+

nbstack       (-|-)
+--------+--------+
|        |        |
|        |        |
|-----+--+--+-----+
|     |     |     |
|     |     |     |
+-----+-----+-----+

Usage

Example

static const int nmaster = 2;  /* default number of clients in the master area */

#include "nmaster.c"

static const Layout layouts[] = {
    /* symbol     arrange function */
    { "-|=",      ntile },
    { "-|-",      nbstack },
...

static Key keys[] = {
    /* modifier                     key        function        argument */
    { MODKEY,                       XK_a,      incnmaster,     {.i = +1 } },
    { MODKEY,                       XK_z,      incnmaster,     {.i = -1 } },
    { MODKEY,                       XK_x,      setnmaster,     {.i = 2 } },
    { MODKEY,                       XK_t,      setlayout,      {.v = &layouts[0] } },
    { MODKEY,                       XK_b,      setlayout,      {.v = &layouts[1] } },
...

Download