Float Groups

  • 2 minutes to read


A Float Group (a FloatGroup object) is a kind of floating window displaying a dock panel, groups of dock panels or a DocumentPanel in the floating state. The following image shows a Float Group containing two layout panels:


When a panel/DocumentPanel is about to become floating, a Float Group is automatically created and the panel is added to this group. Docking a floating panel destroys the Float Group.

Float groups can be moved within the boundaries of a window or a desktop. This feature is controlled by the DockLayoutManager.FloatingMode option.

Floating panels display their image and caption in the Windows Taskbar preview. Use the FloatGroup.WindowTaskbarTitle and FloatGroup.WindowTaskbarIcon attached properties to specify a different caption and image.

Child Items

The following objects can be children of a Float Group:

You can add multiple child objects to a Float Group. In this instance, the Float Group’s children will be arranged side by side.

To create a floating panel in XAML, you need to:

  1. Add a FloatGroup object to the DockLayoutManager.FloatGroups collection. This collection contains all Float Groups, so it allows you to access all floating panels.
  2. Add a dock object(s) (for instance, a LayoutPanel object(s)) to the created FloatGroup.
  3. Set the size for the created FloatGroup object, via the BaseLayoutItem.FloatSize property.
  4. Set the position for the created FloatGroup object, via the FloatGroup.FloatLocation property.

In code, a panel can be made floating via the DockController.Float method of the DockLayoutManager.DockController object.

Dock Operations

To prevent a panel from being made floating, use the BaseLayoutItem.AllowFloat option. You can create a floating panel and then prevent it from being docked via the BaseLayoutItem.AllowDock option.

To make a panel floating in code, use the DockController.Float method of the DockLayoutManager.DockController object.

The DockLayoutManager.DockItemStartDocking, DockLayoutManager.DockItemDocking and DockLayoutManager.DockItemEndDocking events allow dock operations to be dynamically controlled.


How to create floating panels in XAML

See Also