FrameLayout margin not working

后端 未结 7 1872
野的像风
野的像风 2020-12-04 09:46

My layout structure is like this

LinearLayout
    FrameLayout
       ImageView
       ImageView
    FrameLayout
    TextView
LinearLayout

I

7条回答
  •  离开以前
    2020-12-04 09:58

    you have to set your ImageView's layout gravity top i.e. android:layout_gravity="top" in the XML resource file, or from code: FrameLayout.LayoutParams.gravity = Gravity.TOP

提交回复
热议问题