Howto wmctrl ============ https://wiki.ubuntuusers.de/wmctrl/ sudo apt-get install wmctrl Get information about program windows and workspaces: ## List of windows: wmctrl -l 0x0100000c 0 host freepad 0x0120000c 4 host openssh 0x0180000c 4 host openssh 0x0140002b 1 host wmctrl › Wiki › ubuntuusers.de — Mozilla Firefox 0x01a0000c 4 host xterm 0x01e0000c 2 host xterm 0x0240000c 3 host VIM: ~/howto.wmctrl.txt ## List of workspaces: wmctrl -d 0 - DG: N/A VP: 0,0 WA: N/A 1:tui 1 - DG: N/A VP: 0,0 WA: N/A 3:firefox 2 * DG: N/A VP: 0,0 WA: N/A 5:xterm 3 - DG: N/A VP: 0,0 WA: N/A 6:vim 4 - DG: N/A VP: 0,0 WA: N/A 10 ## Switch to a workspace: wmctrl -a freepad ## Move a window to the active workspace: wmctrl -R firefox ## Move an active windows to the second workspace: ## Counting starts at zero! wmctrl -r :ACTIVE: -t 2 ## Select a window with the mouse and maximize horizontally: wmctrl -r :SELECT: -b add,maximized_horz ## Select a window with the mouse and set position (200 px, 200 px) and size (640x480 px): wmctrl -r :SELECT: -e 0,200,200,640,480