Question

I have an existing Windows icon (.ico) file, that I would like to use in a WPF application. Are there any good tools for converting an .ico icon to an XAML Path Geometry?

Was it helpful?

Solution

XAML Paths are a vector format and ICOs are bitmaps, so a simple conversion isn't possible.

You could try to open the ICO in a vector software like Inkscape, outline it with Paths then export it as XAML.

If the path is not a requirement, you can also use the .ico in the WPF application directly: simply set it as an Image's Source.

<Image Source="test.ico"/>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top