Skip to content

Repository files navigation

RoundedHorizontalProgressBar

Download

RoundedHorizontalProgressBar - An Android custom rounded Progress Bar that supports different Colors as progress both primary & background colors. Allows you to animate the progress for a specific duration

Gradle

dependencies {
...
compile'com.sasank.roundedhorizontalprogress:roundedhorizontalprogress:1.0.1'
}

Usage

  • In XML layout:
 <com.sasank.roundedhorizontalprogress.RoundedHorizontalProgressBar
android:id="@+id/progress_bar_1"style="?android:attr/progressBarStyleHorizontal"android:layout_width="200dp"android:layout_height="wrap_content"android:indeterminate="false"android:maxHeight="12dp"android:minHeight="12dp"android:progress="40"app:backgroundColor="@color/green_light"app:progressColor="@color/green"/>
  • If the progress Bar needs to be horizontal
 <com.sasank.roundedhorizontalprogress.RoundedHorizontalProgressBar
android:id="@+id/progress_bar_1"
--------------------------------
app:backgroundColor="@color/green_light"app:progressColor="@color/green"app:isRounded="false"/>
  • All customizable attributes of the View:
 <declare-styleablename="RoundedHorizontalProgress">
<attrname="backgroundColor"format="color"/>
<attrname="progressColor"format="color"/>
<attrname="isRounded"format="boolean"/> <!-- Default Value is true(Rounded) -->
</declare-styleable>
  • Animating the view progress
mRoundedHorizontalProgressBar.animateProgress(2000, 0, 80); // (animationDuration, oldProgress, newProgress)

Sample

  • Clone the repository and check out the app module.

About

RoundedHorizontalProgressBar - An Android custom rounded Progress Bar that supports different Colors as progress both primary & background colors. Allows you to animate the progress for a specific duration

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages