Android 如何使用样式更改选项卡小部件文本颜色?
我的应用程序使用ActionBarSherlock 应用程序主题是theme.Sherlock.Light.DarkActionBar(像Holo.Light.DarkActionBar) 我需要2个深度标签(1个深度标签是动作栏标签),所以我制作了TabHost和TabWidget layout.xmlAndroid 如何使用样式更改选项卡小部件文本颜色?,android,android-layout,Android,Android Layout,我的应用程序使用ActionBarSherlock 应用程序主题是theme.Sherlock.Light.DarkActionBar(像Holo.Light.DarkActionBar) 我需要2个深度标签(1个深度标签是动作栏标签),所以我制作了TabHost和TabWidget layout.xml <TabHost xmlns:android="http://schemas.android.com/apk/res/android" android:id="@andr
<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="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout android:id="@android:id/tabcontent"
android:visibility="invisible"
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_weight="0"/>
<FrameLayout android:id="@+android:id/realtabcontent"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
<TabWidget android:id="@android:id/tabs"
**style="@style/TabWidget**
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0"/>
</LinearLayout>
</TabHost>
<style name="TabWidget">
<item name="android:background">@color/holo_gray_dark</item>
*==> works fine light(default)->dark*
<item name="android:textColor">@color/android_white</item>
<item name="android:textColorHint">@color/android_white</item>
<item name="android:textColorHighlight">@color/android_white</item>
<item name="android:textColorLink">@color/android_white</item>
*==> these did not work...*
</style>