Create Progres Layout with Kotlin


Source link: https://github.com/JDevZone/FillProgressLayout

Here a library for creating progress bar layout. We can use it as animation progress for our project. This library writing with Kotlin. Its Simple and easy to add in our project.
The Developer create some option for animation, we can use animation from left to right, or Right to Left.
If you're looking for progress layout in Android, you can use it.

Thank you for the Developer.

FillProgressLayout

A simple and flexible Fill Progress Layout written in Kotlin


GitHub license


Installation

  1. Add it in your root build.gradle at the end of repositories:
	allprojects {
 		repositories {
 			... 			maven {
 url  https://jitpack.io  
}
 		
}
 	
}
  1. Add the dependency in app gradle
	dependencies {
 	

  implementation  com.github.JDevZone:FillProgressLayout:{
latest_version
}
  	
}

Basic usage

As FillProgressLayout is direct child of LinearLayout you can replace LinearLayout with it as follows

<com.devzone.fillprogresslayout.FillProgressLayout

 android:id="@+id/fillL"

 android:layout_margin="30dp"

 app:fpl_backgroundColor="@color/colorRedTrans"

 app:fpl_progressColor="@color/colorGreenTrans"

 app:fpl_isRounded="false"

 app:fpl_progress="0"

 app:fpl_progressDuration="3000"

 app:fpl_progressDirection="left_to_right"

 app:fpl_shouldRestart="false"

 android:layout_width="match_parent"

 android:layout_height="wrap_content">

<--childviews-->
  </com.devzone.fillprogresslayout.FillProgressLayout>

Alternatively

You can use FillProgressLayout as background for other layouts.

<RelativeLayout

 android:layout_width="match_parent"

 android:layout_height="wrap_content">

<--as background for AppCompatTextView-->

<com.devzone.fillprogresslayout.FillProgressLayout

  android:layout_alignBottom="@+id/tv"

  android:layout_alignParentTop="true"

  android:layout_width="match_parent"

  android:layout_height="wrap_content"/>

 <androidx.appcompat.widget.AppCompatTextView

  android:id="@+id/tv"

  android:text="@string/app_name"

  android:gravity="center"

  android:layout_width="match_parent"

  android:layout_height="wrap_content"/>
  </RelativeLayout>

Samples

Fill Direction Demo

Left To Right

Right To Left

Top To Bottom

Bottom To Top

Additional Rounded Corners sample

Customisation

Here are the attributes you can specify through XML or related setters programatically:

  • fpl_backgroundColor - Set background color.
  • fpl_progressColor - Set progress color.
  • fpl_isRounded - Set true if you need rounded corners.
  • fpl_roundedCornerRadius - Set radius for round corners.
  • fpl_progress - Set current progress.
  • fpl_progressDuration - Set fill duration.
  • fpl_shouldRestart - Set if progress filling should restart from 0.
  • fpl_progressDirection - Set fill direction. i.e. left_to_right,right_to_left,top_to_bottom or bottom_to_top

License

Checkable TextView is released under the MIT license. See LICENSE for details.

Resources

Web and mobile payments, built for developers.

A set of unified APIs and tools that instantly enables businesses to accept and manage online payments.

Render emoji in your Android application with just 1 line of code.

Gradle plugin for versioning your library/application on every git commit.

Material intro screen is inspired by Material Intro and developed with love from scratch.

Demo that shows how to use RxJava with Android Data Binding ObservableFields.

A place autocomplete search dialog which uses Google's places API for finding results.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes