I Am creating Line graph with Blu color where Point also appears in blue color, what i need is to have line in one color and point in between line in another color, Thanks for any help.
Asked
Active
Viewed 113 times
0
-
You have to modify the aCahrtEngine source and recompile it, for that. – Phantômaxx Jun 16 '14 at 07:21
1 Answers
0
Probably, it is not the best idea - to modify library code - but it works. So You can add your own PointStyle enum and add color property with your_own_point_style_needed_color to ScatterChart for example. Then the last thing is to add drawing method like drawMyOwnPoint()
private void drawMyOwnPoint(Canvas canvas, SimpleSeriesRenderer renderer, Paint paint, float x, float y) {
paint.setColor(renderer.getColor());
canvas.drawCircle(x, y, size, paint);
paint.setColor(renderer.getMyOwnNeededPointColor()); //here you get your point color
canvas.drawCircle(x, y, size / 3 * 2, paint);
}
and place it in your PointStyle case clause inside public void drawLegendShape() and public void drawSeries() methods. Then from client code just set needed PointStyle and your_own_point_style_needed_color.

Sergii Kozyrev
- 121
- 3