BinarySmartNavigator
A custom TabControl class that provides a customized and enhanced tab items navigation experience.
public class BinarySmartNavigator : TabControl
Inherits from / implements: TabControl
Remarks
The control is used like a TabControl: add BinarySmartNavigatorItems and give each its content. How this control works. It is a tab control with a different face. Each item's header is drawn as a small ellipse in a row across the top, the selected item's Header is shown as the title (through SelectedHeader), and the previous and next buttons ( PART_PreviousTabButton , PART_NextTabButton ) step the selection. Everything else - selection, content, keyboard - is the base class's. One place keeps the buttons right. Their enabled state and tool tips follow the selection and the item count, and are recomputed whenever either changes - by a button, a click on an ellipse, the keyboard, code, or items being added or removed. The tool tip on a disabled button says why it is disabled, which is why the template shows tool tips on disabled buttons. Animations let go when they finish. ControlAnimationType animates the newly selected item or its content, and every animation ends with Stop, so the element goes back to sizing itself afterwards rather than keeping the last animated size. The default style uses ContentVanishesAndAppears.
Members at a glance
BinarySmartNavigator | Initializes a new instance of the BinarySmartNavigator class. |
ControlAnimationType | Gets or sets the type of the control animation. |
ItemEllipseBorderBrushHover | Gets or sets the item ellipse border brush on hover. |
ItemEllipseBorderBrushNormal | Gets or sets the item ellipse border brush normal. |
ItemEllipseBorderBrushSelected | Gets or sets the item ellipse border brush on selected. |
ItemEllipseFillHover | Gets or sets the item ellipse fill hover brush. |
ItemEllipseFillNormal | Gets or sets the item ellipse fill normal brush. |
ItemEllipseFillSelected | Gets or sets the item ellipse fill selected brush. |
ItemTitleBackground | Gets or sets the item title background brush, |
ItemTitleForeground | Gets or sets the item title foreground brush. |
NavigationButtonArrowFill | Gets or sets the navigation button arrow fill brush. |
NavigationButtonDisabledArrowFill | Gets or sets the navigation button disabled arrow fill brush. |
NavigationButtonDisabledBackground | Gets or sets the navigation button disabled background brush. |
NavigationButtonDisabledBorder | Gets or sets the navigation button disabled border brush. |
NavigationButtonDisabledBorderBrushForStrokeLayer | Gets or sets the navigation button disabled border brush for stroke layer. |
NavigationButtonDropShadowColor | Gets or sets the color of the navigation button drop shadow. |
NavigationButtonDropShadowEffect | Gets the effect the navigation buttons draw their drop shadow with. |
NavigationButtonDropShadowSoftness | Gets or sets how far the navigation button's drop shadow spreads, in device-independent pixels. |
NavigationButtonHasDropShadow | Gets or sets a value indicating whether the navigation button has drop shadow rendered. |
NavigationButtonHoverBackground | Gets or sets the navigation button hover background brush. |
NavigationButtonHoverBorder | Gets or sets the navigation button hover border brush. |
NavigationButtonHoverBorderBrushForStrokeLayer | Gets or sets the navigation button hover border brush for stroke layer. |
NavigationButtonNormalBackground | Gets or sets the navigation button normal background brush. |
NavigationButtonNormalBorder | Gets or sets the navigation button normal border brush. |
NavigationButtonNormalBorderBrushForStrokeLayer | Gets or sets the navigation button normal border brush for stroke layer. |
NavigationButtonPressedBackground | Gets or sets the navigation button pressed background brush. |
NavigationButtonPressedBorder | Gets or sets the navigation button pressed border brush. |
NavigationButtonPressedBorderBrushForStrokeLayer | Gets or sets the navigation button pressed border brush for stroke layer. |
NavigationOrientation | Gets or sets the navigation orientation. |
SelectedHeader | Gets or sets the selected header. |
OnApplyTemplate | Called when ApplyTemplate is called. |
OnItemsChanged | Keeps the navigation buttons right as items are added and removed. |
OnSelectionChanged | Raises the SelectionChanged event. BinarySmartNavigator overrides it so the control's own handling runs alongside the base behavior. |
ControlAnimationTypeProperty | Identifies the ControlAnimationType dependency property. |
ItemEllipseBorderBrushHoverProperty | Identifies the ItemEllipseBorderBrushHover dependency property. |
ItemEllipseBorderBrushNormalProperty | Identifies the ItemEllipseBorderBrushNormal dependency property. |
ItemEllipseBorderBrushSelectedProperty | Identifies the ItemEllipseBorderBrushSelected dependency property. |
ItemEllipseFillHoverProperty | Identifies the ItemEllipseFillHover dependency property. |
ItemEllipseFillNormalProperty | Identifies the ItemEllipseFillNormal dependency property. |
ItemEllipseFillSelectedProperty | Identifies the ItemEllipseFillSelected dependency property. |
ItemTitleBackgroundProperty | Identifies the ItemTitleBackground dependency property. |
ItemTitleForegroundProperty | Identifies the ItemTitleForeground dependency property. |
NavigationButtonArrowFillProperty | Identifies the NavigationButtonArrowFill dependency property. |
NavigationButtonDisabledArrowFillProperty | Identifies the NavigationButtonDisabledArrowFill dependency property. |
NavigationButtonDisabledBackgroundProperty | Identifies the NavigationButtonDisabledBackground dependency property. |
NavigationButtonDisabledBorderBrushForStrokeLayerProperty | Identifies the NavigationButtonDisabledBorderBrushForStrokeLayer dependency property. |
NavigationButtonDisabledBorderProperty | Identifies the NavigationButtonDisabledBorder dependency property. |
NavigationButtonDropShadowColorProperty | Identifies the NavigationButtonDropShadowColor dependency property. |
NavigationButtonDropShadowEffectProperty | Identifies the NavigationButtonDropShadowEffect dependency property. |
NavigationButtonDropShadowSoftnessProperty | Identifies the NavigationButtonDropShadowSoftness dependency property. |
NavigationButtonHasDropShadowProperty | Identifies the NavigationButtonHasDropShadow dependency property. |
NavigationButtonHoverBackgroundProperty | Identifies the NavigationButtonHoverBackground dependency property. |
NavigationButtonHoverBorderBrushForStrokeLayerProperty | Identifies the NavigationButtonHoverBorderBrushForStrokeLayer dependency property. |
NavigationButtonHoverBorderProperty | Identifies the NavigationButtonHoverBorder dependency property. |
NavigationButtonNormalBackgroundProperty | Identifies the NavigationButtonNormalBackground dependency property. |
NavigationButtonNormalBorderBrushForStrokeLayerProperty | Identifies the NavigationButtonNormalBorderBrushForStrokeLayer dependency property. |
NavigationButtonNormalBorderProperty | Identifies the NavigationButtonNormalBorder dependency property. |
NavigationButtonPressedBackgroundProperty | Identifies the NavigationButtonPressedBackground dependency property. |
NavigationButtonPressedBorderBrushForStrokeLayerProperty | Identifies the NavigationButtonPressedBorderBrushForStrokeLayer dependency property. |
NavigationButtonPressedBorderProperty | Identifies the NavigationButtonPressedBorder dependency property. |
NavigationOrientationProperty | Identifies the NavigationOrientation dependency property. |
SelectedHeaderProperty | Identifies the SelectedHeader dependency property. |
Constructors
Properties
ControlAnimationType
Gets or sets the type of the control animation.
Value. The type of the control animation.
ItemEllipseBorderBrushHover
Gets or sets the item ellipse border brush on hover.
ItemEllipseBorderBrushNormal
Gets or sets the item ellipse border brush normal.
ItemEllipseBorderBrushSelected
Gets or sets the item ellipse border brush on selected.
ItemEllipseFillHover
Gets or sets the item ellipse fill hover brush.
ItemEllipseFillNormal
Gets or sets the item ellipse fill normal brush.
ItemEllipseFillSelected
Gets or sets the item ellipse fill selected brush.
ItemTitleBackground
Gets or sets the item title background brush,
ItemTitleForeground
Gets or sets the item title foreground brush.
SelectedHeader
Gets or sets the selected header.
Value. The selected header.
Methods
OnApplyTemplate
Called when ApplyTemplate is called.
OnItemsChanged
Keeps the navigation buttons right as items are added and removed.
- e
- The change.
OnSelectionChanged
Raises the SelectionChanged event. BinarySmartNavigator overrides it so the control's own handling runs alongside the base behavior.
- e
- The event data.
Fields
ControlAnimationTypeProperty
Identifies the ControlAnimationType dependency property.
ItemEllipseBorderBrushHoverProperty
Identifies the ItemEllipseBorderBrushHover dependency property.
ItemEllipseBorderBrushNormalProperty
Identifies the ItemEllipseBorderBrushNormal dependency property.
ItemEllipseBorderBrushSelectedProperty
Identifies the ItemEllipseBorderBrushSelected dependency property.
ItemEllipseFillHoverProperty
Identifies the ItemEllipseFillHover dependency property.
ItemEllipseFillNormalProperty
Identifies the ItemEllipseFillNormal dependency property.
ItemEllipseFillSelectedProperty
Identifies the ItemEllipseFillSelected dependency property.
ItemTitleBackgroundProperty
Identifies the ItemTitleBackground dependency property.
ItemTitleForegroundProperty
Identifies the ItemTitleForeground dependency property.
SelectedHeaderProperty
Identifies the SelectedHeader dependency property.