-
Notifications
You must be signed in to change notification settings - Fork 146
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
Gravity issues #29
Comments
This FlowLayout just supports horizontal flow layout, so it doesn't make sense that the children of a horizontal FlowLayout use |
It does make sense when in the flowlayout there are three items, and the third doesn't fit in the row, but there's still some space left. By supporting gravity, this space wouldn't always be at the end of the second item but maybe in the middle or at the start of the first one. |
oh, I get your point now. It's really userful in some situations. But It's a little complicated to layout all children if the attr layout_gravity = "left/right" is supported in each child of a FlowLayout. Maybe it is more reasonable to support the attr layout_gravity = "left/right" for each row rather than each child? |
The whole point of the FlowLayout is that the rows and in which row the elements are positioned are determined dynamically, so I don't see how it could be useful (or implemented) to have this feature. You don't know/control, how many rows there are, which elements are in which row, etc. You could do something like
but this would be complicated to implement and make it nessecary to modify the FlowLayout in-code to achive the wanted effect. At the moment, you can do anything you want just using XML. |
yeah, I agree with your idea. You can hava a look at the |
The layout_gravity="right" and layout_gravity="left" (or start/end) don't work for children of a FlowLayout.
The text was updated successfully, but these errors were encountered: