In This Article

BarSeparator Class

Represents a separator control, for use within a ribbon or toolbar.

public class BarSeparator : Separator
Inheritance:
object Visual UIElement FrameworkElement Control Separator object

Constructors

BarSeparator()

Initializes an instance of the class.

public BarSeparator()

Properties

IsSpacer

Indicates whether the separator is a spacer and should not render any decorations.

public bool IsSpacer { get; }

Property Value

bool

Key

A string that uniquely identifies the control.

[Localizability(LocalizationCategory.NeverLocalize)]
public string? Key { get; set; }

Property Value

string

StandaloneToolBarSeparatorMode

The mode that determines how this separator behaves within a StandaloneToolBar.

public StandaloneToolBarSeparatorMode StandaloneToolBarSeparatorMode { get; set; }

Property Value

StandaloneToolBarSeparatorMode:

The default value is Default.

VariantSize

The VariantSize currently assigned to the control.

public VariantSize VariantSize { get; set; }

Property Value

VariantSize

Remarks

This property should only be manually set when the control is standalone, and not hosted by a bar control.

Methods

OnCreateAutomationPeer()

Provides an appropriate SeparatorAutomationPeer implementation for this control, as part of the WPF automation infrastructure.

protected override AutomationPeer OnCreateAutomationPeer()

Returns

AutomationPeer:

The type-specific AutomationPeer implementation.

Fields

IsSpacerProperty

Defines the IsSpacer property.

public static readonly DependencyProperty IsSpacerProperty

KeyProperty

Defines the Key property.

public static readonly DependencyProperty KeyProperty

StandaloneToolBarSeparatorModeProperty

Defines the StandaloneToolBarSeparatorMode property.

public static readonly DependencyProperty StandaloneToolBarSeparatorModeProperty

VariantSizeProperty

Defines the VariantSize property.

public static readonly DependencyProperty VariantSizeProperty

Extension Methods