Это мой код для создания вкладок (внизу), работает нормально.
<?xml version="1.0" encoding="utf-8"?>
<TabHost xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@android:id/tabhost"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<TabWidget
android:id="@android:id/tabs"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true" />
<FrameLayout
android:id="@android:id/tabcontent"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:padding="5dp">
<LinearLayout
android:id="@+id/tab1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:elevation="10dp"
android:orientation="vertical">
<!-- Tab 1 content -->
<include layout="@layout/tab1" />
</LinearLayout>
<LinearLayout
android:id="@+id/tab2"
android:layout_width="match_parent"
android:layout_height="450dp"
android:orientation="vertical">
<!-- Tab 2 content -->
<include layout="@layout/tab2" />
</LinearLayout>
</FrameLayout>
</RelativeLayout>
</TabHost>
Я добавил свойство высоты несколькими способами (для вкладок, tabHost, для макета ...)и ни один из них не работает.Я нашел некоторые решения здесь, но ни одно не работает для меня.Есть идеи для этого конкретного кода?