Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / Design Time / October 2005

Tip: Looking for answers? Try searching our database.

How to provide design-time support for LinearGradientBrush type?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Marcin Rzeznicki - 08 Oct 2005 14:18 GMT
Hello,
I am writing control which exposes design-time browsable property for
setting gradient background of type LinearGradientBrush. I wanted to
provide design-time support for creating brushes. Having delved into
that topic it seemed to me that creating my own UITypeEditor showing
modal form was the best way to achieve my goal. So I did. Everything
worked fine till I realized that brush produced by my editor was not
serialized into code. After quite long and unfruitfull search I do not
see any way to do the serialization. I would like to implement code
serializer (due to complicated setup of LinearGradientBrush it seems to
me that it is impossible to achieve serialization by InstaceDescriptor
way), yet I cannot attach it to LinearGradientBrush type as the
attribute is of class level. Is there any way out of this maze? I 'd
really appreciate any help, thank you in advance
Frank Hileman - 08 Oct 2005 18:06 GMT
That class is not designed to be serialized. You will need to create your
own class, as we did with VG.net.

Regards,
Frank Hileman

check out VG.net: http://www.vgdotnet.com
Animated vector graphics system
Integrated Visual Studio .NET graphics editor

> Hello,
> I am writing control which exposes design-time browsable property for
[quoted text clipped - 10 lines]
> attribute is of class level. Is there any way out of this maze? I 'd
> really appreciate any help, thank you in advance
Marcin Rzeznicki - 08 Oct 2005 23:15 GMT
Frank Hileman napisal(a):
> That class is not designed to be serialized. You will need to create your
> own class, as we did with VG.net.

Thank you.
Is the case of XmlNode the same? I'd like to be able to edit some xml
files in desig-time, yet inspection of docs shows that XmlNode does not
implement ISerializable.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.