How can I have a marquee using MaxLines instead of SingleLine ?
This is my TextView :
<TextView
android:text="bla bla bla bla bla bla"
android:id="@+id/MarqueeText"
android:layout_width="30dp"
android:layout_height="wrap_content"
android:singleLine="true"
android:ellipsize="marquee"
android:marqueeRepeatLimit="marquee_forever"
android:scrollHorizontally="true"
android:focusable="true"
android:focusableInTouchMode="true"
android:freezesText="true">
After in my code.java I setSelected
my TextView
:
TextView txtView=(TextView) findViewById(R.id.MarqueeText);
txtView.setSelected(true);
The problem is android:singleLine
is deprecated so I have to use android:maxLines
instead but the marquee don't work with it.