Android ViewPager - Show preview of page on left and right
android, android-viewpager
Solution
To show preview of left and right pages set the following two values
- `viewpager.setClipToPadding(false);`
- `viewpager.setPadding(left,0,right,0);`
If you need space between two pages in the viewpager then add
viewpager.setPageMargin(int);
Problem
I'm using Android's `ViewPager`. What I want to do is to show a preview of the page on both the left and the right. I've seen where I can use a negative `pageMargin` to show a preview of the right side. ``` setPageMargin(-100); ``` Is there anyway that I can show a preview of the left side aswell? Its basically something similar to the gallery widget that I am looking for.