FlexLayoutPanelExtensions
Namespace: Wisej.Web.Markup
Assembly: Wisej.Framework (4.1.0.0)
Adds fluent markup extension methods to the FlexLayoutPanel class.
- C#
- VB.NET
public class FlexLayoutPanelExtensions
Public Class FlexLayoutPanelExtensions
Methods
AlignX<TPanel>(panel, control, value)
Sets the horizontal alignment for a specific control within the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel containing the control. |
| control | Control | The control to set the horizontal alignment for. |
| value | HorizontalAlignment | The horizontal alignment value to set. |
Returns: TPanel. The modified panel with the updated horizontal alignment for the control.
This method allows you to fluently set the horizontal alignment of a control within a panel.
var panel = new FlexLayoutPanel();
var control = new Control();
panel.AlignX(control, HorizontalAlignment.Right);
AlignY<TPanel>(panel, control, value)
Sets the vertical alignment for a specific control within the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel containing the control. |
| control | Control | The control to set the vertical alignment for. |
| value | VerticalAlignment | The vertical alignment value to set. |
Returns: TPanel. The modified panel with the updated vertical alignment for the control.
This method allows you to fluently set the vertical alignment of a control within a panel.
var panel = new FlexLayoutPanel();
var control = new Control();
panel.AlignY(control, VerticalAlignment.Bottom);
FillWeight<TPanel>(panel, control, value)
Sets the fill weight for a specific control within the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel containing the control. |
| control | Control | The control to set the fill weight for. |
| value | Int32 | The fill weight value to set. |
Returns: TPanel. The modified panel with the updated fill weight for the control.
This method allows you to fluently set the fill weight of a control within a panel.
var panel = new FlexLayoutPanel();
var control = new Control();
panel.FillWeight(control, 2);
HorizontalAlign<TPanel>(panel, value)
Sets the horizontal alignment of the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel to set the horizontal alignment for. |
| value | HorizontalAlignment | The horizontal alignment value to set. |
Returns: TPanel. The modified panel with the updated horizontal alignment.
This method allows you to fluently set the horizontal alignment of a panel.
var panel = new FlexLayoutPanel();
panel.HorizontalAlign(HorizontalAlignment.Center);
LayoutStyle<TPanel>(panel, value)
Sets the layout style of the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel to set the layout style for. |
| value | FlexLayoutStyle | The layout style value to set. |
Returns: TPanel. The modified panel with the updated layout style.
This method allows you to fluently set the layout style of a panel.
var panel = new FlexLayoutPanel();
panel.LayoutStyle(FlexLayoutStyle.Wrap);
Spacing<TPanel>(panel, value)
Sets the spacing between elements in the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel to set the spacing for. |
| value | Int32 | The spacing value to set. |
Returns: TPanel. The modified panel with the updated spacing.
This method allows you to fluently set the spacing between elements in a panel.
var panel = new FlexLayoutPanel();
panel.Spacing(10);
VerticalAlign<TPanel>(panel, value)
Sets the vertical alignment of the specified FlexLayoutPanel.
| Parameter | Type | Description |
|---|---|---|
| TPanel | The type of the panel, which must inherit from FlexLayoutPanel. | |
| panel | TPanel | The panel to set the vertical alignment for. |
| value | VerticalAlignment | The vertical alignment value to set. |
Returns: TPanel. The modified panel with the updated vertical alignment.
This method allows you to fluently set the vertical alignment of a panel.
var panel = new FlexLayoutPanel();
panel.VerticalAlign(VerticalAlignment.Top);