I'm beginner in android and write this code for my activity XML file:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://ift.tt/nIICcg"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent"
android:weightSum="4"
>
<ImageView
android:id="@+id/ExplainImage"
android:layout_gravity="center"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:src="@drawable/abc_btn_check_material">
</ImageView>
<TextView
android:layout_width="wrap_content"
android:layout_height="0dp"
android:textAppearance="?android:attr/textAppearanceLarge"
android:text="Large Text"
android:id="@+id/MAINLABEL"
android:layout_weight="3"
android:layout_gravity="center"
android:height="2dp" />
</LinearLayout>
and show and work good,but i want scroll text view in big text and change text view part to this:
<ScrollView
xmlns:android="http://ift.tt/nIICcg"
android:layout_height="fill_parent"
android:layout_width="fill_parent"
>
<TextView
android:layout_width="wrap_content"
android:layout_height="0dp"
android:textAppearance="?android:attr/textAppearanceLarge"
android:text="Large Text"
android:id="@+id/MAINLABEL"
android:layout_weight="3"
android:layout_gravity="center"
android:height="2dp" />
</ScrollView>
but not show text to me or image,what happen?how can i solve that?thanks.
Aucun commentaire:
Enregistrer un commentaire