Class RangeAxis
An axis that has a range.
Inheritance
Inherited Members
Namespace: System.Windows.Controls.DataVisualization.Charting
Assembly: Controls.DataVisualization.OpenSilver.dll
Syntax
public abstract class RangeAxis : DisplayAxis, IRequireSeriesHost, IRangeAxis, IAxis, IRangeConsumer, IValueMarginConsumer
Constructors
| Improve this Doc View SourceRangeAxis()
Instantiates a new instance of the RangeAxis class.
Declaration
protected RangeAxis()
Fields
| Improve this Doc View SourceMinorTickMarkStyleProperty
Identifies the MinorTickMarkStyle dependency property.
Declaration
public static readonly DependencyProperty MinorTickMarkStyleProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
Properties
| Improve this Doc View SourceActualRange
Gets or sets the actual range of values.
Declaration
protected Range<IComparable> ActualRange { get; set; }
Property Value
Type | Description |
---|---|
Range<System.IComparable> |
MinorTickMarkStyle
Gets or sets the minor tick mark style.
Declaration
public Style MinorTickMarkStyle { get; set; }
Property Value
Type | Description |
---|---|
Style |
Origin
Gets the origin value on the axis.
Declaration
protected abstract IComparable Origin { get; }
Property Value
Type | Description |
---|---|
System.IComparable |
ProtectedMaximum
Gets or sets the maximum value displayed in the range axis.
Declaration
protected IComparable ProtectedMaximum { get; set; }
Property Value
Type | Description |
---|---|
System.IComparable |
ProtectedMinimum
Gets or sets the minimum value displayed in the range axis.
Declaration
protected IComparable ProtectedMinimum { get; set; }
Property Value
Type | Description |
---|---|
System.IComparable |
Methods
| Improve this Doc View SourceCreateMinorTickMark()
Creates a minor axis tick mark.
Declaration
protected Line CreateMinorTickMark()
Returns
Type | Description |
---|---|
Line | A line to used to render a tick mark. |
GetLabelValues(Size)
Returns a sequence of values to plot on the axis.
Declaration
protected abstract IEnumerable<IComparable> GetLabelValues(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.IComparable> | A sequence of values to plot on the axis. |
GetMajorGridLineCoordinates(Size)
Returns a sequence of the major grid line coordinates.
Declaration
protected override IEnumerable<UnitValue> GetMajorGridLineCoordinates(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<UnitValue> | A sequence of the major grid line coordinates. |
Overrides
| Improve this Doc View SourceGetMajorGridLineValues(Size)
Returns a sequence of the values at which to plot major grid lines.
Declaration
protected virtual IEnumerable<IComparable> GetMajorGridLineValues(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.IComparable> | A sequence of the values at which to plot major grid lines. |
GetMajorTickMarkValues(Size)
Returns a sequence of values to plot on the axis.
Declaration
protected abstract IEnumerable<IComparable> GetMajorTickMarkValues(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.IComparable> | A sequence of values to plot on the axis. |
GetMinorTickMarkValues(Size)
Returns a sequence of values to plot on the axis.
Declaration
protected virtual IEnumerable<IComparable> GetMinorTickMarkValues(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.IComparable> | A sequence of values to plot on the axis. |
GetPlotAreaCoordinate(Object)
Returns the plot area coordinate of a given value.
Declaration
public override UnitValue GetPlotAreaCoordinate(object value)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | The value to return the plot area coordinate for. |
Returns
Type | Description |
---|---|
UnitValue | The plot area coordinate of the given value. |
Overrides
| Improve this Doc View SourceGetPlotAreaCoordinate(Object, Double)
Returns the plot area coordinate of a given value.
Declaration
protected abstract UnitValue GetPlotAreaCoordinate(object value, double length)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | The value to return the plot area coordinate for. |
System.Double | length | The length of the axis. |
Returns
Type | Description |
---|---|
UnitValue | The plot area coordinate of the given value. |
GetPlotAreaCoordinate(Object, Range<IComparable>, Double)
Returns the plot area coordinate of a given value.
Declaration
protected abstract UnitValue GetPlotAreaCoordinate(object value, Range<IComparable> currentRange, double length)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | The value to return the plot area coordinate for. |
Range<System.IComparable> | currentRange | The value range to use when calculating the plot area coordinate. |
System.Double | length | The length of the axis. |
Returns
Type | Description |
---|---|
UnitValue | The plot area coordinate of the given value. |
GetValueAtPosition(UnitValue)
Returns the value range given a plot area coordinate.
Declaration
protected abstract IComparable GetValueAtPosition(UnitValue value)
Parameters
Type | Name | Description |
---|---|---|
UnitValue | value | The plot area coordinate. |
Returns
Type | Description |
---|---|
System.IComparable | A range of values at that plot area coordinate. |
OnActualRangeChanged(Range<IComparable>)
Invalidates axis when the actual range changes.
Declaration
protected virtual void OnActualRangeChanged(Range<IComparable> range)
Parameters
Type | Name | Description |
---|---|---|
Range<System.IComparable> | range | The new actual range. |
OnObjectRegistered(IAxisListener)
If a new range provider is registered, update actual range.
Declaration
protected override void OnObjectRegistered(IAxisListener series)
Parameters
Type | Name | Description |
---|---|---|
IAxisListener | series | The axis listener being registered. |
Overrides
| Improve this Doc View SourceOnObjectUnregistered(IAxisListener)
If a range provider is unregistered, update actual range.
Declaration
protected override void OnObjectUnregistered(IAxisListener series)
Parameters
Type | Name | Description |
---|---|---|
IAxisListener | series | The axis listener being unregistered. |
Overrides
| Improve this Doc View SourceOverrideDataRange(Range<IComparable>)
Overrides the data range.
Declaration
protected virtual Range<IComparable> OverrideDataRange(Range<IComparable> range)
Parameters
Type | Name | Description |
---|---|---|
Range<System.IComparable> | range | The range to potentially override. |
Returns
Type | Description |
---|---|
Range<System.IComparable> | The overridden range. |
Render(Size)
Renders the axis labels, tick marks, and other visual elements.
Declaration
protected override void Render(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
Size | availableSize | The available size. |
Overrides
Explicit Interface Implementations
| Improve this Doc View SourceIRangeAxis.GetValueAtPosition(UnitValue)
Returns the value range given a plot area coordinate.
Declaration
IComparable IRangeAxis.GetValueAtPosition(UnitValue value)
Parameters
Type | Name | Description |
---|---|---|
UnitValue | value | The plot area coordinate. |
Returns
Type | Description |
---|---|
System.IComparable | A range of values at that plot area coordinate. |
IRangeAxis.Origin
Gets the origin value on the axis.
Declaration
IComparable IRangeAxis.Origin { get; }
Returns
Type | Description |
---|---|
System.IComparable |
IRangeAxis.Range
Gets the actual maximum value.
Declaration
Range<IComparable> IRangeAxis.Range { get; }
Returns
Type | Description |
---|---|
Range<System.IComparable> |
IRangeConsumer.RangeChanged(IRangeProvider, Range<IComparable>)
Updates the axis with information about a provider's data range.
Declaration
void IRangeConsumer.RangeChanged(IRangeProvider usesRangeAxis, Range<IComparable> range)
Parameters
Type | Name | Description |
---|---|---|
IRangeProvider | usesRangeAxis | The information provider. |
Range<System.IComparable> | range | The range of data in the information provider. |
IValueMarginConsumer.ValueMarginsChanged(IValueMarginProvider, IEnumerable<ValueMargin>)
Updates the layout of the axis to accommodate a sequence of value margins.
Declaration
void IValueMarginConsumer.ValueMarginsChanged(IValueMarginProvider provider, IEnumerable<ValueMargin> valueMargins)
Parameters
Type | Name | Description |
---|---|---|
IValueMarginProvider | provider | A value margin provider. |
System.Collections.Generic.IEnumerable<ValueMargin> | valueMargins | A sequence of value margins. |