DigitalGauge Class
Represents a digital gauge control.
public class DigitalGauge : RectangularGaugeBase, DUCE.IResource, IAnimatable, IFrameworkInputElement, IInputElement, ISupportInitialize, IHaveResources, IQueryAmbient, ILogicalParent, IVisualParent
- Inheritance:
- Object DispatcherObject DependencyObject Visual UIElement FrameworkElement GaugeElement GaugeBase RectangularGaugeBase Object
- Implements:
- ILogicalParent IVisualParent
Remarks
For detailed documentation on this control's features and how to use them, please see the Gauge documentation topics.
Constructors
DigitalGauge()
Initializes a new instance of the DigitalGauge class.
public DigitalGauge()
Properties
BlinkInterval
Gets or sets the interval used when LedState is set to Blinking
.
This is a dependency property.
public Duration BlinkInterval { get; set; }
Property Value
CharacterCasing
Gets or sets the character casing. This is a dependency property.
public CharacterCasing CharacterCasing { get; set; }
Property Value
- CharacterCasing:
The character casing. The default value is
Upper
.
CharacterCount
Gets or sets the number of characters displayed. This is a dependency property.
public int CharacterCount { get; set; }
Property Value
- Int32:
The number of characters displayed. The default value is
10
.
CharacterHeight
Gets or sets the height of the characters. This is a dependency property.
public double CharacterHeight { get; set; }
Property Value
- Double:
The height of the characters. The default value is
Double.NaN
.
CharacterOverflowAlignment
Gets or sets the alignment of the characters when the text is longer than what can be displayed. This is a dependency property.
public DigitalCharacterOverflowAlignment CharacterOverflowAlignment { get; set; }
Property Value
- DigitalCharacterOverflowAlignment:
The alignment of the characters when the text is longer than what can be displayed. The default value is
DigitalCharacterOverflowAlignment.Left
.
CharacterPadding
Gets or sets the padding of the characters displayed. This is a dependency property.
public Thickness CharacterPadding { get; set; }
Property Value
- Thickness:
The padding of the characters displayed. The default value is
0
.
CharacterSegmentThickness
Gets or sets the thickness of the character segments (not used by all character types). This is a dependency property.
public double CharacterSegmentThickness { get; set; }
Property Value
- Double:
The thickness of the character segments, or
Double.NaN
for an automatic thickness. The default value isDouble.NaN
.
CharacterSpacing
Gets or sets the spacing between characters. This is a dependency property.
public double CharacterSpacing { get; set; }
Property Value
- Double:
The spacing between characters. The default value is
5
pixels.
CharacterType
Gets or sets the type of the characters displayed. This is a dependency property.
public DigitalCharacterType CharacterType { get; set; }
Property Value
- DigitalCharacterType:
The type of the characters displayed. The default value is Segment14Normal
CharacterWidthRatio
Gets or sets the width of the characters as a ratio of the CharacterHeight. This is a dependency property.
public double CharacterWidthRatio { get; set; }
Property Value
- Double:
The character width ratio. The default value is
0.4
(40%).
DimmedBrush
Gets or sets the dimmed brush, which is used to render the unlit character segments. This is a dependency property.
public Brush DimmedBrush { get; set; }
Property Value
- Brush:
The dimmed brush. The default value is
#1E000000
.
Foreground
Gets or sets the foreground brush, which is used to render the character segments. This is a dependency property.
public Brush Foreground { get; set; }
Property Value
- Brush:
The foreground brush. The default value is
WhiteSmoke
.
LedOffOpacity
Gets or sets the opacity of the led lights when off. This is a dependency property.
public double LedOffOpacity { get; set; }
Property Value
- Double:
The opacity of the led lights when off. The default value is
0.0
.
LedOnOpacity
Gets or sets the opacity of the led lights when on. This is a dependency property.
public double LedOnOpacity { get; set; }
Property Value
- Double:
The opacity of the led lights when on. The default value is
1.0
.
LedState
Gets or sets the current state of the led lights. This is a dependency property.
public LedState LedState { get; set; }
Property Value
- LedState:
The current state of the led lights. The default value is
LedState.On
.
LogicalChildren
Gets an enumerator for logical child elements of this element.
RefreshRate
Gets or sets the refresh rate, which indicates the minimum interval between updates to the value currently being displayed. This is a dependency property.
public Duration RefreshRate { get; set; }
Property Value
- Duration:
The refresh rate. The default value is
0
milliseconds.
ScrollInterval
Gets or sets the interval used when scrolling characters. This is a dependency property.
public Duration ScrollInterval { get; set; }
Property Value
- Duration:
The interval used when scrolling characters. The default value is
500
milliseconds.
ScrollState
Gets or sets the scroll state, which determines how and when the characters should be scrolled. This is a dependency property.
public DigitalCharacterScrollState ScrollState { get; set; }
Property Value
- DigitalCharacterScrollState:
The scroll state. The default value is
DigitalCharacterScrollState.None
.
SkewAngleX
Gets or sets the skew angle along the X-axis. This is a dependency property.
public double SkewAngleX { get; set; }
Property Value
- Double:
The skew angle along the X-axis. The default value is
0
.
SkewAngleY
Gets or sets the skew angle along the Y-axis. This is a dependency property.
public double SkewAngleY { get; set; }
Property Value
- Double:
The skew angle along the Y-axis. The default value is
0
.
TextAlignment
Gets or sets the alignment of the label text. This is a read-only dependency property.
public DigitalTextAlignment TextAlignment { get; set; }
Property Value
- DigitalTextAlignment:
The alignment of the label text. The default value is
Right
.
Remarks
Valid values are Left
or Right
.
Value
Gets or sets the value displayed by the gauge. This is a dependency property.
public object Value { get; set; }
Property Value
- Object:
The value displayed by the gauge. The default value is null.
Methods
ArrangeOverride(Size)
When overridden in a derived class, positions child elements and determines a size for a FrameworkElement derived class.
protected override Size ArrangeOverride(Size finalSize)
Parameter | Type | Description |
---|---|---|
finalSize | Size | The final area within the parent that this element should use to arrange itself and its children. |
Returns
- Size:
The actual size used.
MeasureOverride(Size)
When overridden in a derived class, measures the size in layout required for child elements and determines a size for the FrameworkElement-derived class.
protected override Size MeasureOverride(Size availableSize)
Parameter | Type | Description |
---|---|---|
availableSize | Size | The available size that this element can give to child elements. Infinity can be specified as a value to indicate that the element will size to whatever content is available. |
Returns
- Size:
The size that this element determines it needs during layout, based on its calculations of child element sizes.
Fields
BlinkIntervalProperty
Identifies the BlinkInterval dependency property. This field is read-only.
public static readonly DependencyProperty BlinkIntervalProperty
CharacterCasingProperty
Identifies the CharacterCasing dependency property. This field is read-only.
public static readonly DependencyProperty CharacterCasingProperty
CharacterCountProperty
Identifies the CharacterCount dependency property. This field is read-only.
public static readonly DependencyProperty CharacterCountProperty
CharacterHeightProperty
Identifies the CharacterHeight dependency property. This field is read-only.
public static readonly DependencyProperty CharacterHeightProperty
CharacterOverflowAlignmentProperty
Identifies the CharacterOverflowAlignment dependency property. This field is read-only.
public static readonly DependencyProperty CharacterOverflowAlignmentProperty
CharacterPaddingProperty
Identifies the CharacterPadding dependency property. This field is read-only.
public static readonly DependencyProperty CharacterPaddingProperty
CharacterSegmentThicknessProperty
Identifies the CharacterSegmentThickness dependency property. This field is read-only.
public static readonly DependencyProperty CharacterSegmentThicknessProperty
CharacterSpacingProperty
Identifies the CharacterSpacing dependency property. This field is read-only.
public static readonly DependencyProperty CharacterSpacingProperty
CharacterTypeProperty
Identifies the CharacterType dependency property. This field is read-only.
public static readonly DependencyProperty CharacterTypeProperty
CharacterWidthRatioProperty
Identifies the CharacterWidthRatio dependency property. This field is read-only.
public static readonly DependencyProperty CharacterWidthRatioProperty
DimmedBrushProperty
Identifies the DimmedBrush dependency property. This field is read-only.
public static readonly DependencyProperty DimmedBrushProperty
ForegroundProperty
Identifies the Foreground dependency property. This field is read-only.
public static readonly DependencyProperty ForegroundProperty
LedOffOpacityProperty
Identifies the LedOffOpacity dependency property. This field is read-only.
public static readonly DependencyProperty LedOffOpacityProperty
LedOnOpacityProperty
Identifies the LedOnOpacity dependency property. This field is read-only.
public static readonly DependencyProperty LedOnOpacityProperty
LedStateProperty
Identifies the LedState dependency property. This field is read-only.
public static readonly DependencyProperty LedStateProperty
RefreshRateProperty
Identifies the RefreshRate dependency property. This field is read-only.
public static readonly DependencyProperty RefreshRateProperty
ScrollIntervalProperty
Identifies the ScrollInterval dependency property. This field is read-only.
public static readonly DependencyProperty ScrollIntervalProperty
ScrollStateProperty
Identifies the ScrollState dependency property. This field is read-only.
public static readonly DependencyProperty ScrollStateProperty
SkewAngleXProperty
Identifies the SkewAngleX dependency property. This field is read-only.
public static readonly DependencyProperty SkewAngleXProperty
SkewAngleYProperty
Identifies the SkewAngleY dependency property. This field is read-only.
public static readonly DependencyProperty SkewAngleYProperty
TextAlignmentProperty
Identifies the TextAlignment dependency property. This field is read-only.
public static readonly DependencyProperty TextAlignmentProperty
ValueProperty
Identifies the Value dependency property. This field is read-only.
public static readonly DependencyProperty ValueProperty
Inherited Members
- RectangularGaugeBase.BackgroundGeometryProperty
- RectangularGaugeBase.BackgroundImageSourceProperty
- RectangularGaugeBase.BackgroundSizeRatioProperty
- RectangularGaugeBase.BackgroundTypeProperty
- RectangularGaugeBase.FrameTypeProperty
- RectangularGaugeBase.GlassTypeProperty
- RectangularGaugeBase.RimGeometryProperty
- RectangularGaugeBase.RimImageSourceProperty
- RectangularGaugeBase.RimTypeProperty
- RectangularGaugeBase.OnRender(DrawingContext)
- RectangularGaugeBase.RenderFrameBackground(DrawingContext)
- RectangularGaugeBase.RenderFrameRim(DrawingContext)
- RectangularGaugeBase.BackgroundGeometry
- RectangularGaugeBase.BackgroundImageSource
- RectangularGaugeBase.BackgroundSizeRatio
- RectangularGaugeBase.BackgroundType
- RectangularGaugeBase.FrameAngle
- RectangularGaugeBase.FrameType
- RectangularGaugeBase.GlassType
- RectangularGaugeBase.RimGeometry
- RectangularGaugeBase.RimImageSource
- RectangularGaugeBase.RimType
- GaugeBase.BackgroundProperty
- GaugeBase.IsBackgroundEffectEnabledProperty
- GaugeBase.IsRimEffectEnabledProperty
- GaugeBase.OriginProperty
- GaugeBase.RimBrushProperty
- GaugeBase.UnitBaseXProperty
- GaugeBase.UnitBaseYProperty
- GaugeBase.XProperty
- GaugeBase.YProperty
- GaugeBase.GetLocation(UIElement, Size)
- GaugeBase.GetOrigin(DependencyObject)
- GaugeBase.GetX(DependencyObject)
- GaugeBase.GetY(DependencyObject)
- GaugeBase.OnCreateAutomationPeer()
- GaugeBase.OnRenderSizeChanged(SizeChangedInfo)
- GaugeBase.SetOrigin(DependencyObject, CoordinateOrigin)
- GaugeBase.SetX(DependencyObject, Unit)
- GaugeBase.SetY(DependencyObject, Unit)
- GaugeBase.ToBitmap(Double, Double)
- GaugeBase.UpdateUnitBases()
- GaugeBase.Background
- GaugeBase.IsBackgroundEffectEnabled
- GaugeBase.IsRimEffectEnabled
- GaugeBase.Items
- GaugeBase.Origin
- GaugeBase.RimBrush
- GaugeBase.UnitBaseX
- GaugeBase.UnitBaseY
- GaugeBase.X
- GaugeBase.Y
- GaugeElement.ZIndexProperty
- GaugeElement.ILogicalParent.AddLogicalChild(Object)
- GaugeElement.ILogicalParent.RemoveLogicalChild(Object)
- GaugeElement.IVisualParent.AddVisualChild(Visual)
- GaugeElement.IVisualParent.RemoveVisualChild(Visual)
- GaugeElement.GetVisualChild(Int32)
- GaugeElement.GetZIndex(UIElement)
- GaugeElement.SetZIndex(UIElement, Int32)
- GaugeElement.VisualChildren
- GaugeElement.VisualChildrenCount
- GaugeElement.ZIndex
- Object.ToString()
- Object.Equals(Object)
- Object.Equals(Object, Object)
- Object.ReferenceEquals(Object, Object)
- Object.GetHashCode()
- Object.GetType()
- Object.MemberwiseClone()