Show: Delphi C++
Display Preferences

Vcl.Controls.TControl.ReplaceDockedControl

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function ReplaceDockedControl(Control: TControl; NewDockSite: TWinControl;  DropControl: TControl; ControlSide: TAlign): Boolean;

C++

bool __fastcall ReplaceDockedControl(TControl* Control, TWinControl* NewDockSite, TControl* DropControl, TAlign ControlSide);

Properties

Type Visibility Source Unit Parent
function public
Vcl.Controls.pas
Vcl.Controls.hpp
Vcl.Controls TControl

Description

Docks the control in the place where another control is already docked.

Call ReplaceDockedControl to replace a control that is already docked while moving that control to another dock site.

Control is the control whose place this control is taking.

NewDockSite is the new dock site for the control that is replaced.

DropControl is a control in the new dock site on which to drop the control that is replaced. For example, if NewDockSite were a page control, DropControl would be a tab sheet.

ControlSide specifies on which side of DropControl or NewDockSite (if DropControl is nil (Delphi) or NULL (C++)) the replaced control should be docked. This value can be obtained by calling the dock site's GetDockEdge method.

ReplaceDockedControl does the same thing as calling the ManualDock method of the control specified by the Control parameter (using the values of NewDockSite, DropControl, and ControlSide) in addition to calling ManualDock for the control whose method this is, docking it in the current position of the Control parameter. However, calling ReplaceDockedControl is more efficient, and prevents unnecessary flicker.

See Also

Personal tools
In Other Languages
Previous Versions
Assistance