I am trying to create a rule-based style based on geometries from another layer.
I have found an example that does exactly what I want, except that it uses a geometry from WKT:
intersects( $geometry, geomFromWKT( 'POLYGON' ) )
What I want to do is exactly the same thing, but with the second geometry based on a different layer rather than WKT. As an example, I want to theme roads in black if they intersect a polygon layer, and grey if they do not. Is this possible?