TabControlExtensions
Wisej.Web.Markup.TabControlExtensions
Last updated
Was this helpful?
Wisej.Web.Markup.TabControlExtensions
Last updated
Was this helpful?
Namespace: Wisej.Web.Markup
Assembly: Wisej.Framework (4.0.0.0)
Adds fluent markup extension methods to the TabControl class.
public class TabControlExtensions
Sets the Alignment property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the Alignment property.
alignment
Returns: TTabControl. The modified tab control with the updated Alignment property.
This method allows you to specify the alignment of the tabs in the tab control.
myTabControl.Alignment(TabAlignment.Bottom);
Sets the BorderStyle property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the BorderStyle property.
borderStyle
Returns: TTabControl. The modified tab control with the updated BorderStyle property.
This method allows you to specify the border style of the tab control.
myTabControl.BorderStyle(BorderStyle.FixedSingle);
Sets the ItemSize property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the ItemSize property.
size
Returns: TTabControl. The modified tab control with the updated ItemSize property.
This method allows you to specify the size of each tab item in the tab control.
myTabControl.ItemSize(new Size(100, 50));
Attaches an event handler for the Deselected event of the specified TabControl.
TTabControl
tabControl
The tab control to attach the event handler to.
action
An action to execute when a tab is deselected.
Returns: TTabControl. The modified tab control with the attached Deselected event handler.
This method allows you to execute a custom action whenever a tab is deselected.
myTabControl.OnDeselected((tc, args) =>
{
AlertBox.Show("Tab deselected!");
});
Attaches an event handler for the Deselecting event of the specified TabControl.
TTabControl
tabControl
The tab control to attach the event handler to.
action
An action to execute when a tab is being deselected.
Returns: TTabControl. The modified tab control with the attached Deselecting event handler.
This method allows you to execute a custom action whenever a tab is being deselected.
myTabControl.OnDeselecting((tc, args) =>
{
AlertBox.Show("Tab deselecting!");
});
Attaches an event handler for the Selected event of the specified TabControl.
TTabControl
tabControl
The tab control to attach the event handler to.
action
An action to execute when a tab is selected.
Returns: TTabControl. The modified tab control with the attached Selected event handler.
This method allows you to execute a custom action whenever a tab is selected.
myTabControl.OnSelected((tc, args) =>
{
AlertBox.Show("Tab selected!");
});
Attaches an event handler for the Selecting event of the specified TabControl.
TTabControl
tabControl
The tab control to attach the event handler to.
action
An action to execute when a tab is being selected.
Returns: TTabControl. The modified tab control with the attached Selecting event handler.
This method allows you to execute a custom action whenever a tab is being selected.
myTabControl.OnSelecting((tc, args) =>
{
AlertBox.Show("Tab selecting!");
});
Sets the SelectedIndex property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the SelectedIndex property.
value
The index of the tab to select.
Returns: TTabControl. The modified tab control with the updated SelectedIndex property.
This method allows you to specify the index of the tab to select.
myTabControl.SelectedIndex(1);
Sets the ShowToolTips property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the ShowToolTips property.
value
A boolean indicating whether tooltips are shown for the tabs.
Returns: TTabControl. The modified tab control with the updated ShowToolTips property.
This method allows you to enable or disable the display of tooltips for the tabs in the tab control.
myTabControl.ShowToolTips(true);
Sets the SizeMode property of the specified TabControl.
TTabControl
tabControl
The tab control for which to set the SizeMode property.
sizeMode
Returns: TTabControl. The modified tab control with the updated SizeMode property.
This method allows you to specify the size mode of the tabs in the tab control.
myTabControl.SizeMode(TabSizeMode.Fixed);
Adds the specified tab pages to the TabPages collection of the specified TabControl.
TTabControl
tabControl
The tab control to which the tab pages should be added.
tabPages
Returns: TTabControl. The modified tab control with the added tab pages.
This method allows you to add multiple tab pages to the tab control in one call.
myTabControl.TabPages(new TabPage("Tab1"), new TabPage("Tab2"));
The type of the tab control, must inherit from .
The to set for the tab control.
The type of the tab control, must inherit from .
The to set for the tab control.
The type of the tab control, must inherit from .
The to set for each tab item.
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The type of the tab control, must inherit from .
The to set for the tab control.
The type of the tab control, must inherit from .
An array of to add to the tab control.