[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Controls' (#lcl)

# TDockTree

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

A tree of TDockZone instances where each docked window has one tree.

## Declaration

Source position: controls.pp line 2611

`type TDockTree = class(TDockManager)`
`protected`
`FRootZone: TDockZone;` |  | The root zone for the DockTree.
`function HitTest(); virtual;` |  | Returns the control and the part of the dockzone at the given coordinates.
`procedure PaintDockFrame(); virtual;` |  | Paints the dock header of the zone containing AControl.
`procedure UpdateAll;` |  | Updates the internal TDockTreeFlags to reflect the update status for the control
`procedure SetDockZoneClass();` |  | The class type for the dock zones in this tree.
`public`
`constructor Create(); override;` |  | Constructor for the class instance.
`destructor Destroy; override;` |  | Destructor for the class instance.
`procedure BeginUpdate; override;` |  | Starts an update process for the class instance.
`procedure EndUpdate; override;` |  | Finishes an update process for the class instance.
`procedure AdjustDockRect(); virtual;` |  | Adjusts the zone rectangle for AControl.
`procedure GetControlBounds(); override;` |  | Returns the zone bounds of a docked control.
`procedure InsertControl(); override;` |  | Positions DropCtl relative Control, using the alignment specified by InsertAt.
`procedure LoadFromStream(); override;` |  | Has an empty implementation in TDockTree.
`procedure MessageHandler(); override;` |  | Has an empty implementation in TDockTree.
`procedure PositionDockRect(); override;` |  | Determines the DockRect while dragging a control over the docksite.
`procedure RemoveControl(); override;` |  | Removes the undocked control from the docksite layout.
`procedure SaveToStream(); override;` |  | Saves the docksite layout to Stream.
`procedure SetReplacingControl(); override;` |  | Specifies the control to be replaced subsequently.
`procedure ResetBounds(); override;` |  | Refreshes the layout for the dock site.
`procedure PaintSite(); override;` |  | Handles special painting of the docksite.
`procedure DumpLayout(); virtual;` |  | Stores the layout in a file.
`property DockZoneClass: TDockZoneClass; [r]` |  | The class type for the dock zones in this tree.
`property DockSite: TWinControl; [rw]` |  | The parent control whose docked clients are managed.
`property RootZone: TDockZone; [r]` |  | The root zone for the DockTree.
`end;`

## Inheritance

`TDockTree` |  | A tree of TDockZone instances where each docked window has one tree.
`TDockManager` |  | The layout manager for a docksite.
`TPersistent`
?
`TObject`

## Description

TDockTree is a TDockManager descendant with a simple docking manager that allows docking a control into another using Align=alClient to fill the whole client area.

In this class, Docking means: Combining several windows into one. And, a window can be a TCustomForm instance, a floating (undocked) control, or a TDockForm instance. A window can be docked to another to the left, right, top, bottom, or "into". The source docking window will be resized to fit to the target docking window.

A docking manager supporting multiple controls per docksite (aka a layout) can be found in the ldocktree.pas unit.

TAnchorDockManager which supports multiple controls with a more flexible layout, store and restore, and more options can be found in the anchordocking package.

## See also

TDockManager |  | The layout manager for a docksite.
TLazDockTree |  | Implements a docking manager using a simple layout.