mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 22:56:06 +02:00
VirtualTreeView: Fix "no parent window" error when VTV is in a high-dpi frame (issue #39362).
This commit is contained in:
parent
19b127a2b1
commit
eaea82f052
@ -26303,7 +26303,7 @@ procedure TBaseVirtualTree.AutoScale();
|
|||||||
var
|
var
|
||||||
lTextHeight: Cardinal;
|
lTextHeight: Cardinal;
|
||||||
begin
|
begin
|
||||||
if (toAutoChangeScale in TreeOptions.AutoOptions) then
|
if HandleAllocated and (toAutoChangeScale in TreeOptions.AutoOptions) then
|
||||||
begin
|
begin
|
||||||
Canvas.Font.Assign(Self.Font);
|
Canvas.Font.Assign(Self.Font);
|
||||||
lTextHeight := Canvas.TextHeight('Tg');
|
lTextHeight := Canvas.TextHeight('Tg');
|
||||||
|
Loading…
Reference in New Issue
Block a user