-2

Code example:

    <TextView
        android:id="@+id/text_view_name"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="center_horizontal"
        android:layout_marginTop="8dp"
        android:layout_marginBottom="8dp"
        android:text="Name"
        android:textColor="@android:color/black"
        android:textSize="20sp"
        android:textStyle="bold" />

How can I change the font, but not activity in the Fragment?

Tim
  • 41,901
  • 18
  • 127
  • 145
coding123
  • 27
  • 7
  • 1
    Possible duplicate of [Android - Using Custom Font](https://stackoverflow.com/questions/3651086/android-using-custom-font) – Robin Vinzenz Dec 18 '18 at 17:49

1 Answers1

0

Just add this line

android:fontFamily="@font/hind_bold"

replace your fount name with hind_bold

M.Bilal Murtaza
  • 1,757
  • 2
  • 10
  • 8