Ubuntu – wmctrl does not resize the window


I would like to resize a web browser to a specific size.

I have been trying to resize my window (testing wmctrl) using wmctrl but somehow is does not resize it, however the position works.

I tried:

wmctrl -r Taschenrechner -e "0,300,200,800,600"

I am doing the test using ubuntu 14.04 LTS.

Any idea why is this not working? What I am missing?

Best Answer

I was just resizing my windows - wmctrl was the last command I ran!

I ran:

wmctrl -r "Ubuntu Web Browser" -e 0,0,0,1280,720

and you ran:

wmctrl -r Taschenrechner -e "0,300,200,800,600"

My suggestion would be to lose the "" around the sizes, and (maybe) add quotes to the window name:

wmctrl -r "Taschenrechner" -e 0,300,200,800,600

Just realised your program is a calculator. I doubt you can resize it - I can move mine but not shrink it or enlarge it.

This is standard with most calculator applications (and I wish it wasn't).

You said your main project is a Web Browser - it should work with that.