Chapter 5. Window Grouping

Table of Contents
5.1. What is window grouping?
5.2. How window grouping works
5.3. Advanced Grouping Topics

The main feature of pekwm is window grouping, similar to that of ion, or the tabs in pwm or fluxbox.

5.1. What is window grouping?

Window grouping is a very simple concept, but it could be hard to understand at first. It's a simple way of making multiple applications share the exact same space.

The simplest way to explain this is with an analogy. Imagine you have 20 sheets of paper. To save space, you stack them on top of each other. then, you have little tabs sticking out of one edge so you can quickly flip to any sheet of paper.

You have likely stumbled upon a WWW-browser that calls this tabbing. In pekwm, Window grouping is visually done by dividing up the physical space of the titlebar. We don't call them tabs for historical reasons, but refer to them as "clients". Windows that can contain any number of clients are more than often referred as "frames".

Also note that a frame can contain any type of clients. If you want to group one of your WWW-browser windows with your text editor for future reference, you're free to do so.

5.2. How window grouping works

The first thing to know is how to group one window to another. Middle-Click (On a normal X setup, the 2nd mouse button is the middle button) the titlebar of the first window and begin to drag the window. You should now see a rectangle with the window's title in it. Drag that rectangle to above the target window, and release your mouse button.

Any time this document mentions a key or mouse button, there's a strong likelihood that you can change which key or mouse button is used for that function. Please see the Keyboard and Mouse config section.

Now that you have windows in a group, you need to learn to choose between windows in that group. The first way is by clicking the middle mouse button on the window's part of the titlebar. That window should now be the currently-active window of the group. You can also use a keybinding for this. The default keybindings are Mod4+Tab and Mod4+Shift+Tab to go forward and back between active window in the frame.

To de-group, simply middle click and drag the window off the frame, and release anywhere. If you release over another window group, you'll move the window to the new group. Default keybinding for detaching clients from a group is first Ctrl+Mod1+T then D.

You can also set windows up to automatically be grouped to one another. See the Autoproperties section for more details.

5.3. Advanced Grouping Topics

Another thing you can do with window grouping is Tagging. This is done by setting the toggleable attribute "tagged" on a frame with the action "Set Tagged". A tag is like a miniature autogroup. It says "All new windows launched should be automatically grouped to this Frame" and all other autogrouping defined in the autoproperties will be ignored while it is set. "UnSet Tagged" removes the tag. Default keybinding to toggle tagging on a frame is Ctrl+Mod1+T then T. Unsetting tagging works even if the window you have set tagged isn't active. It's default keybinding is Ctrl+Mod1+T then C.

You can toggle all autogrouping on and off with the toggleable attribute GlobalGrouping. To disable you need to use the action "Unset GlobalGrouping" and to enable autogrouping use "Set GlobalGrouping". The default keybinding that toggless between set and unset is Ctrl+Mod1+T then G.

You can set a marked state on clients with "set marked" and then attach those marked clients to another frame by focusing the frame you want the marked clients attached to and then using the AttachMarked action. By default marking can be reached with two simple keybindings. Mod4+Z toggles a clients Marked state and Mod4+A attaches clients with marked state set into the current frame. Marked clients will have "[M]" appended to their titlebars.

Pekwm also includes some menus that have to do with grouping. AttachClientInFrame (Ctrl+Mod1+M, A) sends the current client to the selected frame. AttachFrameInFrame (Ctrl+Mod1+M, F) sends the contents of the current frame to the selected frame. AttachClient (Ctrl+Mod1+M, Shift+A) brings the selected client into the current frame. AttachFrame (Ctrl+Mod1+M, Shift+F) brings the contents of the selected frame into the current frame.