Re: [dev] dwm: monocle view

From: Niki Yoshiuchi <>
Date: Wed, 2 Mar 2011 11:04:41 -0500

I am unfortunately on a Windows machine right now (at work) but if I
understand you correctly, this is by design.

alt+j/k moves the focus. Think about what happens when you hit
alt+j/k in tile mode to set the focus on a window in the stack. If
you then launch a new window, the new window becomes the master and
the window that was the master, *not* the window with focus, moves to
the top of the stack (the "previous window" as you put it).

When you are in monocle mode, alt+j/k does the same thing as in tile
mode. It changes focus only. The window you are looking at in
monocle mode isn't necessarily the master.

The reason for this is that the windows (called Clients, by the way),
are stored in a linked list. The head of the list is the master.
When you open a new Client, it gets pushed to the front of the list.
What you are suggesting is to either push the new Client to location
in the list that currently has focus, or to move the Client that has
focus to the front, then add the new Client in front of that. While
this is a pretty simple change, it doesn't belong in dwm (though as a
patch it would be fine), the reason being that the behavior of all the
commands are independent of what mode you are in, and should remain
that way. What you are suggesting is adding special rules to one

-Niki Yoshiuchi

On Wed, Mar 2, 2011 at 6:08 AM, Marcin Szamotulski <> wrote:
> ---------- Forwarded message ----------
> From:
> To:
> Date:
> Subject:
> Hello,
> I found that in monocle layout there is some confusing behaviour of dwm:
>        In tiled layout the previous opened window is always under the freshly
>        opened one (hit alt+shift+enter to get new terminal window and then
>        your previously focused window is under alt+j - one below in the
>        stack).
> However, this is not always the case in monocle layout.
>        For example if you change the layout from tailed to monocle, and then
>        after possible moves around using alt+j, alt+k, then open new
>        window and the previous window (the one under alt+j) is always the one
>        that was in the main area in the tailed layout. This is quite confusing when
>        using  alt+j or alt+k after changing the layout from tailed to
>        monocle.
> After some experiments, it seems to me that the previous window is the
> main area window not the one that had focus, and the main area window
> is not altered in the monocle layout.
> Best regards,
> Marcin Szamotulski
Received on Wed Mar 02 2011 - 17:04:41 CET

This archive was generated by hypermail 2.2.0 : Wed Mar 02 2011 - 17:12:02 CET