Apelles is a dynamic tiling window manager based on the suckless philosophy. It's a fork of dwm with additional features and customizations, focusing on simplicity, efficiency, and keyboard-driven workflow.
- Features
- Installation
- Configuration
- Layouts
- Keybindings
- Mouse Controls
- Autostart
- Scratchpads
- Window Rules
- Status Bar
- Patches and Extensions
- Customization
- Troubleshooting
- Contributing
Core features include:
- Dynamic window tiling
- Multiple layouts
- Customizable gaps between windows
- Floating window support
- Window Swallowing capability
- Scratchpad terminals
- Multi-monitor support
- Status bar with customizable colors
- .Xresources integration
- Custom window factor adjustments
- Automatic window rules
- Window cycling
- Xlib headers
- libXinerama
- libXft
- dmenu (program launcher)
- st (default terminal)
- JetBrainsMono Nerd Font
- slstatus (status bar)
- ranger (optional, for file manager scratchpad)
- make
- gcc
git clone https://github.com/ayusjayaswal/Apelles-Window-Manager.git
cd Apelles-Window-Manager
sudo make clean installMove dwm.desktop to the /usr/share/xsessions/ folder
Main configuration is done through config.def.h. Key aspects that can be configured:
- Keybindings
- Layouts
- Fonts
- Colors
- Border width
- Gap sizes
- Autostart programs
- Window rules
Create ~/.Xresources with these configurations:
! DWM Base Colors
dwm.normfgcolor: #ebdbb2
dwm.normbgcolor: #282828
dwm.normbordercolor: #282828
dwm.selfgcolor: #282828
dwm.selbgcolor: #83a598
dwm.selbordercolor: #83a598
! Layout Settings
dwm.borderpx: 2
dwm.gappx: 8
dwm.snap: 32
dwm.showbar: 1
dwm.topbar: 1
! Window Management
dwm.nmaster: 1
dwm.resizehints: 1
dwm.mfact: 0.55
! Terminal Colors (Gruvbox)
*.foreground: #ebdbb2
*.background: #282828
*.cursorColor: #ebdbb2
! Black + DarkGrey
*.color0: #282828
*.color8: #928374
! DarkRed + Red
*.color1: #cc241d
*.color9: #fb4934
! DarkGreen + Green
*.color2: #98971a
*.color10: #b8bb26
! DarkYellow + Yellow
*.color3: #d79921
*.color11: #fabd2f
! DarkBlue + Blue
*.color4: #458588
*.color12: #83a598
! DarkMagenta + Magenta
*.color5: #b16286
*.color13: #d3869b
! DarkCyan + Cyan
*.color6: #689d6a
*.color14: #8ec07c
! LightGrey + White
*.color7: #a89984
*.color15: #ebdbb2
Apply changes with:
xrdb -merge ~/.XresourcesAvailable layouts:
-
STK- Traditional tiling (master-stack)- One master window on the left, stack on the right
- Adjustable master width
-
[M]- Monocle- All windows fullscreen
- Cycle through with keybindings
-
SPR- Spiral- Windows arranged in fibonacci spiral
- Good for many windows
-
DCK- Deck- Master window with stacked windows
- Like a card deck
-
BST- Bottom stack- Master window on top
- Stack arranged horizontally below
-
GRD- Grid- Equal-sized grid arrangement
- Automatically adjusts to window count
-
NGD- N-row grid- Grid with customizable rows
- Forced vertical splits available
-
CST- Centered master- Master window in center
- Other windows on sides
-
FLT- Floating- Free window placement
- Traditional stacking window manager
MODKEY is set to the Windows key (Mod4)
MODKEY + Enter- Open terminalMODKEY + Shift + Enter- Open dmenuMODKEY + b- Toggle status barMODKEY + x- Kill focused windowMODKEY + Shift + q- Quit ApellesMODKEY + Ctrl + Shift + q- Restart Apelles
MODKEY + w- Focus next windowMODKEY + s- Focus previous windowMODKEY + Shift + w- Move window up in stackMODKEY + Shift + s- Move window down in stackMODKEY + q- Zoom/Switch to masterMODKEY + f- Toggle fullscreenMODKEY + Space- Toggle between layoutsMODKEY + Shift + Space- Toggle floatingMODKEY + Tab- Cycle through layouts forwardMODKEY + Shift + Tab- Cycle through layouts backward
MODKEY + a- Increase number of master windowsMODKEY + d- Decrease number of master windowsMODKEY + h- Decrease master area sizeMODKEY + l- Increase master area size
MODKEY + Shift + h- Increase client size horizontallyMODKEY + Shift + l- Decrease client size horizontally
MODKEY + 1-9- Switch to tag 1-9MODKEY + Shift + 1-9- Move window to tag 1-9MODKEY + Ctrl + 1-9- Toggle tag viewMODKEY + 0- View all tagsMODKEY + Shift + 0- Tag window with all tags
MODKEY + g- Toggle gapsMODKEY + Shift + g- Reset gaps to defaultMODKEY + Alt + u- Increase all gapsMODKEY + Alt + Shift + u- Decrease all gapsMODKEY + Alt + i- Increase inner gapsMODKEY + Alt + Shift + i- Decrease inner gapsMODKEY + Alt + o- Increase outer gapsMODKEY + Alt + Shift + o- Decrease outer gaps
MODKEY + comma/period- Focus previous/next monitorMODKEY + Shift + comma/period- Move window to previous/next monitor
MODKEY + c- Toggle terminal scratchpadMODKEY + v- Toggle ranger file manager scratchpad
MODKEY + Left Click- Move windowMODKEY + Right Click- Resize windowMODKEY + Middle Click- Toggle floating- Click on tag - Switch to tag
- Right click on tag - Toggle tag view
MODKEY + Clickon tag - Move window to tag- Click on layout symbol - Cycle layouts
Programs can be automatically started by adding them to the autostart array in config.h:
static const char *const autostart[] = {
"slstatus", NULL,
"nitrogen", "--restore", NULL, // Wallpaper
"picom", NULL, // Compositor
"nm-applet", NULL, // Network manager
NULL /* terminate */
};Window rules are defined in config.def.h. Example configuration:
static const Rule rules[] = {
/* class instance title tags mask isfloating isterminal noswallow monitor */
{ "Gimp", NULL, NULL, 0, 1, 0, 0, -1 },
{ "Firefox", NULL, NULL, 1 << 8, 0, 0, -1, -1 },
{ "st", NULL, NULL, 0, 0, 1, 0, -1 },
{ NULL, "spterm", NULL, SPTAG(0), 1, 1, 0, -1 },
};The status bar uses slstatus. To customize:
- Clone and build slstatus
- Configure status bar items in slstatus's config.h
- Restart Apelles
Common patches that can be applied:
- systray (system tray support)
- pertag (per-tag layout settings)
- fullgaps (advanced gap customization)
- attachaside (new windows added to stack)
- alpha (transparency support)
- vanity gaps (advanced gap settings)
- swallow (terminal window swallowing)
- cool-autostart (enhanced autostart)
- Create new layout function in
layouts.c - Add to
layouts[]array inconfig.h - Recompile
- Edit colors in
.Xresources - Run
xrdb -merge ~/.Xresources - Restart Apelles
- Modify slstatus configuration
- Recompile slstatus
- Restart status bar
Common issues and solutions:
-
Black screen after starting:
- Check .xinitrc
- Verify X server running
- Check logs in ~/.local/share/xorg/
-
No status bar:
- Verify slstatus installed
- Check autostart configuration
- Try running slstatus manually
-
Font issues:
- Install JetBrainsMono Nerd Font
- Check font configuration in config.h
- Verify Xresources loading
- Fork the repository
- Create feature branch
- Commit changes
- Push to branch
- Create Pull Request
Follow suckless coding style:
- Clear, simple code
- Minimal dependencies
- Avoid bloat
- Keep patches separate
See LICENSE file for details. Based on dwm, which is licensed under the MIT/X Consortium License.