FloatWindow

Namespace: TheTechIdea.Beep.Winform.Controls.Docking.Runtime
Inheritance: System.Windows.Forms.Form

FloatWindow is a borderless themed form that hosts a floating DockPanel:

  • Caption drag — Uses WM_NCLBUTTONDOWN with ReleaseCapture + SendMessage for native smooth movement
  • Resize — Handles WM_NCHITTEST to provide border resize cursors
  • Edge snapping — Snaps to edges of the owner form
  • Close/double-click — Close button or double-click caption triggers re-dock via PanelRedocked event
  • ExtractHostedPanel() — Removes the hosted panel without disposing it for re-docking

Key Events

  • PanelRedocked — Raised when user re-docks the panel
  • MoveOperationEnded — Raised after native move/resize completes

AutoHideSlidePanel

Namespace: TheTechIdea.Beep.Winform.Controls.Docking.Runtime
Inheritance: System.Windows.Forms.Panel

Reveals auto-hidden panel content with animation:

  • Show(DockPanel) — Starts slide-in animation (~100 ms, 10 ms ticks)
  • Hide() — Starts slide-out animation
  • Slide direction — Determined by Edge property (Left/Right/Top/Bottom)
  • Separator grip — 5px resizable grip on the inner edge, minimum 80px extent
  • SeparatorResize event — Raised on drag completion with new dimensions

Animation Timing

// Slide animation: ~100ms total, 10ms ticks
int duration = 100;
int steps = duration / 10;  // 10 steps
// Each tick moves the panel proportionally
// Uses simple linear interpolation

AutoHideStrip

Namespace: TheTechIdea.Beep.Winform.Controls.Docking.Runtime
Inheritance: System.Windows.Forms.Panel

A slim strip along a form edge showing tab-like buttons for auto-hidden panels:

  • Each auto-hidden panel gets a button showing its title
  • Hovering a button triggers the AutoHideSlidePanel to slide out
  • Clicking activates the panel
  • Pin button in the slide panel header restores the panel to docked state

Examples

// Float a panel
manager.FloatPanel("properties",
    new Rectangle(100, 100, 300, 500));
// Panel appears in its own FloatWindow

// Auto-hide a panel
manager.AutoHidePanel("toolbox");
// Panel collapses to edge strip
// Hover to reveal slide panel

// Restore auto-hidden panel
manager.RestoreAutoHiddenPanel("toolbox");
// Panel returns to previous docked position

// Cancel float before it happens
manager.PageFloatingRequest += (s, e) =>
{
    if (e.PanelKey == "locked-panel")
        e.Cancel = true;
};