C# Class GrayIris.Utilities.UI.Controls.YaTabControl

Inheritance: System.Windows.Forms.Control
Afficher le fichier Open project: realistschuckle/yet-another-tab-control Class Usage Examples

Méthodes publiques

Méthode Description
AddNewTab ( ) : GrayIris.Utilities.UI.Controls.YaTabPage

Adds a "NEW_TAB" at the end of the list of tabs.

GetLeftScrollButtonRect ( ) : Rectangle

Gets the Rectangle that contains the left scroll button.

GetRightScrollButtonRect ( ) : Rectangle

Gets the Rectangle that contains the left scroll button.

GetTabRect ( int index ) : Rectangle

Returns the bounding rectangle for a specified tab in this tab control.

ScrollTabs ( int amount ) : void

Scrolls the tabs by the specified amount.

Positive amounts will scroll the tabs to the left. Negative amounts will scroll the tabs to the right.

YaTabControl ( ) : System

Creates a new instance of the YaTabControl class.

Méthodes protégées

Méthode Description
CreateControlsInstance ( ) : System.Windows.Forms.Control.ControlCollection

Overriden from Control.

Dispose ( bool disposing ) : void

Inherited from Control.

OnActiveColorChanged ( EventArgs ea ) : void

Fires the ActiveColorChanged event.

OnBorderColorChanged ( EventArgs ea ) : void

Fires the BorderColorChanged event.

OnControlAdded ( System.Windows.Forms.ControlEventArgs cea ) : void

Overridden. Inherited from Control.

OnControlRemoved ( System.Windows.Forms.ControlEventArgs cea ) : void

Overridden. Inherited from Control.

OnInactiveColorChanged ( EventArgs ea ) : void

Fires the InactiveColorChanged event.

OnMarginChanged ( EventArgs ea ) : void

Fires the MarginChanged event.

OnMouseClick ( MouseEventArgs e ) : void

Overridden. Inherited from Control.

OnMouseDown ( MouseEventArgs mea ) : void

Overridden. Inherited from Control.

OnMouseLeave ( EventArgs mea ) : void

Overridden. Inherited from Control.

OnMouseMove ( MouseEventArgs mea ) : void

Overridden. Inherited from Control.

OnMouseUp ( MouseEventArgs mea ) : void

Overridden. Inherited from Control.

OnNewTabButtonClicked ( NewTabEventArgs ea ) : void

Fires the NewTabButtonClicked event.

OnPaint ( PaintEventArgs pea ) : void

Inherited from Control.

OnScrollButtonStyleChanged ( EventArgs ea ) : void

Fires the ScrollButtonStyleChanged event.

OnSizeChanged ( EventArgs e ) : void

Inherited from Control.

OnTabChanged ( EventArgs ea ) : void

Fires the TabChanged event.

OnTabChanging ( GrayIris.Utilities.UI.Controls.TabChangingEventArgs tcea ) : void

Fires the TabChanging event.

OnTabClosing ( TabClosingEventArgs e ) : void

Fires the TabClosing event.

OnTabDockChanged ( EventArgs ea ) : void

Fires the TabDockChanged event.

OnTabDrawerChanged ( EventArgs ea ) : void

Fires the TabDrawerChanged event.

OnTabFontChanged ( EventArgs ea ) : void

Fires the TabFontChanged event.

Private Methods

Méthode Description
CalculateLastVisibleTabIndex ( ) : void

Calculates the last visible tab shown on the control.

CalculateRectangles ( ) : void

Calculates the rectangles for the tab area, the client area, the display area, and the transformed display area.

CalculateTabLengths ( ) : void

Calculates and caches the length of each tab given the value of the Control.Text property of each YaTabPage.

CalculateTabSpan ( ) : void

Calculates the span of a tab given the value of the Font property.

ChildTabTextChanged ( object sender, EventArgs ea ) : void

Monitors when child YaTabPages have their YaTabPage.Text property changed.

GetRectangleClose ( Rectangle tabRectangle, int inflateSize ) : RectangleF
InU ( ) : void

Invalidates and updates the YaTabControl.

IsNewTab ( int tabIndex ) : bool

Indicates whether a given tab index represents the "NEW_TAB"

YaTabPage_TextChanged ( object sender, EventArgs e ) : void

Handles when the text changes for a control.

Method Details

AddNewTab() public méthode

Adds a "NEW_TAB" at the end of the list of tabs.
public AddNewTab ( ) : GrayIris.Utilities.UI.Controls.YaTabPage
Résultat GrayIris.Utilities.UI.Controls.YaTabPage

CreateControlsInstance() protected méthode

Overriden from Control.
protected CreateControlsInstance ( ) : System.Windows.Forms.Control.ControlCollection
Résultat System.Windows.Forms.Control.ControlCollection

Dispose() protected méthode

Inherited from Control.
protected Dispose ( bool disposing ) : void
disposing bool /// See . ///
Résultat void

GetLeftScrollButtonRect() public méthode

Gets the Rectangle that contains the left scroll button.
public GetLeftScrollButtonRect ( ) : Rectangle
Résultat System.Drawing.Rectangle

GetRightScrollButtonRect() public méthode

Gets the Rectangle that contains the left scroll button.
public GetRightScrollButtonRect ( ) : Rectangle
Résultat System.Drawing.Rectangle

GetTabRect() public méthode

Returns the bounding rectangle for a specified tab in this tab control.
/// The index is less than zero.
-or-
The index is greater than or equal to . ///
public GetTabRect ( int index ) : Rectangle
index int The 0-based index of the tab you want.
Résultat System.Drawing.Rectangle

OnActiveColorChanged() protected méthode

Fires the ActiveColorChanged event.
protected OnActiveColorChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnBorderColorChanged() protected méthode

Fires the BorderColorChanged event.
protected OnBorderColorChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnControlAdded() protected méthode

Overridden. Inherited from Control.
protected OnControlAdded ( System.Windows.Forms.ControlEventArgs cea ) : void
cea System.Windows.Forms.ControlEventArgs /// See . ///
Résultat void

OnControlRemoved() protected méthode

Overridden. Inherited from Control.
protected OnControlRemoved ( System.Windows.Forms.ControlEventArgs cea ) : void
cea System.Windows.Forms.ControlEventArgs /// See . ///
Résultat void

OnInactiveColorChanged() protected méthode

Fires the InactiveColorChanged event.
protected OnInactiveColorChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnMarginChanged() protected méthode

Fires the MarginChanged event.
protected OnMarginChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnMouseClick() protected méthode

Overridden. Inherited from Control.
protected OnMouseClick ( MouseEventArgs e ) : void
e MouseEventArgs
Résultat void

OnMouseDown() protected méthode

Overridden. Inherited from Control.
protected OnMouseDown ( MouseEventArgs mea ) : void
mea MouseEventArgs /// See . ///
Résultat void

OnMouseLeave() protected méthode

Overridden. Inherited from Control.
protected OnMouseLeave ( EventArgs mea ) : void
mea System.EventArgs /// See . ///
Résultat void

OnMouseMove() protected méthode

Overridden. Inherited from Control.
protected OnMouseMove ( MouseEventArgs mea ) : void
mea MouseEventArgs /// See . ///
Résultat void

OnMouseUp() protected méthode

Overridden. Inherited from Control.
protected OnMouseUp ( MouseEventArgs mea ) : void
mea MouseEventArgs /// Some . ///
Résultat void

OnNewTabButtonClicked() protected méthode

Fires the NewTabButtonClicked event.
protected OnNewTabButtonClicked ( NewTabEventArgs ea ) : void
ea NewTabEventArgs /// Some . ///
Résultat void

OnPaint() protected méthode

Inherited from Control.
protected OnPaint ( PaintEventArgs pea ) : void
pea PaintEventArgs /// See . ///
Résultat void

OnScrollButtonStyleChanged() protected méthode

Fires the ScrollButtonStyleChanged event.
protected OnScrollButtonStyleChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnSizeChanged() protected méthode

Inherited from Control.
protected OnSizeChanged ( EventArgs e ) : void
e System.EventArgs /// See . ///
Résultat void

OnTabChanged() protected méthode

Fires the TabChanged event.
protected OnTabChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some for the event. ///
Résultat void

OnTabChanging() protected méthode

Fires the TabChanging event.
protected OnTabChanging ( GrayIris.Utilities.UI.Controls.TabChangingEventArgs tcea ) : void
tcea GrayIris.Utilities.UI.Controls.TabChangingEventArgs /// Some for the event. ///
Résultat void

OnTabClosing() protected méthode

Fires the TabClosing event.
protected OnTabClosing ( TabClosingEventArgs e ) : void
e TabClosingEventArgs /// Some for the event. ///
Résultat void

OnTabDockChanged() protected méthode

Fires the TabDockChanged event.
protected OnTabDockChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnTabDrawerChanged() protected méthode

Fires the TabDrawerChanged event.
protected OnTabDrawerChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

OnTabFontChanged() protected méthode

Fires the TabFontChanged event.
protected OnTabFontChanged ( EventArgs ea ) : void
ea System.EventArgs /// Some . ///
Résultat void

ScrollTabs() public méthode

Scrolls the tabs by the specified amount.
Positive amounts will scroll the tabs to the left. Negative amounts will scroll the tabs to the right.
public ScrollTabs ( int amount ) : void
amount int /// The number of pixels to scroll the tabs. ///
Résultat void

YaTabControl() public méthode

Creates a new instance of the YaTabControl class.
public YaTabControl ( ) : System
Résultat System