Questions tagged [rippledrawable]

Using RippleDrawable, users will no longer have a button (for example) that simply changes colors when pressed; instead, that button will respond with ripples and waves when users interact with it.

Using RippleDrawable, users will no longer have a button (for example) that simply changes colors when pressed; instead, that button will respond with ripples and waves when users interact with it.

The design principle is shown at https://material.io/design/motion/.

184 questions
23
votes
4 answers

Achieve toolbar menu item click ripple effect

I try to use padding to increase the touch area of a button. I use
20
votes
1 answer

RippleDrawable mask color, what is it for?

In referring to the RippleDrawable for Android L, https://developer.android.com/reference/android/graphics/drawable/RippleDrawable.html, there's a way to mask away to contain the ripple effect within the view. The masking is done as
Elye
  • 53,639
  • 54
  • 212
  • 474
19
votes
6 answers

Material ripple effect hidden by other view in layout

I added a ripple effect on a ImageButton, however it is hidden by an ImageView used as a background for the parent view RelativeLayout. Here's the layout file:
Jukurrpa
  • 4,038
  • 7
  • 43
  • 73
17
votes
5 answers

how to create ripple effect for pre-lollipop

How to apply ripple effect like this i have put the dependencies in app/build.gradle app/build.gradle dependencies { compile 'com.github.traex.rippleeffect:library:1.3' } build.gradle allprojects{ repositories{ jcenter() …
Amrita Stha
  • 2,973
  • 3
  • 25
  • 46
17
votes
2 answers

Ripple effect does not show up sometimes

I defined a ripple drawable and set it as the background for the listview item view's background. It almost works fine but the ripple effect just sometimes does not show up upon press. Here is the ripple drawable code:
Qianqian
  • 2,104
  • 18
  • 28
16
votes
5 answers

Ripple effect over imageview

To describe my problem i created small example. I have linearlayout with imageview and textview. For linearlayout i've set ripple drawable as background. But when i click or long click on linearlayout ripple animation shows under imageview. How show…
Anton111111
  • 656
  • 1
  • 7
  • 23
16
votes
3 answers

Disable Ripple on ListView

In Android 5.0, my ListView produces a ripple effect when clicking a list item. Is there a way to disable this effect? Looking at the docs, I don't see any way (https://developer.android.com/reference/android/widget/ListView.html)
tir38
  • 9,810
  • 10
  • 64
  • 107
14
votes
6 answers

ImageView selectableItemBackgroundBorderless does not render outside of view bounds

I am using selectableItemBackgroundBorderless to add a ripple to an ImageView. My expected behaviour would be to have a circular ripple, extending the views size. Unfortunately the ripple gets cropped by the view bounds. How can this issue be…
stoefln
  • 14,498
  • 18
  • 79
  • 138
14
votes
1 answer

How to add a ripple effect on a layout with rounded corners?

I want to set a ripple effect on layout with rounded corners. How can I do it?
Rabindra Khadka
  • 1,344
  • 1
  • 13
  • 23
14
votes
2 answers

Android: with RippleEffect & StateListAnimator

I have a layout, that includes another layout:
TejjD
  • 2,571
  • 1
  • 17
  • 37
14
votes
5 answers

Ripple effect does not work in RelativeLayout

I'm trying to implement ripple effect in a RelativeLayout on API 22 but it doesn't show up. However the same ripple works in a Button. The code for my ripple drawable is as follows:
Varun Kumar
  • 1,241
  • 1
  • 9
  • 18
14
votes
2 answers

RippleDrawable created programmatically looks different from its xml counterpart

I have been trying to trace this issue for a while now. I think I did find an explanation some time ago. Unfortunately, its lost in code-comments somewhere. I am trying to create a Material Borderless-Button in Java. To start with, here's what the…
Vikram
  • 51,313
  • 11
  • 93
  • 122
14
votes
1 answer
14
votes
2 answers

Create a ripple drawable without transparency

I'm a bit lost about how to properly use Ripple Drawable. Let's say I have this drawable :
Stephane Mathis
  • 6,542
  • 6
  • 43
  • 69
12
votes
1 answer

Keep ripple within stroke

I'm trying to create a ripple background drawable for a Button with a stroke. This is what I have so far:
Robby Smet
  • 4,649
  • 8
  • 61
  • 104
1
2
3
12 13