Resizing a window to a set size in Linux

Use the wmctrl command:

To list the windows:

$ wmctrl -l
0x00c00003 -1 rgamble-desktop Bottom Expanded Edge Panel
0x00c00031 -1 rgamble-desktop Top Expanded Edge Panel
0x00e00022 -1 rgamble-desktop Desktop
0x0260007c  0 rgamble-desktop Google - Mozilla Firefox

To resize a window based on its title:

wmctrl -r Firefox -e 0,0,0,640,480

The arguments to the resize option are gravity,X,Y,width,height so this will place the window at the top-left corner of the screen and resize it to 640X480.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)