ConstraintLayout views in top left corner

前端 未结 5 1745
无人共我
无人共我 2020-11-22 04:21

Every time I create views like Button and TextView in ConstraintLayout, they all get stuck at the top corner instead of where I placed

5条回答
  •  轮回少年
    2020-11-22 05:08

    Basically this type of problem happens when you use ConstraintLayout .

    • So Go to Preview From Android Studio.

    • Select That button you want to set at the specific position

    • At last just click the infer constrains button as i mention in the picture below on a red circle.

    Thats All run the project and see magic

    Thank you

提交回复
热议问题