mit-cml / appinventor-sources

MIT App Inventor Public Open Source
http://appinventor.mit.edu/appinventor-sources/
Apache License 2.0
1.49k stars 2.08k forks source link

Chart and ChartData2D Do Not Offer PointShape in Line Graph Mode #2788

Open bobparks opened 1 year ago

bobparks commented 1 year ago

Describe the desired feature When Chart is set to scatter, several options for the PointShape appear in the properties for the ChartData2D component. But when line is chosen, the options disappear.

Give an example of how this feature would be used In some cases, especially when superimposing two line charts on top of one another, it would be nice to differentiate using these alternate point shapes. @stezelMIT, @anqizzz8989

Why doesn't the current App Inventor system address this use case?

Why is this feature beneficial to App Inventor's educational mission?

halatmit commented 1 year ago

Let's be careful about making this interface overly complicated, with too many options and too many properties An alternative might be to have just a couple of standard patterns, possibly with a way to modify them.

ewpatton commented 1 year ago

Unfortunately, MPAndroidChart, the library we use for rendering the chart, does not support changing the shapes of the line points so it's unlikely we'll be able to add this in the near future.

dhruvpatidar359 commented 1 year ago

Hello @ewpatton sir , for that we can try this in the MpAndroidChart library-----

Data points are drawn in the protected void drawCircles(Canvas c) method, in the LineChartRenderer class, and X and Y coordinates for drawing are calculated for you, so just replace the c.drawCircle commands at the end of the method by drawing anything else you want, while using the same X and Y coordinates, and you're done.

we can mondify the library for ourself and get the result .