Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Highlighting a single point in oxyplot?

I have an oxyplot winforms control that I'm using in a WPF project. The control takes in two lists (one for x values and one for y values), and plots a lineseries. I'm trying to get my WPF project to loop through these points one at a time and highlight (simple color change) each point the loop hits. However, I can't find a way to change just one point, only the entire series.

For instance:

var s1 = new LineSeries();

s1.Color = OxyColors.LightBlue;
s1.MarkerFill = OxyColors.Blue;
s1.MarkerType = OxyPlot.MarkerType.Circle;

This changes all the points in the lineseries to a light blue color, the line itself to blue, and the points to a circle shape.

There's no methods or properties to change a single point though.

like image 819
pfinferno Avatar asked May 14 '26 05:05

pfinferno


1 Answers

You could use another series where you set only the single point.

like image 189
Rabban Avatar answered May 15 '26 19:05

Rabban



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!