4

I need to check how the browser's WM_NAME (let's say google-chrome) is changing in real time.

How can I do that ?

1 Answers1

3

WM_CLASS is never changing. It's always the same. I think you're trying to catch the VISIBLE_NAME.

That can be done with xprop:

xprop -spy -id 0x01a00092 _NET_WM_VISIBLE_NAME
_NET_WM_VISIBLE_NAME(UTF8_STRING) = "x11 - How can I monitor in real time the changes to the browsers WM_CLASS - Unix & Linux Stack Exchange ::: http://unix.stackexchange.com/questions/349872/how-can-i-monitor-in-real-time-the-changes-to-the-browsers-wm-class - Pale Moon"
_NET_WM_VISIBLE_NAME(UTF8_STRING) = "Newest Unanswered Questions - Unix & Linux Stack Exchange ::: http://unix.stackexchange.com/unanswered/tagged/?tab=newest - Pale Moon"
_NET_WM_VISIBLE_NAME(UTF8_STRING) = "x11 - How can I monitor in real time the changes to the browsers WM_CLASS - Unix & Linux Stack Exchange ::: http://unix.stackexchange.com/questions/349872/how-can-i-monitor-in-real-time-the-changes-to-the-browsers-wm-class - Pale Moon"

-id xxx is the window id of the target window you want to monitor.

Ipor Sircer
  • 14,376
  • 1
  • 27
  • 34