alibaba / UltraViewPager

UltraViewPager is an extension for ViewPager to provide multiple features in a single ViewPager.
MIT License
5k stars 680 forks source link

请问一下,如何正常显示圆角 #101

Closed Sunxyao closed 5 years ago

Sunxyao commented 6 years ago

设置了圆角,只要滑动就会变成直角

MikeAfc commented 6 years ago

麻烦再多提供一些信息

Sunxyao commented 6 years ago

用作banner,设置了viewpager以及图片的background圆角,滑动下一页过程中会变成直角

gp888 commented 5 years ago

用CardView包一下? <android.support.v7.widget.CardView android:layout_width="match_parent" android:layout_height="wrap_content" xmlns:app="http://schemas.android.com/apk/res-auto" app:cardCornerRadius="@dimen/dimens_5" app:cardUseCompatPadding="false" app:cardElevation="0px" android:layout_marginStart="@dimen/dimens_12" android:layout_marginEnd="@dimen/dimens_12">

    <com.tmall.ultraviewpager.UltraViewPager
        android:id="@+id/ultra_viewpager"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:layout_constraintTop_toTopOf="parent" />

</android.support.v7.widget.CardView>