【发布时间】:2012-11-21 03:08:22
【问题描述】:
假设我有 TextView 并且我想更改其中某些部分的颜色。像这样
而且我必须在文本“使用条款”上设置 OnclickListener,所以除了使用两个 textView 之外,我该怎么做。谢谢
问候
【问题讨论】:
标签: android xml text colors textview
假设我有 TextView 并且我想更改其中某些部分的颜色。像这样
而且我必须在文本“使用条款”上设置 OnclickListener,所以除了使用两个 textView 之外,我该怎么做。谢谢
问候
【问题讨论】:
标签: android xml text colors textview
使用没有文本的简单复选框,并用于文本点击事件 这就是你要找的Spannable
【讨论】:
你可以在 TextView 中使用 HTML:
myTextView.setText(Html.fromHtml("<h2>Test</h2>"));
【讨论】: