Top Android Button Libraries
Top Android Button Libraries.
Buttons are an essential component of any Android application's user interface. They allow users to interact with the app by triggering specific actions or events. While Android provides its own set of default buttons, there are also several third-party libraries available that offer additional features, customization options, and improved user experience.
In this tutorial, we will explore the features and installation process for the following Android button libraries:
- MaterialButton by Google
- FloatingActionButton by Google
- FancyButton by @medyo
- Android Button Library by @dmytrodanylyk
Let's dive into each library one by one!
MaterialButton by Google
The MaterialButton library is part of the official Material Components for Android. It provides a set of buttons that follow the Material Design guidelines, offering a consistent and visually appealing look.
Installation
Add the following dependency to your app's build.gradle file:
implementation 'com.google.android.material:material:1.4.0'
Code Usage Example
To use the MaterialButton in your layout XML file, add the following code:
<com.google.android.material.button.MaterialButton
android:id="@+id/materialButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Material Button" />
To handle button click events in your activity or fragment, use the following code:
val materialButton = findViewById<MaterialButton>(R.id.materialButton)
materialButton.setOnClickListener {
// Handle button click here
}
FloatingActionButton by Google
The FloatingActionButton library also comes from the official Material Components for Android. It provides a floating action button that is commonly used for promoting the primary action within an app.
Installation
Add the following dependency to your app's build.gradle file:
implementation 'com.google.android.material:material:1.4.0'
Code Usage Example
To use the FloatingActionButton in your layout XML file, add the following code:
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/floatingActionButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_add"
app:backgroundTint="@color/colorAccent" />
To handle button click events in your activity or fragment, use the following code:
val floatingActionButton = findViewById<FloatingActionButton>(R.id.floatingActionButton)
floatingActionButton.setOnClickListener {
// Handle button click here
}
FancyButton by @medyo
FancyButton is a popular library created by @medyo. It provides a set of customizable buttons with various styles and effects.
Installation
Add the following dependency to your app's build.gradle file:
implementation 'com.github.medyo:fancybuttons:1.9.0'
Code Usage Example
To use the FancyButton in your layout XML file, add the following code:
<com.medyo.fancybuttons.FancyButton
android:id="@+id/fancyButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Fancy Button"
app:fb_borderColor="#000000"
app:fb_borderWidth="2dp"
app:fb_radius="10dp" />
To handle button click events in your activity or fragment, use the following code:
val fancyButton = findViewById<FancyButton>(R.id.fancyButton)
fancyButton.setOnClickListener {
// Handle button click here
}
Android Button Library by @dmytrodanylyk
The Android Button Library by @dmytrodanylyk provides an extensive collection of customizable buttons with different shapes, animations, and effects.
Installation
Add the following dependency to your app's build.gradle file:
implementation 'com.github.dmytrodanylyk.circular-progress-button:library:1.1.3'
Code Usage Example
To use a Circular Progress Button from the library in your layout XML file, add the following code:
<com.dd.CircularProgressButton
android:id="@+id/circularProgressButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Circular Button"
app:spinning_bar_color="#FFFFFF" />
To handle button click events in your activity or fragment, use the following code:
val circularProgressButton = findViewById<CircularProgressButton>(R.id.circularProgressButton)
circularProgressButton.setOnClickListener {
// Handle button click here
}
Additional Button Libraries
If you are looking for more button libraries, here are a few additional options you can explore:
ButtonProgressBar by @jrvansuita
StatefulButton by @amulyakhare
FlashButton by @mikolajadamski
android-flat-button - FButton - a flat button library for Android.
fab - Floating Action Button Library for Android.
slideview - An awesome sliding button library for Android..
SparkButton - Android library to create buttons with Twitter's heart like animation..
ExpandableButtonMenu - [DEPRECATED] An Android library for an expandable button menu.
ButtonMenu - ButtonMenu is an Android library created to build user interfaces based on buttons. This library has been implemented using Model View ViewModel pattern combined with an Android custom view that extends LinearLayout..
sign-in-with-apple-button-android - An Android library for Sign In with Apple.
Android-SocialButtons - A library for easily implementing social login/share buttons.
FabulousFilter - Android library to animate Floating Action Button to Bottom Sheet Dialog and vice-versa.
toolbar-button - FAB to Toolbar Button library for Android Material Collapsing Toolbar.
material-sheet-fab - Android library that provides the floating action button to sheet transition from Google's Material Design..
FABtransitions - Android Library to create Floating Action Button Animations..
FloatingActionButtonExpandable - An android library that brings the floating action button expandable.
AndroidLikeButton - This library will help you to create animation like twitter heart and facebook like and smiley animation in simplest way.
qreader - 🔳 [Android Library] Read QR codes using google's mobile vision api, but without the hassle.
custom-floating-action-button - This view is for replacement of standard Floating Action Button from Google Support Library. It is easy to use, customizable and you can also add text to button.
weekdays-buttons-bar - "Weekdays Buttons Bar" is an Android library that makes it easy to integrate weekdays selection in your layout..
NoboButton - Android Button Library; Simple and fast way to create android button with icon, radius, background.
Android-ActionButton - A simple library to create a toast like button in the bottom right corner of your app's activity.
SlidingButton - Slide button library for android.
CompoundButtonGroup - An Android library to easily implement compound buttons.
CircleButtonBar - CircleBottomBar library for Android.
FABRevealMenu-master - A general purpose android UI library to show a user show menu in accordance of Floating action button with material design guidelines..
custom-google-signin-button - A custom SignInButton for Android that supports 'android:text' attribute, currently not supported by Google's original 'SignInButton'. This library also allows to set button theme to dark or light and is based on Google guidelines..
ReactButton - Android Library to make it easy to add ReactButton feature in your app with Multi Reactions like Facebook or Linkedin, you can add many reactions as you want, you can also split them into a number of columns, and also customize the colours and text for each reaction.
Custom-Toggle-Button - An Android Library for outline toggle buttons .
Morphing-Material-Dialogs - Material dialog ❤️ morphing animation. An android kotlin UI library for building beautiful animations for converting a floating action button into a material dialog..
ExpandableSelector - ExpandableSelector is an Android library created to show a list of Button/ImageButton widgets inside a animated container which can be collapsed or expanded..
AndroidUIView - It's a very simple custom views library according UIButton in iOS, all of the views can be automatically set a pressed effect to a button with a simple background image without writing a selector.xml.
Hamburger-Button - A library about Android hamburger button.
AnimatedVectorDrawableCompat-play-to-reset-button - An Android app using the AnimatedVectorDrawable support library.
FloatingActionButton - [Updated Clans FAB library] Android Floating Action Button based on Material Design specification.
StripedProcessButton - Android library. Animated striped button to show loading process..
scrollme-android - An Android library automatically adds scroll up button to RecyclerView .
android-BlankSpace - 🔳 This is an android popup library "BlankSpace"..
state-button-android - The state button is an android ui library based on Material UI. There are 4 states: enabled, disabled, loading, error.
TextViewPlus - an android library for setting custom font in xml layout.
Android-LoadingButton - A tiny library that lets you create a button with a loading state to improve the UX of your app.
CenteredContentButton - Centered Content Button is Android library which contains button-like and toggle button-like components with centered content - icon and/or text..
PulsatingButtonAndroidLibrary - A simple android UI library to show a shrinking and growing button..
GButton - A simple library that can implement custom google sign in button in your android app..
opencv-edge-detector - 🔲 ✨ Awesome real time edge detector build with OpenCV library for android.
Amazing-Buttons - It is an Android library for buttons..
Process-Button-Android - Material Processing Button Library For Android.
ViewOptionAnimation - Android Library View whitch have option button and animation..
EasyFont - Android Library to set font of TextView, Button, EditText, and RadioButton in XML without editing Java code to set Typeface..
pbba-merchant-button-library-android-r4 - pbba merchant button library android R4.
FabProgress - Android Floating Action Button with ProgressRing Library.
android-tandemactivities - MapFragment library for Android (also can help you use any other Activity in tandem with a FragmentActivity). Includes small example app that shows some solutions for back button and fragment backstack issues that stem from MapFragment solution..
edslider - Android library for icon slider (Facebook-like emoji button).
android-auto-fit-button - Android Auto Fit Button library.
IncrementDecrementButton - Zomato/Swiggy like increment decrement button library for android. Available as both composable as well as XML based library! Simple & easy to use. 📱 ⚡.
VerticalIconButton - Android library for custom button.
button-merchant-android - An open source client library for Button merchants..
multi-floating-action-button - Android library providing an implementation of the Material Design Floating Action Button Speed Dial..
CuteButton - A Material Design Custom Button Library for Android.
AndroidSlideButton - Slide Button using slide library 'com.shitij.goyal:slide-button:1.0.0' ..
CustomButtonsAndroid - This is a library containing some custom useful Buttons using The Kotlin language .
TextViewReadMore - Android library for creating expand button on your long textview .
ProgressButton_MotionLayout - Native android solution using MotionLayout. Android custom progress button with anim and transition to another state. No need to connect the third-party library..
CustomButton - Custom Button provides a beautiful and minimalistic button with outline and drawable support. This library is part of the Custom UI collection of beautiful, minimalistic, and customizable Android UI components..
Fabb - Custom floating action button Android library.
MyDynamicRecyclerviewExample - This is an Android Library for developer to use customized recyclerview with many features, like easy use Empty view, Refresh view, Floating Action Button, Load more. So all these features contain in one recyclerview..
compose-pay-button - An Android library that provides a Jetpack Compose wrapper on top of the Google Pay Button API..
CircularRevealButton - This library provides an easy way to use circular reveal animation with Button, e.g.: for closing a progress, and switching screen..
floating-action-button - Bringing futuresimple's floating-action-button library into 2018.
Android-New-Toggle-Button - This library project will provide you with a styleable multi-state toggle button..
MaterialDesignFABtoSheet - This library implements the floating action button to sheet transition as per the Google�s Material Design documentation. It can be used with any Floating Action Button Library from Android API level 14..
CoolView - An Android Library that help you to customize views (Button, EditText, ImageView), by adding border with the size and color that you want, and give it the corner radius that you seems cool, and you can also make an imageview looks like a circle..
FabWithText - Android floating action button with text. (Library).
material-sheet-fab - Android library that provides the floating action button to sheet transition from Google's Material Design..
GradientRoundedShadowedButton - This android library is library for custom button with gradient color, rounded and shadow.
ButtonCheckBox - ButtonCheckBox is tiny Android library to have CheckBox Like Button.
react-native-sparkbutton - A checked/button with Twitter's heart explosion like animation (for Android). Based on the Android library: https://github.com/varunest/SparkButton.
MultiButton - A button library for Android develop in Kotlin. Uses latest AndroidX libraries with custom button components to have a larger control on functionality.
SlashToggleButton - An android library for a toggle button with an animated slash..
branded-buttons-compose - Branded Buttons is a compose library that contains buttons stylized according to the specification of each brand. It allows you to create high quality and accessibility friendly social sign-in, sign-up, and "continue with" buttons. It has support for both material 2 and material 3..
CHBubbleExpandableMenu - An Android library for an expandable button menu.
MluviiAndroidLib - Mluvii Android Library that allows developers to use Mluvii button inside their app.
FabMenu - Floating action button menu library.
Feel free to check out the GitHub repositories of these libraries for more information and usage examples.
That's it! You now have an overview of some of the top Android button libraries, their features, installation process, and code usage examples.