which process display a given window?

Bryn M. Reeves bmr at redhat.com
Tue Aug 2 11:34:34 UTC 2011


On 08/01/2011 11:39 AM, Frantisek Hanzlik wrote:
> How generally I can state which process display it?
> I would expect, when right-clicking on window top title bar, some
> item as e.g. "window properties" - where would be possible find info
> about process displaying this window. But there isn't nothing of the
> kind. Thus, is there other way discovering this?
> 
> I forgot mention, I'm now in F15 using XFCE (but IMO in Gnome window
> manager has not capability too).

In f15 the gnome and xfce window managers both seem to set a window manager hint
that includes the process ID so you can probably get this by running xwininfo
and clicking the suspect window:

$ xwininfo -wm

xwininfo: Please select the window about which you
          would like information by clicking the
          mouse in that window.

xwininfo: Window id: 0x2200005 "bmr at bmr:~"

  Window manager hints:
      Client accepts input or input focus: Yes
      Initial state is Normal State
      Displayed on desktop 0
      Window type:
          Normal
      Process id: 2157 on host bmr.fab.redhat.com
      Frame extents: 1, 1, 28, 2

$ pga 2157
 2157 ?        Sl     0:05 gnome-terminal
24640 pts/0    S+     0:00 grep --color=auto 2157

Regards,
Bryn.


More information about the users mailing list