TextView 复制 textIsSelectable不起作用的问题

在这个回答下找到了答案 Android: “TextView does not support text selection. Action mode cancelled”

解决办法是layout_width设置为wrap_content

原因我直接拷贝过来吧
it works because the TextView has to layout again. You can trace the setText method to understand why. But layout a view is expansive. It’s an old bug of Android which google just don’t want to fix it.

你可能感兴趣的:(TextView 复制 textIsSelectable不起作用的问题)