[Lazarus] Return of Frame3D issue
patspiper
patspiper at gmail.com
Mon Apr 30 23:31:03 CEST 2012
On 30/04/12 23:15, Frank Church wrote:
>
> In upgrading to Lazarus 1.1 and issue I first came across in this
> thread has returned. I think I decided not to use the controls in
> 0.9.31 but I want to consider them again in Lazarus 1.1,
> http://lists.lazarus.freepascal.org/pipermail/lazarus/2011-August/065582.html.
>
> There is also a mantis issue for it -
> http://bugs.freepascal.org/view.php?id=8328.
>
> In 0.9.30 it is defined in lclintf.h as
>
> function Frame3d(DC: HDC; var ARect: TRect; const FrameWidth :
> integer; const Style : TGraphicsBevelCut): Boolean; {$IFDEF
> IF_BASE_MEMBER}virtual;{$ENDIF} and is also in the Graphics unit as
> procedure Frame3d(var ARect: TRect; const FrameWidth: integer;
> const Style: TGraphicsBevelCut); virtual;
>
> The control I am working with, TJanPanelButton uses the signature in
> lclintfh.inc calling it as Frame3d( Self.Canvas.Handle, R,
> FFrameWidth, bvRaised );
>
> Juha Mahinnen added a patch to Extctrls to match the Delphi
> implementation here -
> http://docwiki.embarcadero.com/Libraries/en/Vcl.ExtCtrls.Frame3D.
> Although it matches the Delphi definition is it in the wrong place as
> it affects the apparently original Lazarus implementation?
>
> In the mean time I have to ifdef it and call Self.Canvas.Frame3D(R,
> FFrameWidth, bvRaised ) instead of Frame3d( Self.Canvas.Handle, R,
> FFrameWidth, bvRaised ) which matches the definition of TCanvas in
> Graphics. Is that any good?
If you want to use
Frame3d(DC: HDC; var ARect: TRect; const FrameWidth : integer; const
Style : TGraphicsBevelCut): Boolean
then you must add LCLIntf to your uses clause, and even qualify it:
LCLIntf.Frame3D(R, FFrameWidth, bvRaised).
Stephano
More information about the Lazarus
mailing list