2

I'm trying to use the AppCompat library and I'm getting some errors on the following style items:

<item name="android:dividerPadding">10dp</item>
<item name="android:showDividers">middle</item>

android:dividerPadding requires API level 11 (current min is 10)    styles.xml  /project/res/values line 85 Android Lint Problem
android:showDividers requires API level 11 (current min is 10)  styles.xml  /project/res/values line 86 Android Lint Problem

I've added the library with resources as a project in eclipse using the instructions here: http://developer.android.com/tools/support-library/setup.html

I'm also using the ViewPageIndicator project found here: https://github.com/JakeWharton/Android-ViewPagerIndicator.

This is the full style hierarchy:

<style name="Widget">
</style>

<style name="Widget.TabPageIndicator" parent="Widget">
    <item name="android:gravity">center</item>
    <item name="android:background">@drawable/vpi__tab_indicator</item>
    <item name="android:paddingLeft">22dip</item>
    <item name="android:paddingRight">22dip</item>
    <item name="android:paddingTop">12dp</item>
    <item name="android:paddingBottom">12dp</item>
    <item name="android:textAppearance">@style/TextAppearance.TabPageIndicator</item>
    <item name="android:textSize">12sp</item>
    <item name="android:maxLines">1</item>
</style>


<style name="CustomTabPageIndicator" parent="Widget.TabPageIndicator">
    <item name="android:background">@drawable/custom_tab_indicator</item>
    <item name="android:textAppearance">@style/CustomTabPageIndicator.Text</item>
    <item name="android:textColor">#FF555555</item>
    <item name="android:textSize">16sp</item>
    <item name="android:divider">@drawable/custom_tab_indicator_divider</item>
    <item name="android:dividerPadding">10dp</item> // ERROR HERE
    <item name="android:showDividers">middle</item> // ERROR HERE
    <item name="android:paddingLeft">8dp</item>
    <item name="android:paddingRight">8dp</item>
    <item name="android:fadingEdge">horizontal</item>
    <item name="android:fadingEdgeLength">8dp</item>
</style>

Any help in resolving this is greatly appreciated. I thought the AppCompat library would be ok with these newer resources?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
span
  • 5,405
  • 9
  • 57
  • 115

1 Answers1

3

Happens to me every time. You just have to clean and build project again in Eclipse, since these are Lint warnings. Please refer to this question for more info.

Community
  • 1
  • 1
Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62