helllo,我尝试创建标签视图必须有一些元素在我的情况下他们是seekbar和水平线性布局与2 textview,但它只显示这样的元素在顶部。 这样的形象在:此选项卡的标签主机不显示所有元素
XML代码:
<LinearLayout
android:id="@+id/tvTab2"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
>
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:text="@string/bspa_count_of_hours"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
</TextView>
<TextView
android:id="@+id/bspa_count_of_hours_value"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
</TextView>
</LinearLayout>
<SeekBar
android:id="@+id/bspa_seekbar_count_of_hours"
android:layout_width="match_parent"
android:layout_height="wrap_content"
/>
</LinearLayout>
'机器人:layout_height = “match_parent”'应该是' android:layout_height =“wrap_content”内部的LinearLayout填充父项。 –