Open tien opened 1 month ago
Hello! This behavior is expected. As described here, with HorizontalLayout.Segmented
—which is the default—ticks are displayed at the edges of the segments. Since the ticks aren’t tied to the labels, they’re unaffected by the label spacing. The tick positioning depends on the segment count, which in turn is influenced by the x step.
To achieve the result you’re looking for, please apply HorizontalLayout.FullWidth
. As per its documentation, there will then be as many ticks as there are labels, and each tick will be directly above its label.
The AxisItemPlacer.Horizontal.default
documentation appears to describe spacing
somewhat imprecisely. The HorizontalLayout
dependence should be mentioned. This will be corrected.
Thanks for the quick response @patrickmichalik, please close this issue or use it to track documentation around spacing
, which ever make sense to you 🙏.
You’re welcome! We plan on using it to track the documentation update—I’ve applied the “documentation error” label. Cheers!
Thank you sir, just bought you a ☕️. Keep up the great work!
Thanks a lot for your support, @tien!
How to reproduce
Use bottom axis item placer with custom spacing.
Observed behavior
Tick appeared for all steps while label correctly respect spacing value.
Expected behavior
Tick should only appear every
n
spacing.Vico version(s)
1.15.0
Android version(s)
VanillaIceCream
Screenshot