【发布时间】:2020-08-06 17:07:00
【问题描述】:
我有这个TextView
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/tv"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="12dp"
android:contentDescription="...."
android:text="text"
android:textAllCaps="true"
android:textColor="@color/black4"
android:textSize="16sp"
app:fontFamily="@font/lato_regular"/>
如果我使用android:fontFamily,它不会设置正确的字体。 android: 和 app: 版本有什么区别。还有当我设置app:font="@font/lato_regular" 时会发生什么?
【问题讨论】:
-
'preloaded_fonts.xml'文件夹中有你的字体吗?
标签: android font-family