TabStripPage Class
Represents a page for a TabStrip control.
public class TabStripPage : UIContainerControl, IUIControl, IUIElement, ILogicalTreeNode, IDpiAwareElement, IDisposable, IImageListProvider
- Inheritance:
- object MarshalByRefObject Component Control ScrollableControl ContainerControl UIContainerControl object
Constructors
TabStripPage()
Initializes a new instance of the TabStripPage class.
public TabStripPage()
Remarks
The default constructor initializes all fields to their default values.
TabStripPage(string, string, Image)
Initializes a new instance of the TabStripPage class.
public TabStripPage(string key, string text, Image image)
| Parameter | Type | Description |
|---|---|---|
| key | string | A string-based key that identifies an object within its parent collection. |
| text | string | The text caption. |
| image | Image | The Image. |
TabStripPage(string, string, int)
Initializes a new instance of the TabStripPage class.
public TabStripPage(string key, string text, int imageIndex)
| Parameter | Type | Description |
|---|---|---|
| key | string | A string-based key that identifies an object within its parent collection. |
| text | string | The text caption. |
| imageIndex | int | The index of an image within an |
Properties
Active
Gets or sets whether the page is visible.
public bool Active { get; set; }
Property Value
- bool:
trueif the page is visible; otherwise,false.
Anchor
Gets or sets which edges of the control are anchored to the edges of its container.
[Browsable(false)]
public override AnchorStyles Anchor { get; set; }
Property Value
- AnchorStyles:
A bitwise combination of the AnchorStyles values. The default is
TopandLeft.
BackgroundFill
Gets or sets the page-specific BackgroundFill for the page.
public BackgroundFill BackgroundFill { get; set; }
Property Value
- BackgroundFill:
The page-specific BackgroundFill for the page.
ContextImage
Gets or sets the context image that is displayed for the page on the opposite side of the tab.
public Image ContextImage { get; set; }
Property Value
- Image:
The context
Imagedisplayed for the page. The default value isnull.
Dock
Gets or sets which edge of the parent container a control is docked to.
[Browsable(false)]
public override DockStyle Dock { get; set; }
Property Value
Enabled
Gets or sets a value indicating whether the control can respond to user interaction.
public bool Enabled { get; set; }
Property Value
- bool:
trueif the control can respond to user interaction; otherwise,false. The default istrue.
Image
Gets or sets the image that is displayed on the page.
public Image Image { get; set; }
Property Value
- Image:
The
Imagedisplayed on the page. The default value isnull.
ImageIndex
Gets or sets the index of an image within an ImageList that is displayed on the page.
[ImageIndex]
[TypeConverter(typeof(ImageIndexConverter))]
public int ImageIndex { get; set; }
Property Value
- int:
The index of an image within an
ImageListthat is displayed on the page. The default value is-1.
IsSelected
Gets whether the page is selected.
[Browsable(false)]
public bool IsSelected { get; }
Property Value
- bool:
trueif the page is selected; otherwise,false.
Key
Gets or sets a string-based key that identifies an object within its parent collection.
public string Key { get; set; }
Property Value
- string:
A string-based key that identifies an object within its parent collection.
TabDisabledForeColor
Gets or sets the page-specific foreground color of the page's tab when it is disabled.
public Color TabDisabledForeColor { get; set; }
Property Value
TabIndex
Gets or sets the tab order of the control within its container.
[Browsable(false)]
public int TabIndex { get; set; }
Property Value
- int:
The index value of the control within the set of controls within its container that are included in the tab order.
TabSelectedBackgroundFill
Gets or sets the page-specific BackgroundFill for the page's tab when it is selected.
public BackgroundFill TabSelectedBackgroundFill { get; set; }
Property Value
- BackgroundFill:
The page-specific BackgroundFill for the page's tab when it is selected.
TabSelectedFont
Gets or sets the page-specific Font to use for drawing the page's tab when it is selected.
public virtual Font TabSelectedFont { get; set; }
Property Value
TabSelectedForeColor
Gets or sets the page-specific foreground color of the page's tab when it is selected.
public Color TabSelectedForeColor { get; set; }
Property Value
TabStop
Gets or sets a value indicating whether the user can give the focus to this control using the TAB key.
[Browsable(false)]
public bool TabStop { get; set; }
Property Value
- bool:
trueif the user can give the focus to the control using the TAB key; otherwise,false. The default istrue.
TabStrip
Gets the TabStrip that contains the page.
[Browsable(false)]
public TabStrip TabStrip { get; }
Property Value
TabUnselectedBackgroundFill
Gets or sets the page-specific BackgroundFill for the page's tab when it is unselected.
public BackgroundFill TabUnselectedBackgroundFill { get; set; }
Property Value
- BackgroundFill:
The page-specific BackgroundFill for the page's tab when it is unselected.
TabUnselectedFont
Gets or sets the page-specific Font to use for drawing the page's tab when it is unselected.
public virtual Font TabUnselectedFont { get; set; }
Property Value
TabUnselectedForeColor
Gets or sets the page-specific foreground color of the page's tab when it is unselected.
public Color TabUnselectedForeColor { get; set; }
Property Value
Text
Gets or sets the text of the page.
ToolTipText
Gets or sets the tool tip text for the page.
UseControlGraphicsForMeasure
Gets or sets whether to use a call to the control's CreateGraphics method to obtain the Graphics used for measure routines.
protected override bool UseControlGraphicsForMeasure { get; }
Property Value
- bool:
trueif the control'sCreateGraphicsmethod should be called; otherwise,false. The default value istrue.
UseExtendedDoubleBuffering
Gets or sets whether to use extended double buffering for rendering.
protected override bool UseExtendedDoubleBuffering { get; }
Property Value
- bool:
trueif extended double buffering should be used; otherwise,false.
Visible
Gets or sets a value indicating whether the control is displayed.
[Browsable(false)]
public bool Visible { get; set; }
Property Value
- bool:
trueif the control is displayed; otherwise,false. The default istrue.
Methods
CreateControlsInstance()
Creates a new instance of the control collection for the control.
protected override Control.ControlCollection CreateControlsInstance()
Returns
- Control.ControlCollection:
A new instance of a Control.ControlCollection assigned to the control.
EnsureTabVisible()
Ensures that the tab for the page is visible.
public void EnsureTabVisible()
GetImage()
Returns the Image associated with the page.
public Image GetImage()
Returns
- Image:
The
Imageassociated with the page.
Remarks
If an image has been set to the Image property, that will be returned.
Otherwise, the ImageIndex property will be used to find an
image in a parent ImageList.
OnRender(PaintEventArgs)
Renders the element.
protected override void OnRender(PaintEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | PaintEventArgs | A PaintEventArgs that contains the event data. |
ResetBackgroundFill()
Resets the BackgroundFill property to its default value.
public virtual void ResetBackgroundFill()
ResetTabDisabledForeColor()
Resets the TabDisabledForeColor property to its default value.
public virtual void ResetTabDisabledForeColor()
ResetTabSelectedBackgroundFill()
Resets the TabSelectedBackgroundFill property to its default value.
public virtual void ResetTabSelectedBackgroundFill()
ResetTabSelectedFont()
Resets the TabSelectedFont property to its default value.
public virtual void ResetTabSelectedFont()
ResetTabSelectedForeColor()
Resets the TabSelectedForeColor property to its default value.
public virtual void ResetTabSelectedForeColor()
ResetTabUnselectedBackgroundFill()
Resets the TabUnselectedBackgroundFill property to its default value.
public virtual void ResetTabUnselectedBackgroundFill()
ResetTabUnselectedFont()
Resets the TabUnselectedFont property to its default value.
public virtual void ResetTabUnselectedFont()
ResetTabUnselectedForeColor()
Resets the TabUnselectedForeColor property to its default value.
public virtual void ResetTabUnselectedForeColor()
ShouldSerializeBackgroundFill()
Indicates whether the BackgroundFill property should be persisted.
public virtual bool ShouldSerializeBackgroundFill()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabDisabledForeColor()
Indicates whether the TabDisabledForeColor property should be persisted.
public virtual bool ShouldSerializeTabDisabledForeColor()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabSelectedBackgroundFill()
Indicates whether the TabSelectedBackgroundFill property should be persisted.
public virtual bool ShouldSerializeTabSelectedBackgroundFill()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabSelectedFont()
Indicates whether the TabSelectedFont property should be persisted.
public virtual bool ShouldSerializeTabSelectedFont()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabSelectedForeColor()
Indicates whether the TabSelectedForeColor property should be persisted.
public virtual bool ShouldSerializeTabSelectedForeColor()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabUnselectedBackgroundFill()
Indicates whether the TabUnselectedBackgroundFill property should be persisted.
public virtual bool ShouldSerializeTabUnselectedBackgroundFill()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabUnselectedFont()
Indicates whether the TabUnselectedFont property should be persisted.
public virtual bool ShouldSerializeTabUnselectedFont()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
ShouldSerializeTabUnselectedForeColor()
Indicates whether the TabUnselectedForeColor property should be persisted.
public virtual bool ShouldSerializeTabUnselectedForeColor()
Returns
- bool:
trueif the property value has changed from its default; otherwise,false.
Inherited Members
- UIContainerControl.Dispose(bool)
- UIContainerControl.AddPendingGraphicsInversion(Rectangle)
- UIContainerControl.AddPendingScrollOperation(Rectangle, Orientation, int)
- UIContainerControl.AddPendingScrollOperation(Rectangle, int, int)
- UIContainerControl.AddToInvalidatedRegion()
- UIContainerControl.AddToInvalidatedRegion(Rectangle)
- UIContainerControl.Arrange(Rectangle)
- UIContainerControl.ArrangeOverride(Size)
- UIContainerControl.ContainsLocation(Point)
- UIContainerControl.CreateChildren()
- UIContainerControl.DpiScaleChanged(SizeF)
- UIContainerControl.GetCursor(Point)
- UIContainerControl.HitTest(PointHitTestParameters, Func<IUIElement, PointHitTestParameters, bool>)
- UIContainerControl.HitTestRecursive(PointHitTestParameters, Func<IUIElement, PointHitTestParameters, bool>)
- UIContainerControl.Invalidate(InvalidationLevels, InvalidationTypes)
- UIContainerControl.InvalidateArrange()
- UIContainerControl.InvalidateMeasure()
- UIContainerControl.Measure(Graphics, Size)
- UIContainerControl.MeasureOverride(Graphics, Size)
- UIContainerControl.OnClick(EventArgs)
- UIContainerControl.OnDoubleClick(EventArgs)
- UIContainerControl.OnDpiChangedAfterParent(EventArgs)
- UIContainerControl.OnHandleCreated(EventArgs)
- UIContainerControl.OnLayout(LayoutEventArgs)
- UIContainerControl.OnLocationChanged(EventArgs)
- UIContainerControl.OnMouseCaptureChanged(EventArgs)
- UIContainerControl.OnMouseDown(MouseEventArgs)
- UIContainerControl.OnMouseEnter(EventArgs)
- UIContainerControl.OnMouseHover(EventArgs)
- UIContainerControl.OnMouseLeave(EventArgs)
- UIContainerControl.OnMouseMove(MouseEventArgs)
- UIContainerControl.OnMouseUp(MouseEventArgs)
- UIContainerControl.OnMouseWheel(MouseEventArgs)
- UIContainerControl.OnPaint(PaintEventArgs)
- UIContainerControl.OnPaintBackground(PaintEventArgs)
- UIContainerControl.OnParentChanged()
- UIContainerControl.OnParentChanged(EventArgs)
- UIContainerControl.OnRenderChildElements(PaintEventArgs)
- UIContainerControl.OnResize(EventArgs)
- UIContainerControl.OnRightToLeftChanged(EventArgs)
- UIContainerControl.OnVisibleChanged(EventArgs)
- UIContainerControl.Render(PaintEventArgs)
- UIContainerControl.ResetDoubleBufferCanvas(bool)
- UIContainerControl.ResumePainting()
- UIContainerControl.SuspendPainting()
- UIContainerControl.TransformToAncestor(IUIElement)
- UIContainerControl.TransformToDescendant(IUIElement)
- UIContainerControl.UpdateCursor()
- UIContainerControl.UpdateLayout()
- UIContainerControl.ActualHeight
- UIContainerControl.ActualWidth
- UIContainerControl.BackColor
- UIContainerControl.BackgroundImage
- UIContainerControl.CaptureMouseWhenPressed
- UIContainerControl.ClipBounds
- UIContainerControl.DesiredSize
- UIContainerControl.DpiScaleFactor
- UIContainerControl.Font
- UIContainerControl.ForeColor
- UIContainerControl.IsArrangeValid
- UIContainerControl.IsMeasureValid
- UIContainerControl.IsPaintValid
- UIContainerControl.IsRightToLeft
- UIContainerControl.LastMouseUpButton
- UIContainerControl.PaintingSuspended
- MarshalByRefObject.GetLifetimeService()
- MarshalByRefObject.InitializeLifetimeService()
- MarshalByRefObject.MemberwiseClone(bool)
- object.GetType()
- object.MemberwiseClone()
- object.ToString()
- object.Equals(object)
- object.Equals(object, object)
- object.ReferenceEquals(object, object)
- object.GetHashCode()