Skip to content
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

margin child doesn' t take effect #18

Open
augustopicciani opened this issue Jul 8, 2015 · 1 comment
Open

margin child doesn' t take effect #18

augustopicciani opened this issue Jul 8, 2015 · 1 comment
Assignees
Milestone

Comments

@augustopicciani
Copy link

If I have structure like this:

FlowLayout [ LinearLayout->TextView + ImageView]

What I have to do to set margin to a LinearLayout?
I tried something like sample in your project:
FlowLayout.LayoutParams params = new FlowLayout.LayoutParams(FlowLayout.LayoutParams.wrap_content,FlowLayout.LAyoutParams.wrap_Content);
params.rightMargin = 10;
LinearLayout.setLayoutParams(params)

but nothing happened. If I use LinearLayout.LayoutParams it return a cast exception.

Can u please give me an help?
Thanks.

@blazsolar blazsolar added the bug label Sep 8, 2015
@blazsolar blazsolar added this to the 1.0 milestone Sep 8, 2015
@blazsolar blazsolar self-assigned this Sep 8, 2015
@haraldk
Copy link

haraldk commented Dec 18, 2015

Hi,

Had a similar issue. Solved it by wrapping the LinearLayout in a FrameLayout (keeping the margins on the LinearLayout.

Harald K

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants