ConvertToVerticalPixels()
<< Click to Display Table of Contents >> ConvertToVerticalPixels() |
Used to convert the cursor position (pixels) to device pixels represented on the Y axis of the chart. This method would only be needed if the value you are given is provided in WPF pixel point (such as the data point used in OnMouseDown), but you would need the value in the chart's rendered pixels. This is useful when handling drawing tools and charts which would have multiple chart panels.
An int value representing the converted value in device pixels
ConvertToVerticalPixels(ChartControl chartControl, ChartPanel chartPanel, double wpfY)
chartControl |
A ChartControl representing the x-axis |
chartPanel |
A ChartPanel representing the the panel for the chart |
wpfY |
A double value which needs to be converted |
public override void OnMouseDown(ChartControl chartControl, ChartPanel chartPanel, ChartScale chartScale, ChartAnchor dataPoint) |