All Questions
Tagged with material-components android
398 questions
0
votes
0
answers
96
views
When using Material 3's Dynamic Color feature, almost all text in my app becomes too faded
My goal is to make text with Dynamic Color enabled more bright and readable, like how it looks without the Dynamic Color. I know that I can set text color programmatically, but this is an approach, ...
1
vote
0
answers
81
views
Custom Button Background Not Applying in Android Studio (Material Theme Override?)
I'm trying to apply a custom background to a button in my Android app, but no matter what I do, the button still appears pink instead of using my custom drawable.
Here's my button XML:
<Button
...
2
votes
2
answers
191
views
How can I expand a Floating Action Button into an EditText in Android?
I'm trying to create a custom interaction where a Floating Action Button (FAB) expands into an EditText when clicked, and collapses back into the FAB when clicked again. The behavior I'm looking for ...
1
vote
0
answers
188
views
How to change rounding of the Android Material range sliders
I haven't found any information on how to change both the active and inactive tracks corner rounding for Android Material range sliders ; how do I do that or work around it?
I have read:
Android ...
1
vote
1
answer
199
views
ShapeableImageView - Changing height results in cut-off corners when applying new ShapeAppearanceModel
My app needs to support multiple corner radius/aspect ratio combination presets which may be displayed in different orders depending on the user profile being displayed. For example, preset A has ...
5
votes
4
answers
602
views
BottomSheetDialog with EditText (Remove background under keyboard)
I have a BottomSheetDialog that functions as a comment section. At the bottom of it, there is an EditText view that enables users to add a new comment.
The issue arises when the keyboard appears—...
1
vote
3
answers
795
views
How do I use M3 dynamic colors in my app's launcher icon?
I want to use M3 colors like ?attr/colorPrimary in my app's launcher icon. I know this is possible because my phone's Settings app does it. I've looked around quite a bit and couldn't find anything ...
0
votes
1
answer
150
views
why must i delay the badge attach process?
I cannot find a way to attach a badge to new layout objects. with BadgeDrawable.create,
The badges work when the corresponding object is present in the layout xml, but they are not displayed for ...
1
vote
0
answers
215
views
How to set surface+x%primary colors in xml layout
In official Material Design 3 resources do not specify how to use these (surface+x%primary) colors in xml layouts.
I tried using these colors in code:
protected void onCreate(Bundle savedInstanceState)...
3
votes
2
answers
4k
views
Material Design 3 DialogFragment is not styled like Dialogs using MaterialAlertDialogBuilder
I have migrated migrated to Material Design 3 and notice that the DialogFragments are not styled like dialogs created using MaterialAlertDialogBuilder. Do you need to add customized styling to ...
0
votes
1
answer
843
views
How to dynamically create a Material 3 Tonal Button?
I have tried a number of variations of new MaterialButton(context) including new MaterialButton(new ContextThemeWrapper(context, R.style.Widget_Material3_Button_TonalButton)) but it always results in ...
2
votes
0
answers
743
views
Custom Navigation Icon not visible Material Toolbar Android
I am using Material Design Components, each fragment in my app has a seperate Toolbar Fragment Owned Toolbar
I am having issue setting the custom drawable as the navitaion icon using xml attribute.
In ...
0
votes
1
answer
100
views
TextInputLayout InputType.TYPE_TEXT_VARIATION_PASSWORD showing password by default
I created alert dialog with TextInputLayout programmatically in fragment. I need to hide password by default, TextInputLayout has toggle button and it is working as expected hide/show on click. I ...
3
votes
1
answer
3k
views
What is the correct way to use typography in Material Design 3?
In material design 3, there are 15 types of typography tokens:
textAppearanceDisplayLarge (57sp)
textAppearanceDisplayMedium (45sp)
textAppearanceDisplaySmall (36sp)
textAppearanceHeadlineLarge (32sp)...
1
vote
0
answers
135
views
MaterialTimePicker with all-day support - Android Material Components
Does anyone know of a fork of the material-components-android repo (or similar library) that implements an "All day" checkbox, or better yet, an All-day + time range selection feature?
Right ...