Questions tagged [materialbutton]
60 questions
1
vote
1 answer
Mat button toggle group component is not working
I am building an application which requires mat button toggle group (material component) and this is the code,

Kugesh Rajasekaran
- 127
- 2
- 9
1
vote
1 answer
Material Button icon is not aligned properly when iconPadding is small
Create a MaterialButton with following attributes:

Amir
- 1,628
- 20
- 28
1
vote
2 answers
MaterialButtonToggleGroup remove default border
I am new to android development and I need some help removing the borders from the MaterialButtonToggleGroup.
Any help is appreciated
Edit

mhassan
- 83
- 5
1
vote
0 answers
android/kotlin : Material Button show a grey box and then the box disappear
short clip of the issue
In the clip above you will be able to see the problem better.
Switching between Fragments user can see on the icon on the material button a grey box shaped element for short time.
I tried using both the emulator and a real…

OFeigenbaum
- 11
- 2
1
vote
1 answer
How do I get the listener from the MaterialButton.addOnCheckedChangeListener { "as a lambda" }
I have some MaterialButtons which changes checked state (in a toggle group scenario).
My plan is to listen to the Checked status through MaterialButtons addOnCheckedChangeListener
but I need to remove the listener when some conditions occure, how do…

Roar Grønmo
- 2,926
- 2
- 24
- 37
1
vote
0 answers
Android custom button with MaterialButton-like semi-transparent ripple
I created custom button based on a MaterialButton that is semi-transparent (primaryColorDisabled) when pressed and disabled. Now, I would like to have its ripple effect to turn the button from its primaryColor to the primaryColorDisabled instead of…

GrzegDev
- 135
- 1
- 10
1
vote
1 answer
Button Doesn't Show Correct Color - Android Studio
In my Android Studio application, I have a button for which I set a drawable as the background. The drawable rounds the corners and changes the color of the button.
However, when I look at the resulting design of the activity, the color I want…

Tanay N
- 17
- 8
1
vote
2 answers
Setting perfectly circular rounded corners on a MaterialButton in XML
So I have been trying to find a way to make a MaterialButton from the Material Components library have perfectly rounded corners. What I mean by this is effectively they have a corner size of 50% the height of the button.
In some of the…

Henry Twist
- 5,666
- 3
- 19
- 44
1
vote
1 answer
Flutter- per my code how to make material button invisible on swiping left and re-appear on swiping right
I am creating an APP which has a lot of emphasis on the image in the background as such, their is text in arabic on that image per line and I want to add "material buttons" on top of this text. I was able to do this ...but then I want the button to…

shahbaz
- 145
- 2
- 16
1
vote
1 answer
How to get background color in MaterialButton in kotlin android
I have a layout:

capo11
- 790
- 3
- 11
- 32
1
vote
1 answer
How to get checked button position in Android MaterialButtonToggleGroup
I have defined an MaterialButtonToggleGroup with 2 MaterialButton in my xml, in this way:
…

capo11
- 790
- 3
- 11
- 32
1
vote
1 answer
android, MaterialButton button color changed after adding style Theme.MaterialComponents.DayNight
having a MaterialButton, with style: