admin管理员组

文章数量:1305377

This issue persists in the JakeWharton/ViewPagerIndicator, specifically in the CirclePageIndicator.

<com.viewpagerindicator.CirclePageIndicator
android:id="@+id/blogindicator"
android:layout_width="match_parent"
android:layout_height="10dp"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
app:centered="true"
app:fillColor="@color/black"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/txtblogname"
app:pageColor="@color/white"
app:snap="false"
/>

The error logs are like this:

AAPT: error: attribute pageColor (aka com.package:pageColor) not found.
AAPT: error: attribute snap(aka com.package:snap) not found.
AAPT: error: attribute fillColor(aka com.package:fillColor) not found.
AAPT: error: attribute centered(aka com.package:centered) not found.

What I tried:

  1. I checked that I was inserting the appropriate namespace:

     xmlns:app=";
    
  2. I tried using vpi name space:

    xmlns:vpi="; vpi:snap="false"

This issue persists in the JakeWharton/ViewPagerIndicator, specifically in the CirclePageIndicator.

<com.viewpagerindicator.CirclePageIndicator
android:id="@+id/blogindicator"
android:layout_width="match_parent"
android:layout_height="10dp"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
app:centered="true"
app:fillColor="@color/black"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/txtblogname"
app:pageColor="@color/white"
app:snap="false"
/>

The error logs are like this:

AAPT: error: attribute pageColor (aka com.package:pageColor) not found.
AAPT: error: attribute snap(aka com.package:snap) not found.
AAPT: error: attribute fillColor(aka com.package:fillColor) not found.
AAPT: error: attribute centered(aka com.package:centered) not found.

What I tried:

  1. I checked that I was inserting the appropriate namespace:

     xmlns:app="http://schemas.android/apk/res-auto"
    
  2. I tried using vpi name space:

    xmlns:vpi="http://schemas.android/apk/res-auto" vpi:snap="false"

Share Improve this question asked Feb 3 at 18:26 Hassaan J.Hassaan J. 1502 silver badges7 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 1

After a many attempts at solving the problem, my last resort was using a cloned project of the same library inside another repository: Add this to build.gradle (app)

    implementation 'fr.avianey.viewpagerindicator:library:2.4.1.1@aar'

Add this to build.gradle (module)

        mavenCentral()

本文标签: