Which is the best way to use Google Sans on my Android Compose app?


I want to use Google Sans on my basic Android app.

On my Pixel, the system apps use Google Sans Flex, but the default system font is still Roboto. I noticed Google Sans Flex is under /product/fonts, so I wonder if apps can use it. I want to use the default font like Mi Sans on other OEMs

Is there any way I can use the font asking the system or do I have to bundle it on my resources?

I also noticed some apps use Google Sans only on Pixel without bundling it, but they are based on plain views without Material Libs

I tried Typeface.create("Google Sans Flex", Typeface.normal) but didn't work

-1
Nov 28 at 1:50 PM
User AvatarMiguel Soto
#android#material-ui#fonts#android-jetpack-compose#material-design

No answer found for this question yet.