niah
niah

Reputation: 93

How can I get a pagination feature in horizontal scroll view without ViewPager

I'm trying to implement a UI feature which is already in Field Trip or Paper.

And I thought that expandable pager that can select whether pagination feature is enabled or not will be required to implement this.

1) ViewPager reinforces pagination effects

2) ScrollView does not provide paginations

How can I implement this ?? I want to know how to implement or if it is implemented already and published as a library.

Upvotes: 4

Views: 4243

Answers (1)

Anish Kumar
Anish Kumar

Reputation: 1485

So it turns out, its not plain easy to implement Scrolling with Pagination without ViewPager on Android as it is in iOS. However the best way it can be achieved is by creating a custom class of HorizontalScrollView and then have it replicate the functionality. Here are few examples:

http://androidprogrammingmadeeasy.blogspot.com/2011/08/creating-custom-horizontal-scroll-view.html

http://www.androidhub4you.com/2014/03/android-pagination-example-dynamic.html

http://image.incorrectcode.news/question/103680/android-horizontal-scrollview-act-enjoy-iphone-paging/

I'm trying to find a third party framework that can do this for me. I shall update you when found.

Best.

Upvotes: 5

Related Questions