我有一个文本框,其行为类似于本地链接,点击它从数据库获取图像并显示它。它不会一直ping到服务器。android TextView:单击更改文本颜色
下面是文本视图中的XML代码
<TextView android:layout_marginLeft="2dp" android:linksClickable="true"
android:layout_marginRight="2dp" android:layout_width="wrap_content"
android:text="@string/Beatles" android:clickable="true" android:id="@+id/Beatles"
android:textColor="@color/Black"
android:textSize="12dp" android:layout_height="wrap_content" android:textColorHighlight="@color/yellow" android:textColorLink="@color/yellow" android:autoLink="all"></TextView>
的问题是我希望看到的文本视图的颜色应为黄色改变,而不是相同的黑色,
刚像按钮的行为,但不是改变背景颜色我想改变文字颜色
https://开头计算器.com/questions/5371719/change-clickable-textviews-color-on-focus-and-click – CoolMind 2017-10-09 16:42:59