Geometry Nodes: UV unwrap

I'm trying to find a good way to UV unwrap procedural created meshes. Windows for instance, but I just can find the right way. Hopefully someone can help me?

I've already read a lot of discussions about manually UV unwrapping meshes created by extruding curve profiles along a path by capturing the vectors of the curves before creating a mesh with "Capture Attribute" and store them in a attribute "UVMap".
I'm able to create index or factor/length based face corners in the Vector domain, but these face corners are rectangular shaped, because as far as I can understand it just combines a single curve length (the length between 2 control points) of the profile curve (U) and the path curve (V) with eachother and it doesn't take into account that the created faces on the inside of the path are smaller then on the outside of the path and the quad faces are not particular rectangular. The result is stretched UV's.

Why so difficult when there is also a worked out solution: UV Unwrap node? Well the UV Unwrap node works initially fine, but when I change the dimensions of the curve profile, the UV islands don't stay in place. The islands gets even rotated and I can't control it. This probably happens because of the implemented "Pack Islands".

So therefore I prefer to manual unwrap so I have full control of the UV unwrapping. Is it possible to project the faces of the gernerated mesh to a UV and sort them in a certain order, comparable with the capture attribute solution? This way the shape of the face stays when converted to UV's, like with the UV unwrap node.

I was thinking of something like:

Set Positon node to set all vertices based on (the center of) the faces to $$(0,0,0)$$ and arrange them by offset each face by the length of the curve profile and project them om the Z axis by using the Align Euler to Vector node with a normal set to $$(0,0,1)$$. But I haven't managed this yet to get this working.

I will try later to upload some images to clarify my case.

Big thanks in advance for any help.

Cheers, M3D