android:singleLine="true" android:ellipsize="marquee"
are the only attributes required, and scrolling even works with layout_weight defined with layout_width=0dp
here is a sample code:
<TextView android:id="@+id/scroller" android:singleLine="true" android:ellipsize="marquee" android:textAppearance="?android:attr/textAppearanceLarge" android:textColor="#FFFFFF" android:text="Some veryyyyy long text with all the characters that cannot fit in screen, it so sad :( that I will not scroll" android:layout_marginLeft="4dp" android:layout_weight="3" android:layout_width="0dp" android:layout_height="wrap_content" />
but the most important is the TextView should be selected , which you have already executed in your code.
Hope this helps you.
source share