Skip to content

Commit 872219c

Browse files
committed
Fix selection draw in empty areas when header is visible
1 parent a6d581c commit 872219c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Source/VirtualTrees.pas

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28772,6 +28772,9 @@ procedure TBaseVirtualTree.PaintTree(TargetCanvas: TCanvas; const Window: TRect;
2877228772
if DrawSelectionRect then
2877328773
begin
2877428774
R := OrderRect(FNewSelRect);
28775+
//lclheader
28776+
if hoVisible in FHeader.Options then
28777+
OffsetRect(R, 0, FHeader.Height);
2877528778
// Remap the selection rectangle to the current window of the tree.
2877628779
// Since Target has been used for other tasks BaseOffset got the left extent of the target position here.
2877728780
OffsetRect(R, -Target.X + BaseOffset - Window.Left, -Target.Y + FOffsetY);

0 commit comments

Comments
 (0)