Lcl/DrawText: Fix #40324: return value set to the height

This commit is contained in:
rich2014 2023-06-24 15:41:04 +08:00
parent 4ddf892b29
commit 05555c84d5

View File

@ -681,6 +681,8 @@ begin
{Calculate the text's bounding rect}
CalcTextRect;
Result:=theRect.Height;
{If just calculating rect, finish up here}
If CalcRect then begin
Rect:=theRect;
@ -766,8 +768,6 @@ begin
{Restore device-context}
RestoreDC(DC, TDC);
Result := 1;
end;
function TWidgetSet.DPtoLP(DC: HDC; var Points; Count: Integer): BOOL;