On Sat, 4 Mar 2006 08:34:26 +0100
Micha Nelissen <[EMAIL PROTECTED]> wrote:

> On Sat, 4 Mar 2006 08:06:24 +0100
> Micha Nelissen <[EMAIL PROTECTED]> wrote:
> 
> > On Sat, 4 Mar 2006 02:06:46 +0100
> > Mattias Gaertner <[EMAIL PROTECTED]> wrote:
> > 
> > > If 'red' buttons are needed that often, then we should add a
> > > TCustomDrawnButton (or whatever name fits) with properties like Color,
> > 
> > TSpeedButton ?

Yes, that's indeed a better ancestor for custom drawn buttons.

 
> I mean we're getting a lot of buttons this way, with mostly redundant
> (duplicate) code ... :-/

They would be put even in the same unit. I'm sure, we can share the code.
What about this:
TSpeedButton is already painted by the LCL. If the Color property is not the
default, it can switch to custom drawing (Lines instead of
Frame3D/DrawFrameControl). Then we can also add properties BorderWidth,
Margin, gradient, or whatever is desired.
And those who want a 'red' button, we can tell to use a TSpeedButton
instead.
Then the widgetsets need less to fiddle overriding theme properties and
programmers get 'special' looking buttons.
 A programmer, who wants a 'red' button, does not care about the theme of
the button anyway.


Mattias


_________________________________________________________________
     To unsubscribe: mail [EMAIL PROTECTED] with
                "unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to