On 19.07.2012 18:18, Michael Hauser wrote:
> Vincent Bernat wrote:
>>  ❦ 19 juillet 2012 16:36 CEST, Andre Klärner <[email protected]> :
>>
>> You could take a virtual console (Ctrl-Alt-F1) and take the screenshot
>> from here:
>>
>>  $ DISPLAY=:0 scrot
> 
> Pressing the Alt key would close the menu.
> 
> Perhaps someone can explain why and how a Net/Notebook's Powerbutton is
> wired other than the keyboard. I don't know enough about this special
> keys.

Welcome to input handling. When you press any button, the kernel gets this
event. The kernel then passes this on to whoever cares in userspace.

Normally, this is the X11 server. However, power buttons are likely handled by
acpid and thus independent from the server. So the only remaining question
should be "Why can't we do anything in X11?".

> Another idea that could work is mapping a seldom used mouse button (eg.
> Mouse Wheel Right) to make the screenshot.

This won't work for the same reason that a keybinding didnt work and why
pressing alt presses the menu. When a menu opens, GTK grabs all input. This
means that the X11 server will only send input events to this GTK app and no
window manager or anything else can grab keys.

Uli

-- 
"In the beginning the Universe was created. This has made a lot of
 people very angry and has been widely regarded as a bad move."

-- 
To unsubscribe, send mail to [email protected].

Reply via email to