Reputation: 6792
I'm programming on ADK and I got one screen with a text at a huge font so the whole text can't appear on the screen. I want to know to do slide the finger up and see the text below, sliding it as we do with normal texts on Android.
Upvotes: 0
Views: 196
Reputation: 23638
Put your TextView inside ScrollView in XML like:
<ScrollView
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<TextView
android:id="@+id/txt2"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:text="txt2"/>
</ScrollView>
OR If You don't need to use a ScrollView
actually.
Just set the
android:maxLines = "AN_INTEGER"
android:scrollbars = "vertical"
properties of your TextView
in your layout's xml file.
Then use:
yourTextView.setMovementMethod(new ScrollingMovementMethod())
in your code.
It scrolls automatically without any issues.
Upvotes: 1
Reputation: 70
Create a custom listview! Like so : http://www.vogella.com/articles/AndroidListView/article.html#androidlists_overview
Upvotes: 0