Is it possible to have a single line TextView
that cuts off at the nearest pixel and does not add three dots?
2 Answers
<TextView
android:id="@+id/text_ivew"
style="@style/Text.Title"
singleLine="false"
android:ellipsize="end"
android:lines="1"
android:text="text"></TextView>
-
2according to Eclipse's documentation singleLine is "* Deprecated: This attribute is deprecated and is replaced by the textMultiLine flag in the inputType attribute. Use caution when altering existing layouts, as the default value...." i used it without and works fine on android 2.1 :)– max4everMay 31, 2011 at 14:27
-
-
Didn't work with me, text still shows ellipsis (left cell pushes right cell to the right so text in right cell shows ellipses). Apr 27, 2015 at 18:44
-
You should just be able to set the android:ellipsize property to false on your TextView in xml.