且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何将支持库的快餐栏文本颜色设置为android:textColor以外的其他颜色?

更新时间:2023-01-27 20:35:48

我知道已经回答了这个问题,但是我发现最简单的方法是直接使用Html.fromHtml方法和font标记

I know this has been answered already but the easiest way I found was directly in the make using the Html.fromHtml method and a font tag

Snackbar.make(view, 
       Html.fromHtml("<font color=\"#ffffff\">Tap to open</font>").show()