ブラウザWM_NAMEの変更をリアルタイムで監視する方法

ブラウザWM_NAMEの変更をリアルタイムで監視する方法

ブラウザのWM_NAME(google-chromeと仮定)がリアルタイムでどのように変更されるかを確認する必要があります。

どうすればいいですか?

ベストアンサー1

WM_CLASSは決して変更されません。常に同じです。捕まえようとしているようですVISIBLE_NAME

これは次の方法で行うことができます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監視するターゲットウィンドウのウィンドウID。

おすすめ記事