Xfce Forum

Sub domains
 

You are not logged in.

#1 2012-09-22 09:31:34

giancarlogiesa
Member
Registered: 2012-09-22
Posts: 4

[solved] how get the PID of the windows on top?

Hello,

how can i get the PID or the ID Window from the terminal of the windows that is on top or that have the focus?

sincerely, Giancarlo

Last edited by giancarlogiesa (2012-09-22 13:16:04)

Offline

#2 2012-09-22 11:29:02

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,488

Re: [solved] how get the PID of the windows on top?

You can use the xdotool utility to get the pid of the active window like this:

xdotool getactivewindow getwindowpid

or the currently focused window like this:

xdotool getwindowfocus getwindowpid

Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#3 2012-09-22 13:15:48

giancarlogiesa
Member
Registered: 2012-09-22
Posts: 4

Re: [solved] how get the PID of the windows on top?

thank you very much!

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.007 seconds, 7 queries executed - Memory usage: 522.58 KiB (Peak: 531.17 KiB) ]