[]
        
(Showing Draft Content)

C1.WPF.Gauge.C1Gauge

C1Gauge Class

Base class for the Gauge controls

Inheritance
C1Gauge
Implements
IDependencyObject
Namespace: C1.WPF.Gauge
Assembly: C1.WPF.Gauge.dll
Syntax
public abstract class C1Gauge : C1View, IDependencyObject
Public MustInherit Class C1Gauge
    Inherits C1View
    Implements IDependencyObject

Constructors

Name Description
C1Gauge()

Initializes a new instance of the C1Gauge class.

Fields

Name Description
DefaultFaceBorderColor
DefaultFaceBorderWidth
DefaultFaceColor
DefaultFormat
DefaultMax
DefaultMin
DefaultMinMaxFontName
DefaultMinMaxFontSize
DefaultMinMaxOpacity
DefaultMinMaxTextColor
DefaultOrigin
DefaultPointerColor
DefaultPointerThickness
DefaultReadonly
DefaultShowRanges
DefaultStep
DefaultTextVisibility
DefaultThickness
DefaultValueFontName
DefaultValueFontSize
DefaultValueTextColor
FaceBorderBrushProperty

Identifies the FaceBorderBrush dependency property.

FaceBorderColorProperty

Identifies the FaceBorderColor dependency property.

FaceBorderDashesProperty

Identifies the FaceBorderDashes dependency property.

FaceBorderWidthProperty

Identifies the FaceBorderWidth dependency property.

FaceBrushProperty

Identifies the FaceBrush dependency property.

FaceColorProperty

Identifies the FaceColor dependency property.

FaceProperty

Identifies the Face dependency property.

FormatProperty

Identifies the Format dependency property.

IsAnimatedProperty

Identifies the IsAnimated dependency property.

IsEnabledProperty

Identifies the IsEnabled dependency property.

IsReadOnlyProperty

Identifies the IsReadOnly dependency property.

MarkBrushProperty

Identifies the MarkBrush dependency property.

MarkThicknessProperty

Identifies the MarkThickness dependency property.

MaxFontFamilyProperty

Identifies the MaxFontFamily dependency property.

MaxFontSizeProperty

Identifies the MaxFontSize dependency property.

MaxFontStyleProperty

Identifies the MaxFontStyle dependency property.

MaxFontWeightProperty

Identifies the MaxFontWeight dependency property.

MaxForegroundProperty

Identifies the MaxForeground dependency property.

MaxProperty

Identifies the Max dependency property.

MaxTextColorProperty

Identifies the MaxTextColor dependency property.

MaximumProperty

Identifies the Maximum dependency property.

MinFontFamilyProperty

Identifies the MinFontFamily dependency property.

MinFontSizeProperty

Identifies the MinFontSize dependency property.

MinFontStyleProperty

Identifies the MinFontStyle dependency property.

MinFontWeightProperty

Identifies the MinFontWeight dependency property.

MinForegroundProperty

Identifies the MinForeground dependency property.

MinProperty

Identifies the Min dependency property.

MinTextColorProperty

Identifies the MinTextColor dependency property.

MinimumProperty

Identifies the Minimum dependency property.

OriginProperty

Identifies the Origin dependency property.

PointerBrushProperty

Identifies the PointerBrush dependency property.

PointerColorProperty

Identifies the PointerColor dependency property.

PointerProperty

Identifies the Pointer dependency property.

ShowRangePointerProperty

Identifies the ShowRangePointer dependency property.

ShowRangesProperty

Identifies the ShowRanges dependency property.

StepProperty

Identifies the Step dependency property.

TextVisibilityProperty

Identifies the TextVisibility dependency property.

ThicknessProperty

Identifies the Thickness dependency property.

ValueFontFamilyProperty

Identifies the ValueFontFamily dependency property.

ValueFontSizeProperty

Identifies the ValueFontSize dependency property.

ValueFontStyleProperty

Identifies the ValueFontStyle dependency property.

ValueFontWeightProperty

Identifies the ValueFontWeight dependency property.

ValueForegroundProperty

Identifies the ValueForeground dependency property.

ValueProperty

Identifies the Value dependency property.

ValueTextColorProperty

Identifies the ValueTextColor dependency property.

_textMax

The string of Min, Max, and Value.

_textMaxRect

The rectangle of Min, Max, and Value.

_textMin

The string of Min, Max, and Value.

_textMinRect

The rectangle of Min, Max, and Value.

_textValue

The string of Min, Max, and Value.

_textValueRect

The rectangle of Min, Max, and Value.

Properties

Name Description
Decorators

Gets the collection of decorators in this gauge.

Face

Gets or sets the GaugeRange used to represent the gauge's overall geometry and appearance.

FaceBorderBrush

Gets or sets the brush of the face border.

FaceBorderColor

Gets or sets the color of the face border.

FaceBorderDashes

Gets or sets the face border dashes.

FaceBorderWidth

Gets or sets the width of the face border.

FaceBrush

Gets or sets the brush of the face.

FaceColor

Gets or sets the color of the face.

Format

Gets or sets the format string used for displaying the gauge values as text.

IsAnimated

Gets or sets whether changing the value will animate the gauge.

IsEnabled

Gets or sets whether gauge enables user interaction or not.

IsReadOnly

Gets or sets a value to determine whether the gauge is readonly.

MarkBrush

Gets or sets the brush to paint marks.

MarkThickness

Gets or sets the thickness of the marks.

Max

Gets or sets the maximum value of the gauge.

MaxFontFamily

Gets or sets the maximum value font style.

MaxFontSize

Gets or sets the maximum value font style.

MaxFontStyle

Gets or sets the maximum value font style.

MaxFontWeight

Gets or sets the maximum value font style.

MaxForeground

Gets or sets the foreground of the maximum label.

MaxTextColor

Gets or sets the color of the maximum label.

Maximum

Gets or sets the maximum value of the gauge.

Min

Gets or sets the minimum value of the gauge.

MinFontFamily

Gets or sets the minimum value font style.

MinFontSize

Gets or sets the minimum value font style.

MinFontStyle

Gets or sets the minimum value font style.

MinFontWeight

Gets or sets the minimum value font style.

MinForeground

Gets or sets the foreground of the minimum label.

MinTextColor

Gets or sets the color of the minimum label.

Minimum

Gets or sets the minimum value of the gauge.

Origin

Gets or sets the starting point used for painting the range.

Pointer

Gets or sets the GaugeRange used to represent the gauge's current value.

PointerBrush

Gets or sets the brush of the pointer.

PointerColor

Gets or sets the color of the pointer.

Ranges

Gets the collection of ranges in this gauge.

ShowRangePointer

Gets or sets whether the range pointer is shown.

ShowRanges

Gets or sets whether the gauge should display the ranges contained in the ranges property.

Step

Gets or sets a value that determines the intervals the can be set when the user interacts directly with the control. For instance if Step=25 the possible values will be 0,25,50,75,100.

TextVisibility

Gets or sets which values should be displayed as text in the gauge.

Thickness

Gets or sets the thickness of the gauge, on a scale between zero and one.

UpdateAnimation

Gets the animation used to update the value.

Value

Gets or sets the value displayed on the gauge.

ValueFontFamily

Gets or sets the value font style.

ValueFontSize

Gets or sets the value font style.

ValueFontStyle

Gets or sets the value font style.

ValueFontWeight

Gets or sets the value font style.

ValueForeground

Gets or sets the foreground of the value label.

ValueTextColor

Gets or sets the color of the value label.

Methods

Name Description
Dispose(bool)
DrawBorder()

Draw the border with BorderBrush and BorderThickness.

DrawGauge()

Draw the gauge.

DrawLabel(GaugeLabel)

Draw the specified labels.

DrawMark(GaugeMark)

Draw the specified tick mark.

DrawMinMaxText()

Draw the text of Min and Max.

DrawPointer(GaugePointer, double)

Draw the specified pointer.

DrawRange(GaugeRange, double)

Update element range.

DrawValueText(double)

Draw the text of Value.

FormatDecimal(double)

Format decimal number to the string.

GetPercent(double)

Get the value of percent.

GetPointerBrush(double)

Get point brush from the value.

GetValueFromPoint(Point)

Get gauge value from the point.

OnApplyTemplate()
OnBorderBrushChanged()
OnBorderThicknessChanged()
OnCornerRadiusChanged()
OnPaddingChanged()
OnPropertyChanged(string, object, object, bool)

Called when a property changed.

OnRender(DrawingContext)
OnValueChangedEvent(GaugeValueEventArgs)

Raises the ValueChangedEvent event.

Refresh(bool)

Refreshes the control.

Events

Name Description
Tapped

Occurs for every touch event.

ValueChanged

Raised when the property Value changed.