Jak zrobić część tekstu Bold w Androidzie w czasie wykonywania?
A ListView
w mojej aplikacji jest wiele elementów typu stringname
, experience
, date of joining
itd. Chcę tylko zrobićname
pogrubienie. Wszystkie elementy smyczkowe będą w jednymTextView
.
mój XML:
<ImageView
android:id="@+id/logo"
android:layout_width="55dp"
android:layout_height="55dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:layout_marginTop="15dp" >
</ImageView>
<TextView
android:id="@+id/label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toRightOf="@id/logo"
android:padding="5dp"
android:textSize="12dp" >
</TextView>
Mój kod, aby ustawić TextView elementu ListView:
holder.text.setText(name + "\n" + expirience + " " + dateOfJoininf);