Reputation: 2958
Im currently using MPAndroidChart in C# via Nuget.
I tried to build a RoundedBarChart using this reference WW-Digital/MPAndroidChart
But the issue some methods/variables for example:
In this line setBarSpace
is existing. refer MPAndroidChart
// initialize the buffer
BarBuffer buffer = mBarBuffers[index];
buffer.setPhases(phaseX, phaseY);
buffer.setBarSpace(dataSet.getBarSpace());
buffer.setDataSet(index);
buffer.setInverted(mChart.isInverted(dataSet.getAxisDependency()));
while in c# MPAndroidChart in C# via Nuget
// initialize the buffer
BarBuffer buffer = BarBuffers[index];
buffer.SetPhases(phaseX, phaseY);
///buffer.Bar(dataSet.getBarSpace());
buffer.SetDataSet(index);
buffer.SetInverted(Chart.IsInverted(dataSet.AxisDependency));
There is no BarSpace
variable or method that is existing.
The java and c# version is the same 3.0.2
If I am missing something kindly provide me insight on this.
Upvotes: 0
Views: 285
Reputation: 9084
The MPAndroidChart in C# via Nuget is different from the WW-Digital/MPAndroidChart.
The MPAndroidChart.Xamarin nuget you are using is a Xamarin.Android
binding for MPAndroidChart by Philipp Jahoda. So you should refer to this example.
There is no BarSpace variable or method that is existing.
You could use buffer.SetBarWidth()
method, usage like this :
protected IBarDataProvider mChart;
...
buffer.SetBarWidth(mChart.BarData.BarWidth);
You could refer to BarChartRenderer.
Upvotes: 1