FlowLayout
FlowLayout copied to clipboard
margin child doesn' t take effect
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.
Hi,
Had a similar issue. Solved it by wrapping the LinearLayout
in a FrameLayout
(keeping the margins on the LinearLayout
.
Harald K