How do I change the text view on Android?

Asked 1 years ago, Updated 1 years ago, 96 views

I want to put a line change in the text view in xml, but \n doesn't work properly when I see it as a visual editor. What should I do?

<TextView
   android:id="@+id/txtTitlevalue"
   android:text="Line1: \n-Line2\n-Line3"
   android:layout_width="54dip"
   android:layout_height="fill_parent"
   android:textSize="11px" />

textview android newline

2022-09-21 23:14

1 Answers

Check with a device or emulator, not a visual editor. It works well.


2022-09-21 23:14

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.