Android Horizontal Scrolling that Snaps to List Items



I'd like to implement a UI experience in Android where a user can view a single item (for example, an item in my case is a collection of texts), and swipe left or right on the item to go to the previous or next item.


From my research, ListView does not implement horizontal scrolling. Potential candidates seem to be HorizontalScrollView and GridView, but I haven't seen any examples that can do this simply - only seemingly complicated libraries that need to be included.


My question is, is there a way to use ListView, HorizontalScrollView, GridView, or a combination of them to implement a horizontal scroll that shows one item at a time and snaps to the item being displayed?


The highlighted area in the picture below shows where I'm trying to implement this logic.


horizontal scroll


No comments:

Post a Comment