In This Article

ScaleBase Class

Represents the base class for scales.

public abstract class ScaleBase : GaugeElement, ILogicalParent, IVisualParent
Inheritance:
object Visual UIElement FrameworkElement GaugeElement object
Derived:
CircularScale LinearScale
Implements:
ILogicalParent IVisualParent

Constructors

ScaleBase()

Initializes an instance of the class.

protected ScaleBase()

Properties

Background

The background brush.

public Brush? Background { get; set; }

Property Value

Brush:

The default value is DarkGray.

BarExtent

The extent of the bar.

public Unit BarExtent { get; set; }

Property Value

Unit:

The default value is 90%.

BorderBrush

The border brush.

public Brush? BorderBrush { get; set; }

Property Value

Brush:

The default value is Black.

BorderDashStyle

The border dash style.

public DashStyle? BorderDashStyle { get; set; }

Property Value

DashStyle:

The default value is Solid.

BorderWidth

The border width.

public double BorderWidth { get; set; }

Property Value

double:

The default value is 0.

IsBarVisible

Indicates whether the scale renders an associated bar.

public bool IsBarVisible { get; set; }

Property Value

bool:

true if the scale bar visible; otherwise, false. The default value is true.

Methods

GetBarExtent(DependencyObject)

Gets the value of the BarExtentProperty attached property for a specified object.

[AttachedPropertyBrowsableForChildren(IncludeDescendants = true)]
public static Unit GetBarExtent(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object to which the attached property is retrieved.

Returns

Unit

OnCreateAutomationPeer()

Returns class-specific AutomationPeer implementations for the Windows Presentation Foundation (WPF) infrastructure.

protected override AutomationPeer? OnCreateAutomationPeer()

Returns

AutomationPeer:

The type-specific AutomationPeer implementation.

SetBarExtent(DependencyObject, Unit)

Sets the value of the BarExtentProperty attached property to a specified object.

public static void SetBarExtent(DependencyObject obj, Unit value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value Unit

The bar extent.

Fields

BackgroundProperty

Defines the Background property.

public static readonly DependencyProperty BackgroundProperty

BarExtentProperty

Defines the BarExtent property.

public static readonly DependencyProperty BarExtentProperty

BorderBrushProperty

Defines the BorderBrush property.

public static readonly DependencyProperty BorderBrushProperty

BorderDashStyleProperty

Defines the BorderDashStyle property.

public static readonly DependencyProperty BorderDashStyleProperty

BorderWidthProperty

Defines the BorderWidth property.

public static readonly DependencyProperty BorderWidthProperty

IsBarVisibleProperty

Defines the IsBarVisible property.

public static readonly DependencyProperty IsBarVisibleProperty

Inherited Members

Extension Methods