Advertisement
bpranoto

Untitled

Jul 21st, 2024
13
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | Source Code | 0 0
  1. procedure TForm1.VTDrawText(Sender: TBaseVirtualTree; TargetCanvas: TCanvas;
  2. Node: PVirtualNode; Column: TColumnIndex; const CellText: String;
  3. const CellRect: TRect; var DefaultDraw: Boolean);
  4. var
  5. ActualClientRect,DisplayRect:TRect;
  6. begin
  7. ActualClientRect:=Sender.GetDisplayRect(Node,0,True);
  8. DisplayRect:=Sender.ClientRect;
  9. //
  10.  
  11. if (ActualClientRect.Bottom>=DisplayRect.Bottom)
  12. or not Assigned(Node^.NextSibling)
  13. then begin
  14.  
  15. // Display Footer in the panel1
  16. if Column=0 then begin
  17. Self.Panel1.Canvas.Clear;
  18. end;
  19. Self.Panel1.Canvas.TextOut(CellRect.Left,3,'Footer ' + IntToStr(Column));
  20.  
  21. end;
  22. end;
  23.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement