I have problem to check, if text view been ellipsized. I defined layout for item in recycle view and I have to check, if text was ellipsized and hide button if yes. I found solution, where can I can get layout from text view and check if it was ellipsized, but in bind method in recycle view it always return false. Do you have someone some idea, how I can do it?
Layout l = textview.getLayout();
if (l != null) {
int lines = l.getLineCount();
if (lines > 0)
if (l.getEllipsisCount(lines-1) > 0)
Log.d(TAG, "Text is ellipsized");
}
This code is not working for me.