Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.
Just started learning how to use Vaadin Charts. I am creating a simple line chart with categories for x-axis.
The tick marks for the x-axis are not displayed. Following is my simple code
XAxis x = new XAxis(); x.setCategories("07-2014", "08-2014","09-2014","10-2014","11-2014","12-2014","01-2015","02-2015","03-2015","04-2015","05-2015","06-2015","07-2015"); x.setTickmarkPlacement(TickmarkPlacement.ON);
I haven't tested it but I think it depends on the theme you're using, the theme by default is ValoLightTheme which has disabled tickmarks by design.
You should be able to enable them by doing:
If you want to do it for all the charts you can change the theme doing:
To change only this you could also extend ValoLightTheme and override the setAxisDefaults method
Hope it helps
The documentation is a little misleading since it says that the tick mark color by default is #C0D0E0 and the tick mark default width is 1 and the tick length default is 5. So by default if the background is dark then the tick marks should show automatically with the default settings. I have it working by setting the tick mark color to some other color.