c# and vector image files

  • Thread starter Thread starter Marc Gravell
  • Start date Start date
M

Marc Gravell

Perhaps look at WPF (part of .NET 3.0) instead - this allows most of
what you are talking about, while still dealing in managed code.

Marc
 
Ive seen on the web third party componets such as custom buttons and
guages and dashboard graphics in controls that graphicaly look realy
good.

I was wonderinghow they do thos great looking controls.

I know its possible to produce custom controls with GDI+ to draw the
gpahics, but it would seem almost impossible to draw some of the realy
complex controls ive seen.

I was wondering if c# supports any vector file formats. Can you create
a custom control using a vector file embeded into the control for
different states of the controls. Or is there a way to take a vector
file and auto generate the GDI code to reproduce it in windows form.

Im wanting to use vector files becasue it should mean the control can
be resized at will without pixelisation.

Does anyone have any thoughts ?


thanks

Peted
 
Hi,


--
Ignacio Machin
http://www.laceupsolutions.com
Mobile & warehouse Solutions.
Ive seen on the web third party componets such as custom buttons and
guages and dashboard graphics in controls that graphicaly look realy
good.

I was wonderinghow they do thos great looking controls.

A lot of work and years of expertise. :-)

Im wanting to use vector files becasue it should mean the control can
be resized at will without pixelisation.

Does anyone have any thoughts ?

you can master using GDI+, take a look at Bob Powell's website/book. It
takes a lot of work though. The easiest solution is to simply stick with a
good third party lib and use it :)
 
[...]
I was wondering if c# supports any vector file formats. Can you create
a custom control using a vector file embeded into the control for
different states of the controls. Or is there a way to take a vector
file and auto generate the GDI code to reproduce it in windows form.

C# supports the original Windows vector file format: Windows Metafile.
It has a Metafile class, derived from Image.

The newer technologies may be preferable if you can use them, but you
should be able to use a Metafile for the purpose you've described if
you have to. Of course, you can't just replace the rendition of any
random control with a metafile representation; it has to be a control
that already allows that, via setting of an Image property. That's
where the newer technologies may be more useful.

But it can be done and if you're writing a custom control from scratch,
it should be very easy (since you're writing the code to do all the
rendering anyway).

Pete
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top