Skip to main content
Version: 3.5

FlowLayoutPanel

Namespace: Wisej.Web

Assembly: Wisej.Framework (3.5.0.0)

Represents a panel that dynamically arranges its controls horizontally or vertically in automatic rows or columns.

public class FlowLayoutPanel : Panel, IExtenderProvider

Arranges child controls horizontally or vertically. Ignores the control location, dock style and anchoring. Uses the following properties of the child controls:

  • Margin Increases the space around the control.
  • FillWeight Stretches the width of control proportionally, according to the fill weights of all the controls, to use the remaining space in the row.
  • MinimumSize Enforces the minimum size of controls stretched using the FillWeight value.
  • MaximumSize Enforces the maximum size of controls stretched using the FillWeight value.
  • FlowBreak Determines whether to create a new row or a new column after the control.

Uses the following properties of the parent FlowLayoutPanel control:

Constructors

Instance memberFlowLayoutPanel()

Initializes a new instance of the FlowLayoutPanel class.

Instance memberFlowLayoutPanel(controls, direction)

Initializes a new instance of the FlowLayoutPanel class with the specified initial settings.

NameTypeDescription
controlsControl[]The array of child controls to add to the panel.
directionFlowDirectionThe flow direction of the layout of the child controls.

Instance memberFlowLayoutPanel(location, size, controls, direction)

Initializes a new instance of the FlowLayoutPanel class with the specified initial settings.

NameTypeDescription
locationPointThe location of the panel on its parent control.
sizeSizeThe size of the panel.
controlsControl[]The array of child controls to add to the panel.
directionFlowDirectionThe flow direction of the layout of the child controls.

Properties

Instance memberFlowDirection

FlowDirection: Returns or sets a value indicating the flow direction of the FlowLayoutPanel control. (Default: LeftToRight)

Instance memberLayoutEngine

LayoutEngine: Returns the control's layout engine.

Instance memberWrapContents

Boolean: Returns or sets whether the FlowLayoutPanel control should wrap its contents or let the contents be clipped. (Default: True)

Methods

Instance memberGetFillWeight(control)

Determines whether to proportionally stretch the width or the control to fill the remaining space it the containing row.

ParameterTypeDescription
controlControlThe child control.

Returns: Int32. The fill weight value associated with the control.

The FillWeight property defines the relative width of a control in a row managed by the FlowLayoutPanel. The default value is 0 and the maximum value is 100 (the control will fill all the remaining width of the row.)

Instance memberGetFlowBreak(control)

Determines whether to create a new row or a new column, depending on the value of the FlowDirection property, after the control.

ParameterTypeDescription
controlControlThe child control.

Returns: Boolean. true if the flow break is set; otherwise, false.

Instance memberSetFillWeight(control, value)

Determines whether to proportionally stretch the width or the control to fill the remaining space it the containing row.

ParameterTypeDescription
controlControlThe child control.
valueInt32The fill weight value to set.

The FillWeight property defines the relative width of a control in a row managed by the FlowLayoutPanel. The default value is 0 and the maximum value is 100 (the control will fill all the remaining width of the row.) Throws:

Instance memberSetFlowBreak(control, value)

Determines whether to create a new row or a new column, depending on the value of the FlowDirection property, after the control.

ParameterTypeDescription
controlControlThe child control.
valueBooleanThe flow-break value to set.

Inherited By

NameDescription
BindingNavigatorRepresents the navigation and manipulation user interface (UI) for controls that are bound to a data source.

Implements

NameDescription
IBindableComponentBindable components implement this interface.
IDropTargetControls that support drag & drop operations implement this interface.
IImageProvides access to common image properties across the controls that implement this interface.
IWisejComponentAll wisej components implement this interface.
IWisejControlAll wisej controls derived from the Control class must implement this interface.
IWisejSerializableAllows an object to serialize itself.