mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-05 21:38:27 +02:00
lcl: TSpeedButton: implemented AutoSize=true
git-svn-id: trunk@34398 -
This commit is contained in:
parent
b8da5fdca9
commit
774703c6a9
@ -301,6 +301,8 @@ type
|
||||
function GetNumGlyphs: Integer;
|
||||
procedure GlyphChanged(Sender: TObject);
|
||||
function DialogChar(var Message: TLMKey): boolean; override;
|
||||
procedure CalculatePreferredSize(var PreferredWidth,
|
||||
PreferredHeight: integer; WithThemeSpace: Boolean); override;
|
||||
procedure MeasureDraw(Draw: boolean; PaintRect: TRect;
|
||||
out PreferredWidth, PreferredHeight: integer);
|
||||
procedure MouseEnter; override;
|
||||
|
@ -490,6 +490,15 @@ begin
|
||||
Result := inherited DialogChar(Message);
|
||||
end;
|
||||
|
||||
procedure TCustomSpeedButton.CalculatePreferredSize(var PreferredWidth,
|
||||
PreferredHeight: integer; WithThemeSpace: Boolean);
|
||||
var
|
||||
r: TRect;
|
||||
begin
|
||||
r:=Rect(0,0,0,0);
|
||||
MeasureDraw(false,r,PreferredWidth,PreferredHeight);
|
||||
end;
|
||||
|
||||
procedure TCustomSpeedButton.MeasureDraw(Draw: boolean;
|
||||
PaintRect: TRect; out PreferredWidth, PreferredHeight: integer);
|
||||
var
|
||||
|
Loading…
Reference in New Issue
Block a user