CounterAnimationTextView

Additional

Language
Kotlin
Version
1.0.1 (Mar 26, 2021)
Created
Mar 26, 2021
Updated
Mar 26, 2021
Owner
Hamza Khan (hamzaahmedkhan)
Contributor
Hamza Khan (hamzaahmedkhan)
1
Activity
Badge
Generate
Download
Source code

Announcement

CounterAnimationTextView

A tiny Android library makes very easier count animation of TextView.

Usage

Include the CounterAnimationTextView widget in your layout.

      <com.github.hamzaahmedkhan.counteranimationtextview.CountAnimationTextView
          android:id="@+id/moneyPositive"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="0"
          android:textColor="@color/black"
          android:textSize="20sp" />

Animate Count with Duration

    counterAnimationTextView
        .setAnimationDuration(5000)
        .countAnimation(0, 99999)

Animate Count with DecimalFormat

    counterAnimationTextView
        .setDecimalFormat(new DecimalFormat("###,###,###"))
        .setAnimationDuration(10000)
        .countAnimation(0, 9999999)

Animate Count with interPolator

    counterAnimationTextView
        .setInterpolator(AccelerateInterpolator())
        .countAnimation(0, 9999999)

Gradle

Add the dependency to your build.gradle.

dependencies {
 implementation 'com.github.hamzaahmedkhan:CounterAnimationTextView:1.0.1'
}

If this project helps you in anyway, show your love ❤️ by putting a on this project ✌️ ........ ALSO FEEL FREE TO FORK AND CONTRIBUTE!!