Re: property exists (OnPaint followup)
Chris Anderson <[email protected]>
| Newsgroups | gmane.comp.windows.devel.dotnet.winforms |
|---|---|
| Message-ID | <[email protected]> |
Wow, that is whack. I can understand a little why they have a separate Appearance property...but if it were me I'd at least mirror the Control.BackColor <sarcasm>Great advert for Infragistics! </sarcasm> Yeah, if there's a separate base class (which probably inherits from Control FWIW) and that base class exposes Appearance, that would be the way to do it. (You can use ILDasm or Reflector to find out) If not, and each control just inherits directly from Control (and so you would have to list all the possible Infragistic control types in your code,) then you may need to use Reflection to check if it has an Appearance property, and access it, etc - but that will be much slower! > -----Original Message----- > From: Discussion forum for developers using Windows Forms to build apps > and controls [mailto:[email protected]] On Behalf Of > Peter Osucha > Sent: 23 May 2007 19:46 > To: [email protected] > Subject: Re: [DOTNET-WINFORMS] property exists (OnPaint followup) > > Chris, > > I probably wasn't clear. The Infragistics controls do, of course, > inherit from System.Windows.Forms.Control. I can access the .BackColor > just fine. The problem is that the Infragistics people really want you > to use there Appearance.BackColor instead of just the BackColor. They > want you to use it so much in fact that if I set the > Appearance.BackColor to something (eg, transparent), BackColor does not > get set to transparent (it seems the developers dropped the ball). I > can't set the BackColor of the control, I can only set the > Appearance.BackColor. And since they don't update the BackColor for > the > control when I change the Appearance.BackColor, then I need to be able > to retrieve the Appearance.BackColor. > > I guess I can look for info on a InfragisticsControlBaseClass - the > support group doesn't seem that knowledgable though when it comes to > this stuff. > > Peter >