
–>>I want like this
这是我的代码:
<TextVIEw androID:text="Best seller:" androID:layout_wIDth="match_parent" androID:layout_height="wrap_content" androID:ID="@+ID/textVIEw4" androID:textcolor="#3f3f3f" androID:textSize="18sp" /> <androID.support.v7.Widget.RecyclerVIEw androID:layout_wIDth="match_parent" androID:scrollbars="horizontal" androID:ID="@+ID/rv_bestSeller" androID:layout_height="200dp" /> <TextVIEw androID:text="New Product" androID:layout_wIDth="match_parent" androID:layout_height="wrap_content" androID:ID="@+ID/textVIEw5" androID:textSize="18sp" androID:textcolor="#3f3f3f" /> <androID.support.v7.Widget.RecyclerVIEw androID:layout_wIDth="match_parent" androID:scrollbars="horizontal" androID:layout_height="200dp" androID:ID="@+ID/rv_newProduct"/> <TextVIEw androID:text="All Product" androID:layout_wIDth="match_parent" androID:layout_height="wrap_content" androID:ID="@+ID/textVIEw6" androID:textSize="18sp" androID:textcolor="#3f3f3f" /> <androID.support.v7.Widget.RecyclerVIEw androID:layout_wIDth="match_parent" androID:layout_height="wrap_content" androID:ID="@+ID/rv_allProduct" /></linearLayout></ScrollVIEw>
–>>But the space is so small
解决方法 这样做是不好的做法,如果你这样做是因为标题使用了这个库https://github.com/emilsjolander/StickyListHeaders
它会给你标题,你不需要里面有列表的滚动视图.
如果你真的想以这种方式继续使用nestedScrollVIEw而不是常规的ScrollvIEw
https://developer.android.com/reference/android/support/v4/widget/NestedScrollView.html
这将允许你像你想要的那样禁用嵌套滚动
总结以上是内存溢出为你收集整理的android – 如何使recyclerview显示所有项目,不能滚动全部内容,希望文章能够帮你解决android – 如何使recyclerview显示所有项目,不能滚动所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)