-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support RecyclerView of which height is wrap_content #349
Comments
I thought it's supported. Could you share your XML configuration for the RecyclerView and the settings for the FleboxLayoutManager? |
@thagikura My layout(for a
And item's layout:
And settings for
|
@thagikura Actually the bug is: some last line won't be shown under some circumstances(I'm still working on finding what these conditions are), not "only shows first line". |
Thanks for the info. I guess the height may be constrained by another component. |
@thagikura I think I find the reason causes the bug: if the item of |
Thanks for creating the test project. In the initial call of the onLayoutChidlren, the width of the TextViews haivng a compound drawable seems to be calculated as if they don't have the compound drawable. As a result, the number of flex lines is shorter than expected. Let me mark this as a bug. |
@thagikura Thanks. I will wait for the fix but currently the |
Looks like I have the same behavior when TextView in ListItem has custom background (like this in my case:)
|
if we have three items at one line with linear layout manager then change for flex layout manager, only two items will be shown on and third one will be on next line |
Also happens when using android.support.design.chip.Chip. |
I am seeing the same bug with items that have a constraintlayout parent, with textview and imagebutton as children. |
If the
RecyclerView
's height is wrap_content, only one line of items will be shown and we should scroll theRecyclerView
to see the second line(FlexDirection
isROW
). It was said that ifFlexWrap
is set toWRAP
, multiple lines will be shown but the fact is not like that. Please support this, thanks.The text was updated successfully, but these errors were encountered: