查看分页器转换像卡片一样带到顶部 [英] View Pager Transformation bring to top like cards
本文介绍了查看分页器转换像卡片一样带到顶部的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想实现以下目标
我能够使用以下库 https://github.com/Hongchae/CoverFlowPager
在进行一些自定义之后,我就能拥有它
and after some customization i was able to have this
现在我想调整页面以使其看起来像第一张图片
Now i want to adjust the pages to appear like the first image
感谢您的帮助,谢谢
推荐答案
要显示左右片段的预览,必须设置以下值:
For showing the preview of left and right fragments you have to set the following values:
//这是为了避免截断效果
// This for avoiding the truncate effect
viewpager.setClipToPadding(false);
//用于设置填充以查看其他片段
// This for setting the padding for seeing the other fragments
viewpager.setPadding(left,0,right,0);
要修改viewpager中片段之间的空间,请使用
To modify the space between the fragments in the viewpager use
viewpager.setPageMargin(int);
此帖子可能会帮助您> ViewPager在下一个和之前显示屏幕上的项目预览
这篇关于查看分页器转换像卡片一样带到顶部的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文