SpringIndicator
介绍:
使用bezier实现粘连效果的页面指示,基于BezierDemo http://jcodecraeer.com/a/opensource/2015/0203/2406.html
运行效果:
使用说明:
build.gradle依赖
dependencies {
compile 'com.github.chenupt.android:springindicator:1.0.0@aar'
}
将indicator添加到layout
<github.chenupt.springindicator.SpringIndicator
xmlns:app="http://schemas.android.com/apk/res-auto"
app:textSize="18sp"
app:indicatorColors="@array/indicator_colors"
app:textColor="@color/colorPrimaryDark"
app:selectedTextColor="@android:color/white"
app:indicatorColor="@color/colorPrimary"
android:id="@+id/indicator"
android:layout_width="match_parent"
android:layout_height="56dp"/>
将ViewPager和indicator关联
springIndicator.setViewPager(viewPager);
已下载
0