How to make a page indicator for horizontal recyclerview
You can add an indicator by using RecyclerView.ItemDecoration. Just draw some lines or circles at the bottom and use layoutManager.findFirstVisibleItemPosition() to get the current active item. Since pagers tend to fill the whole width this is an accruate way of getting the displayed item. This also allows us to calculate the scrolling distance by comparing … Read more