[Lazarus] Would like to help, but....
Mattias Gaertner
nc-gaertnma at netcologne.de
Wed Jul 22 19:22:03 CEST 2009
On Wed, 22 Jul 2009 09:21:04 -0700 (PDT)
Samuel Herzog <sam_herzog at yahoo.com> wrote:
> I like to help in fixing issues.
>
> But with this one I am not sure if it makes sense to do this, and if
> yes, then what would be the best way.
>
> http://bugs.freepascal.org/view.php?id=13961
>
> Paul has already answered, but I am still not happy with the current
> situation.
>
> TCustomLabel = class(TGraphicControl)
> TCustomSpeedButton = class(TGraphicControl)
>
> Someone has implemented already the Autosize mechanism for
> TCustomLabel.
I don't see why do you mention TLabel here.
TLabel is more simple than TSpeedButton and allows Wordwrap and
OptimalFill. So the AutoSize algorithm will be completely
different.
> What do you suggest to do ?
> Create a class TCustomGraphicControl with AutoSize support and then
> inherit TCustomLabel and TCustomSpeedButton from this new class ?
What is the gain?
Why not simply implement procedure
TCustomSpeedButton.CalculatePreferredSize?
Mattias
More information about the Lazarus
mailing list