Skip to content

🐥A loading(progress) view that you can select different shapes.

License

Notifications You must be signed in to change notification settings

samlss/JumboLoadingView

Repository files navigation

JumboLoadingView

A loading(progress) view that you can select different shapes.


Api reqeust MIT Licence Blog

screenshot_circle screenshot_square screenshot_triangel screenshot_star

Use

Add it in your root build.gradle at the end of repositories:

allprojects {
    repositories {
        //...
        maven { url 'https://jitpack.io' }
    }
}

Add it in your app build.gradle at the end of repositories:

dependencies {
    implementation 'com.github.samlss:JumboLoadingView:1.0'
}

Attributes description:

attr description
circleColor set the color of the bigger circle
showProgress set if show progress, the default is not to show
progress set progress(0-100)
progressTextColor set the color of progress text
progressTextSize set the size of progress text
shapeColor set the color of shape
shapeType set the type of shape,includes: circle,square,triangle,star
shapeStyle style of the shape,includes: stoke,fill
interpolator the animation interpolator

interpolator:

  • AccelerateDecelerateInterpolator
  • AccelerateInterpolator
  • DecelerateInterpolator
  • BounceInterpolator
  • CycleInterpolator
  • LinearInterpolator
  • AnticipateOvershootInterpolator
  • AnticipateInterpolator
  • OvershootInterpolator

in layout.xml:

  <com.iigo.library.JumboLoadingView
            app:shapeType="star"
            app:showProgress="true"
            app:interpolator="OvershootInterpolator"
            app:progressTextColor="@color/colorPrimary"
            app:progressTextSize="18sp"
            android:layout_width="100dp"
            android:layout_height="100dp"
            android:layout_marginTop="20dp"
            app:circleColor="@color/colorPrimary"
            app:shapeColor="@color/colorPrimary" />

in java code:

   jumboLoadingView.start(); //start animation
   jumboLoadingView.stop(); //stop animation
   jumboLoadingView.release(); //release,generally call in the activity's destroy().
   
   jumboLoadingView.setCircleColor(Color.RED); //set the color of the bigger circle
   jumboLoadingView.setShapeColor(Color.RED); //set the color of shape
   jumboLoadingView.setProgressTextColor(Color.RED); //set the color of progress text
   jumboLoadingView.setProgressTextSize(12); //set the size of progress text
   jumboLoadingView.setProgress(99); // set progress

About

🐥A loading(progress) view that you can select different shapes.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages