# font fontname "Sans Serif:pixelsize=15:regular" #This is for the built-in "launch terminal" command, which is kind of redundant since it lets you bind arbitrary executable paths to keyboard/mouse shortcuts. command term "st -g 80x25 -f 'Nimbus Mono PS'" #ROOT MENU command Terminal "tabbed -c -r 2 st -w '' -f 'Nimbus Mono PS'" command Qutebrowser qutebrowser command Firefox firefox command "File Manager" pcmanfm command Calculator mate-calc command Virtualbox virtualbox command " " "" command Shutdown poweroff borderwidth 1 #Set the borders to be one pixel. The default colors are light grey for active and dark grey for inactive vtile 58 #When you invoke tiling mode, this is the percentage of the horizontal area that the main window takes up. I found this pleasing enough. Default is 50. gap 0 17 0 0 #Make room for Xmobar. bind-key 4-r "rofi -show run" #Windows-R is a habit I'll never break. This brings up Rofi, a superior clone of dmenu. bind-key M-t "st -g 80x25 -f 'Nimbus Mono PS'" #Alt-T to bring up a terminal bind-key 4-t "st -g 80x25 -f 'Nimbus Mono PS'" #Sometimes I hit Windows instead of ALT. bind-key M-r "rofi -show run" #And sometimes I hit ALT instead of Windows # Xmonad/i3wm-like bindings for showing and hiding groups (simulates multiple workspaces/desktops) # ALT-N takes you to group N, and ALT-SHIFT-N "throws" a window to that group. bind-key M-1 group-only-1 bind-key M-2 group-only-2 bind-key M-3 group-only-3 bind-key M-4 group-only-4 bind-key M-5 group-only-5 bind-key M-6 group-only-6 bind-key M-7 group-only-7 bind-key M-8 group-only-8 bind-key M-9 group-only-9 bind-key MS-1 window-movetogroup-1 bind-key MS-2 window-movetogroup-2 bind-key MS-3 window-movetogroup-3 bind-key MS-4 window-movetogroup-4 bind-key MS-5 window-movetogroup-5 bind-key MS-6 window-movetogroup-6 bind-key MS-7 window-movetogroup-7 bind-key MS-8 window-movetogroup-8 bind-key MS-9 window-movetogroup-9 #Volume control bind-key 4-q "amixer sset Master 100%" bind-key 4-a "amixer sset Master 70%" bind-key 4-z "amixer sset Master 0%" bind-key 4-e "pcmanfm" bind-key 4-Tab window-vtile bind-key C4-Tab window-htile bind-key 4-c "mate-calc" sticky yes #this just means that windows spawn in the group that's active when they're spawned. moveamount 1 #I think this is the default but I fuck with this a lot. This is how many pixels that the window moves when you use keyboard shortcuts to move it, or how many pixels are added/removed at the bottom and right if you use keyboard shortcuts to resize it. Fast mode multiplies this by ten. bind-mouse 4-1 window-move #press Windows-primary click to drag window bind-mouse 4-2 window-move #press Windows-middle click to drag window (my Lenovo Ideapad 3 has very very sloppy differentiation #between the clicker buttons--there's one physical button beneath the trackpad and it guesses which #button you meant based on your finger's position on the lower part of the pad. Normally I would map #middle click to close window, but that led to some data loss when I first got this laptop. I do recommend #the model, though, if you can get a 17-inch one with a four-core, 8-thread Core i5 and the Iris graphics. #Best laptop I've ever owned. bind-mouse 4-3 window-resize #press Windows-secondary click to resize window. Frustratingly, this wm only lets you resize the #bottom and right edges with the pointer bind-mouse M-1 window-move bind-mouse M-2 window-move bind-mouse M-3 window-resize #Same bindings but for ALT-keys. ALT-primary click is actually bound by default but for the sake of clarity #it is written out here bind-mouse CM-1 window-stick bind-mouse CM-2 window-stick #Assign a window to no/every group, so that it appears no matter which group(s) are on screen bind-mouse CM-3 window-maximize #Maximize with Control-Alt-secondary click. I don't use this much. bind-mouse MS-1 window-vtile bind-mouse MS-2 window-vtile #Snap this window to the left side of the screen, with a height of the screen minus the gap for Xmobar, and #A width of 58% of the screen, then tile all other windows in the space remaining on the right of the screen bind-mouse MS-3 window-freeze #ALT-SHIFT-3 freezes a window's geometry unbind-mouse CMS-M3 unbind key M-question unbind-key CMS-equal unbind-key CM-Delete unbind-key CMS-r #Unbind various default controls bind-key CM-Delete restart #Ctrl-ALT-Delete reinitializes the WM, causing it to reload this file if it has been altered. bind-key MS-F4 quit #Ctrl-Shift-F4 closes the window manager unbind-key CM-equal unbind-key CM-g unbind-key CM-n unbind-key CM-Return unbind-key CM-w unbind-key M-period unbind-key M-Left unbind-key M-Right #More default controls we need to unbind. ALT-Left and ALT-Right are common browser controls inter alia bind-key M-q window-close #ALT-q quits a window bind-key M-w menu-window #brings up a "search-as-you-type" menu to change to any window managed by the WM. I think I could #make Rofi do this but the default interface is inoffensive and unobtrusive. bind-key M-F4 window-close #I can't help it, some windows keybindings are seared into my soul in letters of fire. Alt-F4 closes #the active window. Note that both KDE and GNOME implement this by default. I'm hardly the only one #who grew up with a Compaq Presario running windows 95 and no friends. bind-key 4-w window-close #Also Windows-W closes windows for some reason. #These replace the ALT-left and ALT-right bindings from earlier with corresponding vim-like keys. #These cycle through non-empty groups/workspaces with Windows-H and Windows-L bind-key 4-h group-rcycle bind-key 4-l group-cycle #And while we're building on the vim-key thing, the corresponding up and down keys, also with Windows #key, maximize and minimize the active window. bind-key 4-j window-hide bind-key 4-k window-maximize #By default, ALT+vimkeys moves the window and Ctrl+ALT+vimkeys resizes it at the right and bottom. #Adding shift changes the step from MOVEAMOUNT to MOVEAMOUNT X 10. bind-key 4S-k window-fullscreen #Add Shift to Windows+K to make a window fullscreen, ignoring borders and the gap for xmobar #These move the pointer, although there's no keyboard shortcut to click. Useful I guess if your trackpad #Won't recognize your dry fingers. Ctrl-Windows+vimkeys for slow, add Shift for fast. bind-key C4-h pointer-move-left bind-key C4-l pointer-move-right bind-key C4-j pointer-move-down bind-key C4-k pointer-move-up bind-key CS4-h pointer-move-left-big bind-key CS4-l pointer-move-right-big bind-key CS4-j pointer-move-down-big bind-key CS4-k pointer move-up-big