RippleDrawable alternatives and similar packages
Based on the "Material Widget" category.
Alternatively, view RippleDrawable alternatives based on common mentions on social networks and blogs.
-
material-design-icons
Material Design icons by Google -
material-dialogs
😍 A beautiful, fluid, and extensible dialogs API for Kotlin & Android. -
MaterialDrawer
The flexible, easy to use, all in one drawer library for your Android project. Now brand new with material 2 design. -
MaterialDesignLibrary
This is a library with components of Android L to you use in android 2.2 -
MaterialViewPager
A Material Design ViewPager easy to use library -
android-floating-action-button
Floating Action Button for Android based on Material Design specification -
RippleEffect
Implementation of Ripple effect from Material Design for Android API 9+ -
Carbon
Material Design implementation for Android 4.0+. Shadows, ripples, vectors, fonts, animations, widgets, rounded corners and more. -
material-menu
Animations for Android L drawer, back, dismiss and check icons -
materialish-progress
A material style progress wheel compatible with 2.3 -
material-ripple
Android L Ripple effect wrapper for Views -
MaterialDialog
An Android library for conveniently building Material Design Dialog in Android version 2.2 ~ L. -
MaterialProgressBar
Material Design ProgressBar with consistent appearance -
MaterialNavigationDrawer
Navigation Drawer Activity with material design style and simplified methods -
MaterialList
An Android library aimed to get the beautiful CardViews that Google shows at its official design specifications -
material-range-bar
Android widget for selecting a range of values. -
MaterialTabs
Custom Tabs with Material Design effects. It requires 14+ API and android support v7 (Toolbar) -
MaterialEverywhere
Showcase of the new AppCompat 21, which includes new Material Theme, working in pre-21 devices. -
snackbar
[DEPRECATED] Android Library that implements Snackbars from Google's Material Design documentation. -
Horizontal Calendar
A material horizontal calendar view for Android based on RecyclerView -
AndroidMaterialDesignToolbar
Android Sample Project with Material Design and Toolbar. -
MaterialPowerMenu
A demo of the power menu with Reveal and other animations -
CircularProgressView
A Material style circular progress bar for Android -
Material Dialogs for Android 📱
📱Android Library to implement animated, 😍beautiful, 🎨stylish Material Dialog in android apps easily. -
material-drawer
Custom drawer implementation for Material design apps. -
ZDepthShadowLayout
Android - draw z-depth shadow of MaterialDesign -
android-materialshadowninepatch
Provides 9-patch based drop shadow for view elements. Works on API level 9 or later. -
uberprogressview
:hourglass_flowing_sand: An android progress view developed after taking inspiration from Uber app. -
Android-Material-circular-button
Animated Material circular button -
AdvancedMaterialDrawer
A Gmail-like Material Drawer implementation -
Android-DialogFragments
Various DialogFragments for Android.
Appwrite - The open-source backend cloud platform
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of RippleDrawable or a related project?
README
RippleDrawable
Port of Android <ripple>
effect for pre lollipop devices with android 14 + (ICS+)
(well, since NineOldAndroids is deprecated, this library become 14 + only)
Features
- XML inflating
- Ripple supports different shapes
- Custom drawable loader
- Define your custom drawable tags
Implementation
Create your desirable ripple.xml in drawable/
folder
<?xml version="1.0" encoding="utf-8"?>
<ripple
xmlns:android="http://schemas.android.com/apk/res/android"
android:color="@color/ripple_material_light"> <!-- ripple color -->
<!-- for Floating Action Button -->
<item>
<shape android:shape="oval">
<solid android:color="@color/accent_material_dark"/>
</shape>
</item>
</ripple>
Secondly we need to inflate RippleDrawable
and intercept View
touches
see LollipopDrawablesCompat
and DrawableHotspotTouch
for inflating and interception sequently. Here is sample:
public class SampleActivity extends AppCompatActivity {
private FloatingActionButton mActionButton;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_sample);
mActionButton = (FloatingActionButton) findViewById(R.id.fab);
mActionButton.setBackgroundDrawable(getDrawable2(R.drawable.fab_background));
mActionButton.setClickable(true);// if we don't set it true, ripple will not be played
mActionButton.setOnTouchListener(
new DrawableHotspotTouch((LollipopDrawable) mActionButton.getBackground()));
}
/**
* {@link #getDrawable(int)} is already taken by Android API
* and method is final, so we need to give another name :(
*/
public Drawable getDrawable2(int id){
return LollipopDrawablesCompat.getDrawable(getResources(), id, getTheme());
}
}
Thats it!
Dependency
root build.gradle add a repository
repositories {
maven {
url "https://jitpack.io"
}
}
and in application module just add
dependencies {
compile 'com.github.ozodrukh:RippleDrawable:2.0.0'
}
a little bit more
you can inflate and create your own Drawable
classes, here is tips & tricks
1 extend your Drawable from LollipopDrawable
public class LayerDrawable extends LollipopDrawable {
2 implement your own inflation
public void inflate(Resources r, XmlPullParser parser, AttributeSet attrs, Resources.Theme theme);
3 Register your LollipopDrawable
static {
LollipopDrawablesCompat.registerDrawable(RippleDrawable.class, "ripple");
}
4 inflate it!
LollipopDrawablesCompat.getDrawable(getResources(), R.drawable.custom_drawable, getTheme());
License
The MIT License (MIT)
Copyright (c) 2015 Abdullaev Ozodrukh
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*Note that all licence references and agreements mentioned in the RippleDrawable README section above
are relevant to that project's source code only.