Skip to content

Index of dragged point in the ScatterPlotDraggable #2682

@mocakturk

Description

@mocakturk

ScottPlot Version: 4.1.64

Operating System: Win10

Application Type: WinForms

Question: IDraggable interface contains Dragged and DragSnap possibility to fix the coordinate of the dragged point.
However, it is not possible to know dragged point's index.

public Coordinate Snap(Coordinate value)
{
    // "value" is the coordinate after dragging
    // what is the index of this coordinate inside whole plot?
    // or, what is the coordinate before dragging?
    ...
}

I'm using ScatterPlotListDraggable as Plot type.
When I check ScatterPlotListDraggable class, I can see the dragged index as private variable.

private int IndexUnderMouse { get; set; } = -1;

Perhaps, it can be public.

Thanks for this awesome library.
Murat

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions