LiveCharts2
LiveCharts2 copied to clipboard
[Feature Request] Multi-line labels
How to reproduce?
- Create a chart with a XAxis and a serie with some DateTime values.
- Add a custom Labeler with a line break
2a. Example:
Labeler = value => new DateTime((long)value).ToString("dd.MM.yyyy ") + Environment.NewLine + new DateTime((long)value).ToString("HH:mm:ss"),
- run your test to see that the line break is replaced by a square character
Extra notes
I would expect the Labeler to allow for line break. See below how the labels get displayed:
I am using
Live-Charts version | 2.0.0-beta.101 |
.Net Version | 5.0.301 |
Windows | Windows 10 |
Hi @rteuteu55 and thanks for the issue!
The library draws the chart using SkiaSharp, and this feature is not supported by them, I really do not think SkiaSharp will ever support this, so this means that if we require multiline labels we should implement that.
I will keep this issue open as a reminder to implement this feature.
Thank you for checking that. @beto-rodriguez I would love to have a go at trying to help but would have no clue where to start. Any suggestion would be welcome!
Fixed with the referenced commit and will be included in the next version of the library,
Thanks for the report!