Why sources letter spacing is different from documentation in Android material design?

678 Views Asked by At

I am confusing about android:letterSpacing attribute. Here https://material.io/design/typography/the-type-system.html#type-scale says that Body1 has letter spacing 0.25px , but in source code it shows 0.0178571429

enter image description here

If i need letter spacing 0.25px (or 0.15px or any other) what value should i use (or how can i calculate right value?)? <item name="android:letterSpacing">0.0178571429</item> or <item name="android:letterSpacing">0.25</item>

1

There are 1 best solutions below

0
Mukhtar Bimurat On

I found answer here How to calculate letterSpacing for TextView from sketch values? . If just divide 0.25/14 = 0.0178571429 we get letterSpacing attribute value