0

我已经使用如下所示的自定义样式实现了动作条 sherlock

  <resources>
  <style name="MyTheme" parent="Theme.Sherlock">
  <item name= "actionBarStyle">@style/ActionStyle</item>
  <item name="actionBarTabTextStyle">@style/MyTabTextStyle</item>
  <item name="android:actionBarTabTextStyle">@style/MyTabTextStyle</item>
  </style>
  <style name= "ActionStyle" parent="Widget.Sherlock.ActionBar">
   <item name="android:background">#ff000000</item>
   <item name="background">#ff000000</item>
  </style>
 <style name="MyTabTextStyle" parent="Widget.Sherlock.ActionBar.TabText" >
 <item name="android:textColor">#0EBFE9</item>
 <item name = "android:showDividers">none</item>
<item name ="android:textStyle">bold</item>
<item name = "android:divider">#000000</item>

</style>
</resources>

即使将背景设置为黑色,操作栏也会在操作栏和导航选项卡之间显示蓝色分隔线。我已将显示分隔符指定为无,但导航包含选项卡之间的分隔符。

4

1 回答 1

2

You need to Inherit the Parent Theme TabBar, not TabText:

Widget.Sherlock.ActionBar.TabBar

This way:

<style name="Theme.mActionBarTabBar" parent="Widget.Sherlock.ActionBar.TabBar">
    <item name="android:showDividers">none</item>
</style>
于 2013-02-07T08:14:33.977 回答