在Android开发中,写完界面发现控件全部堆在左上角
![图片[1]-Android开发中布局全部堆在左上角-吾爱博客](https://img.ayfre.com/2023/01/30/9838ef6970b14315423cc057886831aa.png)
解决方法
使用此方法自定义控件位置,在xml控件位置写入
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintHorizontal_bias="0.526" // 位置
app:layout_constraintVertical_bias="0.619" // 位置
![图片[2]-Android开发中布局全部堆在左上角-吾爱博客](https://img.ayfre.com/2023/01/30/20868fc0f3175cef9ec87e8e66d98757.png)
温馨提示:
本文最后更新于
2023-01-30
,某些文章具有时效性,若有错误或已失效,请在下方
留言。
© 版权声明
吾爱博客|AYFRE.COM 版权所有,转载请标明出处。
THE END
请登录后查看评论内容