SVG (Scalable Vector Graphics) is an open W3C standard for graphics file format and Web development language based on XML. Those images are made up of lines, curves and other “smooth” elements so when you zoom in on a SVG it stays smooth (unlike GIF, JPEG, PNG).

Imagine you can draw some of your user interface elements in a vector drawing application like: Adobe, InkScape (free) or Skencil (free) and convert your work into WPF XAML or Silverlight XAML. ViewerSVG (SVG to xaml converter) is your tool.

image

Lets look how that sweet animal transforms into xaml:

image

You can now draw your WPF shapes much more easily than in Blend. Save your shapes to SVG files, load them to ViewerSVG and export them to code. Isn’t that great? What do you say?

Tags :

8 Responses to “Convert Your Vector Graphics Image to WPF/Silverlight Code”


  1. stelt

    Said on May 28, 2008 :

    I understand that it’s great up to the moment where the SVG content is converted into a vendor lock-in format. Isn’t that just throwing away options?

  2. Shahar Y

    Said on May 28, 2008 :

    Hi stelt,

    WPF doesn’t natively render SVG content. If you want to use SVG image in your application, you can overcome this problem using this tool.
    We don’t create here a new image format (vendor lock-in format) – WPF/Silverlight exist to create applications…
    Did I answer your question? Or did I misunderstood it?

  3. Rickasaurus

    Said on May 28, 2008 :

    Ideally, this would be done on the fly by Silverlight so that you could keep your images in an open format inside your database.

    Also, all that XML bandwidth overhead is horrific.

    Do we have more options with Silverlight 2?

  4. John

    Said on May 28, 2008 :

    Xaml is not a graphics format, it’s a declarative language for applications.

  5. Ben

    Said on May 30, 2008 :

    Well I don’t understand all the nay-saying, I think that this is GREAT! Now you can save time by re-using any of your assets that you may have made for Flash in the past, since with the Awesomeness of Silverlight you will inevitably be switching ;)

  6. stelt

    Said on May 31, 2008 :

    @Shahar Y: With SVG you can create applications too. Read http://steltenpower.com/livreSVGeng.html for an update on SVG

    @Rickasaurus: Microsoft is great in making promises, not in delivering. But then you’re already locked-in …

    @John: SVG is much more than a graphics format; read http://steltenpower.com/livreSVGeng.html

    @Ben: I’m a real web person: creatively combining loads of different content and technologies. Converting is always throwing away information. That plus my other mentioned reasons is why i’ll never switch to Silverlight.

  7. Mihai

    Said on August 4, 2011 :

    I know this is waaaay late, but i just found the post. Wile all the comments have some truth to them, i think you are not thinking about all the possibilities. For instance, i now need just such a tool. I have an image that i have to color in different ways using bindings (WPF, not Silverlight#x, but it’s the same thing.) What i want to do is draw the image with a good tool, then get the XAML for that image and twick that by hand to change just the colors i need…

1 Trackback(s)

  1. Sep 6, 2009: WPF: 90+ Miejsc które warto zna? « Dawid Po?li?ski

Post a Comment