gpt4 book ai didi

android - 如何设置 TextAppearanceSpan 的 TextColor?

转载 作者:塔克拉玛干 更新时间:2023-11-03 00:43:14 26 4
gpt4 key购买 nike

我目前可以创建一个中等大小的 TextAppearanceSpan,但是如何将文本颜色设置为指定的 RBG 颜色(例如 #c71585)?

new TextAppearanceSpan(context, android.R.style.TextAppearance_Medium);

我看到有一个构造函数

public TextAppearanceSpan(Context context, int appearance,
int colorList) {

但是 colorList 的 int 是什么?有这方面的例子吗?

谢谢。

最佳答案

为什么不将没有colorListTextAppearanceSpanForegroundColorSpan 结合使用? ?

关于android - 如何设置 TextAppearanceSpan 的 TextColor?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2473751/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com