Click here to Skip to main content
15,936,337 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
I want to create a vector graphics software like CorelDraw or Inkscape in C# or VB.NET using windows forms. How do I start? Should I first draw the whole project cycle and then build the base libraries for the graphics tools? I don't want to build the menus by code but with the designer. Please help me.
Updated 13-Mar-12 15:33pm
ZurdoDev 13-Mar-12 11:09am    
That is a loaded question. You'll start in Visual Studio with a new windows forms project but there is a ton more after that. What specifically are you stuck on?
Sergey Alexandrovich Kryukov 13-Mar-12 19:27pm    
No, this is a typical problems best solved with WPF.
Sergey Alexandrovich Kryukov 13-Mar-12 19:39pm    
By the way, I just put my answer with essential overview of a plan and advice for such work. Please see.
Sergey Alexandrovich Kryukov 13-Mar-12 21:34pm    
Fixed number of spelling and punctuation mistakes. Also, there is not such language as C#.NET. And I think this is about Inkscape, not Inkspace (what is it?).
Sergey Alexandrovich Kryukov 13-Mar-12 21:38pm    
By the way "I don't want to build the menus by code but with the designer" is ridiculous. This piece of functionality is so insignificant compared to the whole project that I suspect that your idea of this project is way too ambitious compared to your skills. (I would be glad to learn that I was wrong, so don't think I'm trying to discourage you; it's just a little warning about complexity of the project.)

You can use Designer, but you could be surprised to know how little is the use of Designers in all serious projects, compared to "real" code. Designers are more created for quick-and-dirty work, beginners, small projects, etc. And this type of project just has to be very serious. Just think about it.


1 solution

Very, very big project. I can only give you some starting ideas.

Use WPF. For the graphics building surface, use the class System.Windows.Controls.Canvas, for the elements places on this surface, you will use the objects of the type System.Windows.UIElement.

Please see:[^],[^].

All the required events, zoom and pan operations are pretty much already developed for your. One hint: use System.Windows.Controls.Viewbox, System.Windows.Controls.ScrollViewer.[^],[^],[^].

The primary data format for the vector graphics created with your editor would be XAML. Most likely, you will need to develop export methods to other vector formats, first of all, to Scalable Vector Graphics (SVG). Please see:[^],[^],[^].

You should understand that XAML expressive capabilities are narrower than that of SVG. For example, blurring is not supported (to best of my knowledge). So, you need to be careful if you also need import (which would be good).

Most likely, you will also need export to pixel graphics format, which is relatively easy.


Please also see my past answer to a related question:
Connect different controls[^].

Share this answer
RaisKazi 13-Mar-12 20:14pm    
My 5.
Sergey Alexandrovich Kryukov 13-Mar-12 20:36pm    
Thank you Rais.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900