相关疑难解决方法(0)

如何在AlertDialog中更改textcolor

AlertDialog

如何更改AlertDialog中的textcolor?

<item name="android:textColor">@color/black_text</item>
Run Code Online (Sandbox Code Playgroud)

这仅更改标题颜色.

ad = new AlertDialog.Builder((new ContextThemeWrapper(context, R.style.DialogTheme)));
            ad.setTitle(R.string.my_activ_remove_title_dialog);

            ad.setPositiveButton(R.string.my_activ_remove_dialog, new DialogInterface.OnClickListener() {
                public void onClick(DialogInterface dialog, int arg1) {
                    content.remove(position);
                    notifyItemRemoved(position);
                    notifyItemRangeChanged(position, content.size());
                }

            });
            ad.setNegativeButton(R.string.my_activ_cancel_remove_dialog, new DialogInterface.OnClickListener() {
                public void onClick(DialogInterface dialog, int arg1) {

                }
            });
Run Code Online (Sandbox Code Playgroud)

Alerd Dialog v2

android

17
推荐指数
3
解决办法
2万
查看次数

标签 统计

android ×1