Skip to main content

TdxContainerDockSite.CanContainerDockHost(TdxDockingType) Method

Returns a value indicating whether the container can accept other docking controls of the docking type specified.

Declaration

function CanContainerDockHost(AType: TdxDockingType): Boolean; virtual;

Parameters

Name Type
AType TdxDockingType

Returns

Type
Boolean

Remarks

The CanContainerDockHost method is used to check whether the specified docking type is supported by the container. If the method returns True, dock controls can be docked to the container in the specified manner and become the container’s children. If the method returns False, docking is prohibited or another container is created which becomes the docked control’s parent.

For instance, the CanContainerDockHost method of vertical side containers returns True if the specified dock type is either dtTop or dtBottom. This means that controls can be docked to the top or bottom edge of any control within the container. The docked control will become the container’s child. However, you can also try to dock a control to the left or right edge of a container’s child. In this case, the CanContainerDockHost method returns False. This means that another container must be created in order to accommodate the docked control. If the doSideContainerCanInSideContainer option is enabled, a horizontal side container is created to accommodate it. This and other docking options can be accessed via the Options property of the docking manager.

See Also