Hm, it would be cool though, if we could achieve some sort of piping system for graphical applications.
100% agree, but I think the actual number of use cases are not that many, the implementation complexity is high, and on top of that you then need buy-in from all the apps.
Would be really cool, though.
A potentially easier idea I have ruminated on is just letting apps (or better, having the OS almost force them to) expose a "current app environment state" that any other (authorized) app could read and subscribe to (in some waves hands efficient way).
Even in this example, though, you already have security concerns: do I want other apps to be able to know that my file browser is perusing the "pr0n" directory? If no, then how do we put the user in charge of that kind of thing in a way that is simple enough not to make the entire idea more trouble than it's worth?
That seems pretty specific and outside the purview of what a window manager should be doing itself.