ongakuer / CircleIndicator

A lightweight indicator like in nexus 5 launcher
Apache License 2.0
4.27k stars 712 forks source link

Changing the size of the indicator icon #163

Open dukay159 opened 2 years ago

dukay159 commented 2 years ago

I am used ViewPager2 and CircleIndicator 3 for my image slider but the size of the unselected and selected icons isn't equal.

image

This is my code:

<me.relex.circleindicator.CircleIndicator3
        android:layout_width="match_parent"
        android:layout_height="30dp"
        android:layout_gravity="center"
        app:ci_drawable="@drawable/ic_indicator"
        app:ci_drawable_unselected="@drawable/ic_indicator_unselected"
        app:ci_height="8dp"
        app:ci_width="8dp"
        app:ci_margin="8dp"/>

Anyone knows how to set size for the indicator icons? Any help will be appreciated. Thanks!

CongNguyenWiki commented 2 years ago

How to change this by code java?

Xyan-Banan commented 1 year ago

this behaviour is because of animator. change ci_animator to some animator that does not interact with size of indicator

hormesiel commented 1 year ago

Duplicate of #56