dialog xml
<style name="Theme.MyApp.Dialog.Alert" parent="ThemeOverlay.Material3.MaterialAlertDialog">
<item name="android:textColor">@color/md_theme_light_onBackground</item>
<item name="android:background">@color/md_theme_light_background</item>
the missing attribute is the inner items color how to set it
CodePudding user response:
Define dialog in your styles.xml and do whatever modifications required here.
<style name="MyDialog" parent="Theme.Material3.Dark.Dialog.Alert"/>
And then in your code
AlertDialog.Builder(this, R.style.MyDialog)