I have a TextView
that should be 4 lines long .
First line text should be "YES"
Second Line ="No"
Third Line = "true"
Fourth line + "false"
How can this be done with a single TextView
?
I have a TextView
that should be 4 lines long .
First line text should be "YES"
Second Line ="No"
Third Line = "true"
Fourth line + "false"
How can this be done with a single TextView
?
try following for multiline TextView.
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:maxLines="4"
android:singleLine="false"
android:text="YES\nNo\ntrue\nfalse" />
You can try \n
to set text in next line.
Try this:
<TextView android:id="@+id/text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:lines="4"
android:text="YES\nNo\ntrue\nfalse" />