Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Window is full-screen and grabs everything. New windows are appearing behind it.

I cannot just kill that application.

I'm logged in as root remotely through the SSH.

Expecting something like that:

$ xcontrol
> ls
window id: PID:   Window class:    Window name:    ...
111       1122   Vncviewer ..
222       1133    .. .            google-chrome ...
> minimize 111
> restore 111
> hide 222
> unhide 222
> move 111 by (10,-20)
> q
$
share|improve this question

2 Answers 2

up vote 6 down vote accepted

You can use wmctrl to control windows and the desktop from the command line. (If you are logging in via SSH or virtual console, you probably have to set DISPLAY to :0 first.) For instance:

## List windows
wmctrl -l
## Put the window (find window id in above list) below other windows:
wmctrl -i -r 0x04800004 -b add,below
## Remove maximization:
wmctrl -i -r 0x04800004 -b remove,maximized_horz,maximized_vert

I haven't found out how to minimize one window with wmctrl, but you can show the desktop (i.e., minimize all windows) with

wmctrl -k on
share|improve this answer
    
wmctrl finds the window, but it resists to all that commands. Does it work for, for example, OpenGL or some other enhanced windows? –  Vi. Sep 10 '10 at 14:24
1  
wmctrl is supposed to work with EWMH/NetWM compatible X window managers. The web page lists WMs known to work. Which WM are you using? –  bhm Sep 10 '10 at 18:26
    
inconify feature for wmctrl is comming in a future release. the author added a -Y flag for that (commited in github). –  Marc MAURICE Aug 15 '13 at 20:46

Maybe xdotool can help you.

share|improve this answer
    
Yes! see askubuntu.com/questions/4876/… –  Marc MAURICE Aug 15 '13 at 20:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.