LoadIndicators
LoadIndicators copied to clipboard
Load indicators library
Load Indicators - Android library
Overview
Load Indicators is an Android library that takes a sprite animation and plays it in a view. Play a sprite animation with ease on Android.
Sample app available in store:
Download
Add jitpack.io respository to the project-level build.gradle file.
allprojects {
repositories {
...
maven { url "https://jitpack.io" }
}
}
add the library to your app dependencies block:
dependencies {
...
implementation 'com.github.adrian110288:LoadIndicators:1.1.1'
}
Usage
Add LoaderView to your xml layout:
<com.loadindicators.adrianlesniak.library.LoaderIndicator
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
Use a number of custom attributes on the view to adjust look and feel of your sprint animation:
-
app:loader_srcA drawable resource that represents a sprint animation. It is advised that PNG format is used. Refer
-
app:loader_frameDurationAn integer value that represents a duration of each frame in the animation.
-
app:loader_frameCountAn integer value that represents a number of frames in the animation. The field must be larger that 0 and it is mandatory. Also ensure the correct number of frames is added.
-
app:loader_autoStartA boolean value that, when set to
true, will auto play animation when used in xml layout. -
app:loader_canLoopA boolean value controlling looping behavior.
-
app:loader_loopInReverseA boolean value that allows the unwinding animation to be played, if
app:loader_canLoopis also set totrue.
Refer to sample app in the repository for example sprint animations.
Important!
Sprint animations are downloadable for free from Icons 8 Preloaders. Configure your sprint animations using the website, download the sprint as PNG and drop it into drawable folder of you app.
For any help regarding the usage of the library or the website, do not hesitate to contact me or create an issue on Github.

