안드로이드 개발 질문/답변
(글 수 45,052)
제목 그대로 textView와 listView를 함께 사용하려고 하는데
textView가 사라져서 보이질 않는데 어떻게 해야하는 건가요?
textView가 사라져서 보이질 않는데 어떻게 해야하는 건가요?
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" > <TextView android:id="@+id/message" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Active process: " /> <ListView android:id="@+id/proc_list" android:layout_width="fill_parent" android:layout_height="fill_parent" /> </LinearLayout>
2010.08.19 13:43:48
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Thumbnail Test"
android:textSize="20sp"
android:gravity="center"
android:layout_marginBottom="15dip"
android:layout_marginTop="15dip"
/>
<ListView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/test"
/>
</LinearLayout>
저 같은 경우는 이렇게 썼는데 잘 나오는데요
정 안되시면 TableRow 로 텍스트뷰랑 리스트뷰를 따로따로 감싸는 방법도 있구요
listview height를 wrap_content로 바꿔보세요