Skip to content

Instantly share code, notes, and snippets.

@stecman
Created June 9, 2022 23:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save stecman/9b227c6b48b1d4ff57fb979c692dfd67 to your computer and use it in GitHub Desktop.
Save stecman/9b227c6b48b1d4ff57fb979c692dfd67 to your computer and use it in GitHub Desktop.
X11 / Linux hide titlebar of a window
#!/bin/bash
# Hide the decorations of a window.
# Defaults to hiding the focused window's decorations.
# Pass -m to use the mouse to select the target window.
# Get the focused window's ID
ID_OPTION="-id $(xdotool getwindowfocus)"
while getopts 'm' flag; do
case "${flag}" in
# Passing no ID defaults to using mouse selection
m) ID_OPTION="" ;;
esac
done
xprop $ID_OPTION -format _MOTIF_WM_HINTS 32i -set _MOTIF_WM_HINTS 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment