/syncfusion-winforms:syncfusion-winforms-layout-managersfrom Syncfusion WinForms Controls
Guide for implementing Syncfusion layout managers in Windows Forms applications. Use when creating container layouts with BorderLayout (5-region docking), CardLayout (wizards/property pages), FlowLayout (horizontal/vertical flow), GridLayout (uniform grids), or GridBagLayout (flexible grids with spanning). Covers container controls, child control management, spacing configuration (HGap, VGap), positioning constraints, and designer integration for automatic control arrangement and structured layouts.
Ships in Syncfusion WinForms Controls. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The LayoutManagers Package provides five specialized layout managers that automatically arrange child controls within container controls (Panel, Form, etc.) based on specific layout strategies. These managers eliminate manual positioning and provide professional, maintainable layouts.
Use this skill when the user needs to:
The LayoutManagers Package (Syncfusion.Windows.Forms.Tools) provides five layout managers:
Purpose: Dock controls along borders and center (like .NET docking)
Key Features:
When to use: MDI-style interfaces, dock panels, application shells with header/footer/sidebar
Purpose: Show one child control at a time from a stack
Key Features:
When to use: Wizards, property pages, tabbed content without tabs, step-by-step forms
Purpose: Arrange controls in horizontal or vertical flow (MOST COMMONLY USED)
Key Features:
When to use: Toolbars, button panels, tag lists, responsive content, most general-purpose layouts
Purpose: Position controls in a uniform grid
Key Features:
When to use: Calculator layouts, button grids, uniform icon panels, simple tabular layouts
Purpose: Create complex layouts with flexible grid
Key Features:
When to use: Complex forms, dialog boxes, layouts with variable cell sizes, advanced positioning requirements
Key Namespace: Syncfusion.Windows.Forms.Tools
Assembly: Syncfusion.Shared.Base.dll
📄 Read: references/getting-started.md
When to read: User needs to install, understand container concepts, or set up their first layout manager.
Topics covered:
📄 Read: references/border-layout.md
When to read: User wants to dock controls to borders (North, South, East, West, Center).
Topics covered:
📄 Read: references/card-layout.md
When to read: User needs wizards, property pages, or stack-based navigation.
Topics covered:
📄 Read: references/flow-layout.md
When to read: User needs horizontal/vertical flow layouts (MOST COMMON use case).
Topics covered:
📄 Read: references/grid-layout.md
When to read: User needs uniform grid with equal-sized cells.
Topics covered:
📄 Read: references/grid-bag-layout.md
When to read: User needs complex layouts with variable cell sizes and control spanning.
Topics covered:
Choose your layout based on requirements:
| Requirement | Recommended Layout | Why |
|---|---|---|
| Dock to borders (header/footer/sidebar) | BorderLayout | Simple 5-region positioning |
| Wizard or multi-step form | CardLayout | One visible card at a time with navigation |
| Horizontal button toolbar | FlowLayout (Horizontal) | Auto-wrapping, flexible spacing |
| Vertical sidebar or list | FlowLayout (Vertical) | Auto-wrapping, flexible spacing |
| Calculator or keypad | GridLayout or GridBagLayout | Uniform grid or flexible grid |
| Complex form with labels/fields | GridBagLayout | Variable cell sizes, spanning, alignment |
| Simple tabular layout (equal cells) | GridLayout | Uniform rows and columns |
| General-purpose responsive layout | FlowLayout | Most versatile, widely applicable |
using Syncfusion.Windows.Forms.Tools;
// Create BorderLayout
BorderLayout borderLayout = new BorderLayout();
borderLayout.ContainerControl = panel1; // Panel as container
// Create controls for each position
Label northLabel = new Label { Text = "Header", BackColor = Color.LightBlue };
Label southLabel = new Label { Text = "Footer", BackColor = Color.LightGray };
Label eastLabel = new Label { Text = "Right", BackColor = Color.LightYellow };
Label westLabel = new Label { Text = "Left", BackColor = Color.LightGreen };
Panel centerPanel = new Panel { BackColor = Color.White };
// Add controls to container
panel1.Controls.Add(northLabel);
panel1.Controls.Add(southLabel);
panel1.Controls.Add(eastLabel);
panel1.Controls.Add(westLabel);
panel1.Controls.Add(centerPanel);
// Set constraints (position each control)
borderLayout.SetPosition(northLabel, BorderPosition.North)
borderLayout.SetPosition(southLabel, BorderPosition.South);
borderLayout.SetPosition(eastLabel, BorderPosition.East);
borderLayout.SetPosition(westLabel, BorderPosition.West);
borderLayout.SetPosition(centerPanel, BorderPosition.Center);
// Configure spacing
borderLayout.HGap = 5;
borderLayout.VGap = 5;
// Create CardLayout
CardLayout cardLayout = new CardLayout();
cardLayout.ContainerControl = panel1;
// Create wizard pages
Panel page1 = new Panel { BackColor = Color.AliceBlue };
Label label1 = new Label { Text = "Step 1: Welcome", Dock = DockStyle.Fill };
page1.Controls.Add(label1);
Panel page2 = new Panel { BackColor = Color.Honeydew };
Label label2 = new Label { Text = "Step 2: Configure", Dock = DockStyle.Fill };
page2.Controls.Add(label2);
Panel page3 = new Panel { BackColor = Color.LavenderBlush };
Label label3 = new Label { Text = "Step 3: Finish", Dock = DockStyle.Fill };
page3.Controls.Add(label3);
// Add pages to container
panel1.Controls.Add(page1);
panel1.Controls.Add(page2);
panel1.Controls.Add(page3);
// Name each card
cardLayout.SetCardName(page1, "Welcome");
cardLayout.SetCardName(page2, "Configure");
cardLayout.SetCardName(page3, "Finish");
// Navigation
cardLayout.LayoutMode = CardLayoutMode.Fill; // Fill container
cardLayout.First(); // Show first card
// Navigate programmatically
// cardLayout.Next(); // Next card
// cardLayout.Previous(); // Previous card
// cardLayout.ActivateCard("Configure"); // Jump to specific card
// Create FlowLayout
FlowLayout flowLayout = new FlowLayout();
flowLayout.ContainerControl = panel1;
flowLayout.LayoutMode = FlowLayoutMode.Horizontal;
flowLayout.Alignment = FlowAlignment.Near;
flowLayout.HGap = 10;
flowLayout.VGap = 5;
// Add buttons
for (int i = 1; i <= 8; i++)
{
Button btn = new Button { Text = $"Button {i}", Size = new Size(80, 30) };
panel1.Controls.Add(btn);
}
// Buttons will flow horizontally and wrap to next line automatically
// Create GridLayout (3x3 grid)
GridLayout gridLayout = new GridLayout();
gridLayout.ContainerControl = panel1;
gridLayout.Rows = 3;
gridLayout.Columns = 3;
gridLayout.HGap = 5;
gridLayout.VGap = 5;
// Add 9 buttons (automatic placement in grid)
for (int i = 1; i <= 9; i++)
{
Button btn = new Button { Text = i.ToString() };
panel1.Controls.Add(btn);
}
// Create GridBagLayout
GridBagLayout gridBagLayout = new GridBagLayout();
gridBagLayout.ContainerControl = panel1;
// Create form controls
Label nameLabel = new Label { Text = "Name:", AutoSize = true };
TextBox nameTextBox = new TextBox { Width = 200 };
Label emailLabel = new Label { Text = "Email:", AutoSize = true };
TextBox emailTextBox = new TextBox { Width = 200 };
Button submitButton = new Button { Text = "Submit" };
// Add to container
panel1.Controls.Add(nameLabel);
panel1.Controls.Add(nameTextBox);
panel1.Controls.Add(emailLabel);
panel1.Controls.Add(emailTextBox);
panel1.Controls.Add(submitButton);
// Create constraints
GridBagConstraints labelConstraints = new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false);
labelConstraints.Anchor = GridBagAnchor.East; // Align right
GridBagConstraints fieldConstraints = new GridBagConstraints(1, 0, 1, 1);
fieldConstraints.Fill = GridBagFill.Horizontal;
fieldConstraints.WeightX = 1; // Take extra horizontal space
// Apply constraints
gridBagLayout.SetConstraints(nameLabel, new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false));
gridBagLayout.SetConstraints(nameTextBox, new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false) {WeightX = 1 });
gridBagLayout.SetConstraints(emailLabel, new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false));
gridBagLayout.SetConstraints(emailTextBox, new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false){ WeightX = 1 });
gridBagLayout.SetConstraints(submitButton, new new GridBagConstraints(0, 0, 1, 1, 1.0, 0.0, AnchorTypes.East, FillType.Horizontal, new Insets(5,5,5,5), 0, 0, false));
// Header + Footer + Sidebar + Content area
BorderLayout borderLayout = new BorderLayout();
borderLayout.ContainerControl = this; // Form as container
borderLayout.HGap = 0;
borderLayout.VGap = 0;
Panel header = new Panel { Height = 60, BackColor = Color.Navy };
Panel footer = new Panel { Height = 30, BackColor = Color.Gray };
Panel sidebar = new Panel { Width = 200, BackColor = Color.LightGray };
Panel content = new Panel { BackColor = Color.White };
this.Controls.AddRange(new Control[] { header, footer, sidebar, content });
borderLayout.SetPosition(header, BorderPosition.North);
borderLayout.SetPosition(footer, BorderPosition.South);
borderLayout.SetPosition(sidebar, BorderPosition.West);
borderLayout.SetPosition(content, BorderPosition.Center);
When to use: Main application window with fixed header/footer and sidebar.
See Quick Start example above. Add Next/Previous buttons to navigate between wizard steps.
See Quick Start example above. Buttons automatically wrap when window resizes.
// Labels in column 0, fields in column 1
// Submit button spans both columns
// All elements properly aligned and spaced
See GridBagLayout reference for complete example.
| Property | Type | Description |
|---|---|---|
| ContainerControl | Control | Container (Panel, Form) where layout is applied |
| Property | Type | Description |
|---|---|---|
| HGap | int | Horizontal gap between regions |
| VGap | int | Vertical gap between regions |
| Property | Type | Description |
|---|---|---|
| LayoutMode | CardLayoutMode | Default or Fill |
| SelectedCard | Control | Currently visible card (designer) |
| Property | Type | Description |
|---|---|---|
| LayoutMode | FlowLayoutMode | Horizontal or Vertical |
| Alignment | FlowAlignment | Near, Far, Center, ChildConstraints |
| ReverseRows | bool | Reverse flow direction |
| AutoHeight | bool | Auto-adjust height for wrapping |
| HGap | int | Horizontal gap between controls |
| VGap | int | Vertical gap between controls |
| Property | Type | Description |
|---|---|---|
| Rows | int | Number of rows |
| Columns | int | Number of columns |
| HGap | int | Horizontal gap between cells |
| VGap | int | Vertical gap between cells |
| Property | Type | Description |
|---|---|---|
| (Constraints set per child) | GridBagConstraints | See GridBagLayout reference |
Scenario: Header, footer, sidebar, content area.
Scenario: Multi-step configuration wizard.
Scenario: Horizontal toolbar that wraps to next line.
Scenario: 4x4 button grid.
Scenario: Labels on left, fields on right.
Scenario: Tags that flow and wrap.
Common layout event:
flowLayout.LayoutComplete += (sender, e) => {
// Layout has been recalculated
};
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub syncfusion/boldcreate-plugins --plugin syncfusion-winformsOther plugins' skills for the same job
113 skills in this plugin
/syncfusion-winforms-ai-assistviewGuide for implementing Syncfusion Windows Forms AI AssistView (SfAIAssistView) for building conversational AI interfaces in desktop applications. Use this when creating chat interfaces, AI assistants, or chatbots with Windows Forms. Supports OpenAI and Azure OpenAI integration, typing indicators, chat suggestions, message bubbles, custom views, input toolbar with attachments, response toolbar actions, and stop responding for interactive messaging experiences./syncfusion-winforms-autocompleteGuides implementation of the Syncfusion WinForms AutoComplete control for text input with auto-suggestion functionality. Use when users want to add autocomplete textboxes, implement auto-suggestion features, create search boxes with suggestions, enable URL/email autocomplete, or build type-ahead search functionality in Windows desktop applications. Covers data binding, customization, filtering, multi-column dropdowns, events, and all AutoComplete-specific features./syncfusion-winforms-autolabelGuides implementation of the Syncfusion WinForms AutoLabel control for automatic label positioning with form controls. Use when users want to add labels that automatically reposition when controls move, create form layouts with paired label-control units, implement complex form designs with FlowLayout, or ensure labels stay synchronized with their associated controls. Covers labeling controls, positioning, spacing, size settings, theming, and events.