Thursday, January 29, 2015

Make TextView scrollable without using ScrollView

2 steps, firstly, set scroll bar rotation in AndroidManifest.xml:
         android:scrollbars="vertical"

Then, set the scrolling method for the TextView, mostly in onCreate() function:
        ((TextView)findViewById(R.id.textview)).setMovementMethod(ScrollingMovementMethod.getInstance());

No comments:

Post a Comment

Enable HP Zbook Thunderbolt 3 Dock on Ubuntu

As mention in previously post, I installed Ubuntu on my HP ZBook. After two days used all things work just fine, but the Thunderbolt 3 Dock ...