开发者

How to show long text only show 1 lines and append with

开发者 https://www.devze.com 2023-03-14 18:22 出处:网络
How to show long text only show 1 lines and append with .... I try <TextView android:id=\"@+id/txtTitle\"

How to show long text only show 1 lines and append with ....

I try

<TextView 
        android:id="@+id/txtTitle" 
        android:text="testqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq"
        android:textStyle="bold"
        android:gravity="center"
        android:maxLines="1" 
        android:lines="1" 
        android:ellipsize="end"
        android:layout_height="wrap_content" 
        android:layout_width="wrap_content"
        android:textSize="20dp"
        android:textColor="#545454"/>

but it sh开发者_C百科ow some text and doesn't append with ...

please help


Check this out ... Add the scrollHorizontally element also.

0

精彩评论

暂无评论...
验证码 换一张
取 消