아이들은 TableRow 될 필요가 없습니다. 테이블 레이아웃은 LinearLayout, TextView, ImageButton 등 모든 유형의 자식을 지원합니다.
이미지 버튼을 TableRow에 래핑하지 마십시오. 그것을 행으로 삽입하십시오.
<TableRow>
<TextView
android:id="@+id/tv1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Example Table Row" />
</TableRow>
<ImageButton
android:id="@+id/ib1"
android:layout_width="fill_parent" <---! The Parent Is The Table Layout !--->
android:layout_height="wrap_content"
android:background="@drawable/coolBGImage" />
<TableRow>
BLAH BLAH BLAH
</TableRow>
는 버튼이 균일하게 열을 나눌 수 있도록 동일한 중량으로 다음 두 이미지 버튼을 추가 android:orientation="horizontal"
</TableRow>
<LinearLayout
android:id="@+id/LL1"
android:layout_width="fill_parent" <---! The Parent is the TableLayout !--->
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageButton
android:id="@+id/IB1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/coolBGImage1"
android:weight="1" />
사용할 하나 개의 행에있는 LinearLayout 3 ImageButtons 넣어.
</LinearLayout>
예, 아무 효과가 없습니다. 난 당신이 그것을 불필요하게 무거운 (많이는 아니지만, 그것을 할 것입니다 작동시킬 수있는 말을하는 동안 다른 접근 방식을 시도하고있다)하지만 – ikromm
당신은 레이아웃 파일이나 그것의 샘플을 게시해볼 수 있습니까? – kaspermoerch
필요 없음. 그것은 조금 더 무겁더라도 정확하게 작동합니다. 건배 :) – ikromm