PathGeometry doesn't render when references a resource
Posted: 20 Jun 2023, 03:05
In WPF both examples render fine, but in NoesisGUI (with Unreal), the last one produces:
Setting Figures through a resource:
Settings Figures directly:Cannot convert 'M 1888.2001 1.915677 V 1001.9211 l -24.8263 43.0005 h -392.9762 l -65.2936 29.7968 h 486.7515 L 1920 1025.9707 V 1.915677 Z' into a 'PathFigureCollection' object
Code: Select all
<Path Fill="White" StrokeThickness="0.264583">
<Path.Data>
<PathGeometry Figures="M 1888.2001 1.915677 V 1001.9211 l -24.8263 43.0005 h -392.9762 l -65.2936 29.7968 h 486.7515 L 1920 1025.9707 V 1.915677 Z" FillRule="NonZero"/>
</Path.Data>
</Path>
Code: Select all
<ResourceDictionary>
<PathFigureCollection x:Key="Path.FrameRight">
M 1888.2001 1.915677 V 1001.9211 l -24.8263 43.0005 h -392.9762 l -65.2936 29.7968 h 486.7515 L 1920 1025.9707 V 1.915677 Z
</PathFigureCollection>
</ResourceDictionary>
<Path Fill="White" StrokeThickness="0.264583">
<Path.Data>
<PathGeometry Figures="{StaticResource Path.FrameRight}" FillRule="NonZero"/>
</Path.Data>
</Path>