如何使tabhost/tabwidget在Android蜂巢中垂直显示?
我想让我的标签垂直显示在左侧。我用如何使tabhost/tabwidget在Android蜂巢中垂直显示?,android,android-tabhost,Android,Android Tabhost,我想让我的标签垂直显示在左侧。我用 android:orientation="vertical" 在tabwidget中。如果我包括这个 <uses-sdk android:minSdkVersion="11"/> 在我的清单文件中,它可以很好地显示出来。但是,因为我有一个连接到internet数据库的代码,需要将版本设置为3,所以当我将版本更改为3时,无法显示选项卡 <TabHost xmlns:android="http://schemas.android.com
android:orientation="vertical"
在tabwidget中。如果我包括这个
<uses-sdk android:minSdkVersion="11"/>
在我的清单文件中,它可以很好地显示出来。但是,因为我有一个连接到internet数据库的代码,需要将版本设置为3,所以当我将版本更改为3时,无法显示选项卡
<TabHost
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@android:id/tabhost"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<LinearLayout android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TabWidget android:id="@android:id/tabs"
android:layout_height="match_parent"
android:layout_width="380dip"
android:layout_weight="0"
android:orientation="vertical"
android:background="#ffe185"
/>
<FrameLayout android:id="@android:id/tabcontent"
android:layout_height="match_parent"
android:layout_width="0dip"
android:layout_weight="1"
android:background="#ffffff"/>
</LinearLayout>
</TabHost>
match_parent直到API 8才可用。尝试用填充父对象替换。如果只返回API 4,则可以使用