Table of Contents

Class LineSeriesCursor

Namespace
LightningChartLib.WinForms.Charting.Views.ViewXY
Assembly
LightningChart.WinForms.Charting.NET4.dll

Line series cursor allows tracking and evaluating line series values

public class LineSeriesCursor : DraggableObject, IChartNode, IHighlightingItem, IDisposable
Inheritance
LineSeriesCursor
Implements
Inherited Members

Remarks

Tracking and values evaluation is available only for series implementing ITrackable

Constructors

LineSeriesCursor()

Simple constructor for Form designer's list editor.

public LineSeriesCursor()

LineSeriesCursor(ViewXY, AxisX)

Constructor.

public LineSeriesCursor(ViewXY owner, AxisX axisX)

Parameters

owner ViewXY

Parent.

axisX AxisX

x-axis

Properties

AssignXAxisIndex

Index of X-axis assigned to this cursor.

public int AssignXAxisIndex { get; set; }

Property Value

int

Behind

Is cursor behind series or front.

public bool Behind { get; set; }

Property Value

bool

FullHeight

Full cursor height. If true, the cursor height will be the height of the control. If false, the cursor is vertically painted in the graph area only.

public bool FullHeight { get; set; }

Property Value

bool

GrabPadding

Grab padding is used to widen the active area. The area is widened on both sides the specified amount.

public double GrabPadding { get; set; }

Property Value

double

HairCrossColorMixing

Use cursor and dataseries colors or just cursor color for haircross.

public bool HairCrossColorMixing { get; set; }

Property Value

bool

IndicateTrackingYRange

When Cursor style is set to 'TrackSeries', and multiple series values hit on same cursor X position, adjusts series tracking horizontal line height to match the minimum and maximum value on current cursor position.

public bool IndicateTrackingYRange { get; set; }

Property Value

bool

LineStyle

Line style.

public LineStyle LineStyle { get; set; }

Property Value

LineStyle

OwnerView

Owner view

[Browsable(false)]
public ViewXY OwnerView { get; }

Property Value

ViewXY

SnapToPoints

When moving the cursor, jumps the cursor to nearest series point.

public bool SnapToPoints { get; set; }

Property Value

bool

SolveYValue

Override LineSeriesCursor's Y-value solving/tracking method. Func (predefined generic) delegate type can be used with an anonymous method or lambda expression. Input parameter is series, which implements ITrackable interface. Output parameter is LineSeriesCoordinateSolveResult struct.

public Func<ITrackable, LineSeriesCoordinateSolveResult?> SolveYValue { get; set; }

Property Value

Func<ITrackable, LineSeriesCoordinateSolveResult?>

Style

Cursor style.

public CursorStyle Style { get; set; }

Property Value

CursorStyle

ThinHairCross

Draw haircross horizontal line as 1px width, otherwise as wide as vertical.

public bool ThinHairCross { get; set; }

Property Value

bool

TrackLineSeries

Predicate to determine if the cursor should draw/resolve TrackPoint for a series implementing ITrackable interface.

public Predicate<ITrackable> TrackLineSeries { get; set; }

Property Value

Predicate<ITrackable>

TrackPoint

Tracking point style. Applies only when Style is set to PointTrack.

public PointShapeStyle TrackPoint { get; set; }

Property Value

PointShapeStyle

ValueAtXAxis

X-value.

public double ValueAtXAxis { get; set; }

Property Value

double

Visible

Is cursor visible or not

public bool Visible { get; set; }

Property Value

bool

Methods

Dispose(bool)

Clean up any resources being used.

protected override void Dispose(bool disposing)

Parameters

disposing bool

true if managed resources should be disposed, otherwise false.

IsPositionOver(int, int, bool)

Is position over item.

public override bool IsPositionOver(int x, int y, bool useDIP = false)

Parameters

x int

x-coordinate

y int

y-coordinate

useDIP bool

Use DIP instead of pixels as parameters

Returns

bool

true if position is over item, false otherwise

SetProperCursor()

Set proper cursor. Default for dragging is VSplit.

public override void SetProperCursor()

ToString()

Convert class description to string.

public override string ToString()

Returns

string

Class description as a string.

Events

PositionChanged

Cursor position on X-axis has changed.

public event LineSeriesCursor.PositionChangedEventHandler PositionChanged

Event Type

LineSeriesCursor.PositionChangedEventHandler