Trigger: When Window with title containing exists?

I have an app that pops up a window in the background without activating the app. (hence can't use the application active trigger) (cannot use application running trigger as app is always running. firewall app)

I am trying to figure out a way to use that app opening up a window with title "xyz" in background as a trigger for a macro.

Basically it would be pretty awesome if there's a trigger like: when window with title "xyz" opens.

Thanks in anticipation

It's probably not practical to track all the windows in all running applications I'm afraid.

You may well be able to use AppleScript and Accessibility APIs to determine when the specific application has the window open, but there wont be any way to trigger on that happening so other than polling for it (which is never a good idea) I don't see a good solution to this I'm afraid.