AB4D Forum
Ellipse, spiral drawn with Inkscape are not shown. - Printable Version

+- AB4D Forum (https://forum.ab4d.com)
+-- Forum: Products Forums (https://forum.ab4d.com/forumdisplay.php?fid=4)
+--- Forum: Paste2Xaml and Ab2d.ReaderWmf (https://forum.ab4d.com/forumdisplay.php?fid=7)
+--- Thread: Ellipse, spiral drawn with Inkscape are not shown. (/showthread.php?tid=4015)



Ellipse, spiral drawn with Inkscape are not shown. - m246246 - 06-14-2017

Attatchd emf (sss.emf) is made by Inkscape 0.92, in which I draw 1 ellipse and 1 spiral. You can see red ellipse and olive spiral in Paint and other applcations. However nothings are shown on screen from the rendered result from ReadGeometry().

When I see the contents via GetXaml(), it look as the following:

<!-- Converted from metafile with Ab2d.ReaderWmf. See www.ab4d.com for more WPF and Silverlight tools. -->
<Image xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Stretch="Uniform">
    <Image.Resources>
    </Image.Resources>
    <Image.Source>
        <DrawingImage xmlns:PresentationOptions="http://schemas.microsoft.com/winfx/2006/xaml/presentation/options" PresentationOptions:Freeze="True">
            <DrawingImage.Drawing>
                <DrawingGroup>
                    <GeometryDrawing Geometry="F1M323,133z">
                        <GeometryDrawing.Pen>
                            <Pen Brush="Red" Thickness="3" StartLineCap="Flat" EndLineCap="Flat" DashCap="Flat" LineJoin="Miter" MiterLimit="10"/>
                        </GeometryDrawing.Pen>
                    </GeometryDrawing>
                    <GeometryDrawing Geometry="F1M508,133">
                        <GeometryDrawing.Pen>
                            <Pen Brush="Olive" Thickness="3" StartLineCap="Flat" EndLineCap="Flat" DashCap="Flat" LineJoin="Miter" MiterLimit="10"/>
                        </GeometryDrawing.Pen>
                    </GeometryDrawing>
                </DrawingGroup>
            </DrawingImage.Drawing>
        </DrawingImage>
    </Image.Source>
</Image>

I'm not sure but it looks value of the Geometry property is too short. (The version of ReaderWmf is 7.2.5960.1045.)

Best Wishes,


RE: Ellipse, spiral drawn with Inkscape are not shown. - abenedik - 06-14-2017

I have checked your file and found out that ReaderWmf do not support EMR_POLYBEZIERTO element that is used by your file (it supports EMR_POLYBEZIERTO16 and EMR_POLYBEZIER16 elements).

I will add support for that next week (this week I am on a short vacation) and will send you a fixed version.