Hi,
I have a Primefaces 10.0.0 Linechart in my Application and I don't want this fancy polishing thing it does by default.
If I have the values 330, 350, 340 it does a tiny leap at the point after the 350 which looks like a 351, but there are no 351.
Is there a way to draw the lines from point to point in a hard way?
Like in the Radar Example?
And while I'm asking:
Is there or will there be a way to submit the data via JSON to the chart?
I've seen that many other frameworks for charts work with a JSON model, so it would be easier for anybody if I see in future, that the primfaces datachart possibilities are too limited, I can always switch to a chartframework with more possibilities.
Thanks for your reply.
Hard Corners in Linecahrt
PrimeFaces just uses Charts.js under the covers so for your line issue you might want to start there!
See: https://www.chartjs.org/
Anything you can do with Charts.js you can do with PF I would think. And at my company we use HighCharts for our charts in JSF and we send the JSON data directly from our app to the HighCharts charts. Just an FYI.
See: https://www.chartjs.org/
Anything you can do with Charts.js you can do with PF I would think. And at my company we use HighCharts for our charts in JSF and we send the JSON data directly from our app to the HighCharts charts. Just an FYI.
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1
You mean this? https://www.chartjs.org/docs/latest/sam ... ation.html
Every one of those options should be available in the Java model backing your chart which gets turned into JSON values to configure the chart.
For example the value in the dataset cubicInterpolationMode: 'monotone', you can set right in the LineChartDataSet see here:
https://github.com/primefaces/primeface ... t.java#L52
Every one of those options should be available in the Java model backing your chart which gets turned into JSON values to configure the chart.
For example the value in the dataset cubicInterpolationMode: 'monotone', you can set right in the LineChartDataSet see here:
https://github.com/primefaces/primeface ... t.java#L52
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1
My fault. I had seen this option but didn't use it because of the String parameter. I think an ENUM would have done better. So you don't have to crawl the documentation to find which values are accepted.
By searching those accepted values I've found that the option I'm looking for is tension which can be set by giving an int value, which is much easier than searching for the correct string which does the magic.
So if any programmer is reading this. Try switching the cubicInterpolationMode to an ENUM.
By searching those accepted values I've found that the option I'm looking for is tension which can be set by giving an int value, which is much easier than searching for the correct string which does the magic.
So if any programmer is reading this. Try switching the cubicInterpolationMode to an ENUM.
-
- Information
-
Who is online
Users browsing this forum: No registered users and 22 guests