如何使用RecyclerView制作多行水平StaggeredGridLayoutManager? [英] How to make a multiline horizontal StaggeredGridLayoutManager with RecyclerView?

查看:46
本文介绍了如何使用RecyclerView制作多行水平StaggeredGridLayoutManager?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些标签,我想以这种方式放置它们,以便用户可以点击它们.(每个砖头都有标签)

I have some tags, and I want to place them this way so that the user can tap on them. (each brick has a tag in it)

问题是可能有很多标签,我无法事先知道需要多少行.我该如何实现?

The problem is that there may be many tags and I can't know beforehand how many lines I need. How do I implement this?

推荐答案

Google的新 FlexboxLayoutManager 是答案.

Google's new FlexboxLayoutManager is the answer.

这篇关于如何使用RecyclerView制作多行水平StaggeredGridLayoutManager?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆