直接上效果图

              ...    
image.png

问题

上面的代码想在注册布局放在toolbar下面,按照我的正常写法android:layout_width="match_parent"
android:layout_height="match_parent" 然后app:layout_constraintTop_toBottomOf="@+id/toolbar"放到toolbar下面但是注册页面还是覆盖了toolbar

原因

ConstraintLayout 布局不支持match_parent属性

解决方案

把注册布局android:layout_width,android:layout_height设置为0再添加约束,看效果

<?xml version="1.0" encoding="utf-8"?>               ...    
image.png

更多相关文章

  1. android中gridview的居中问题
  2. 安卓实现标题和按钮在一行,按钮靠最右边布局
  3. Android动态布局,并动态为TextView控件设置drawableLeft、drawabl
  4. Android(安卓)XRecyclerView实现多条目加载
  5. Android在layout xml中使用include .
  6. android中沉浸式布局的设置
  7. android 更改spinner默认样式
  8. Android屏蔽HOME键亲测可用
  9. [Android]RelativeLayout中最底的View其layout_marginBottom无效

随机推荐

  1. 传统menu的使用方法总结
  2. Android(安卓)Intent 其中一个分析
  3. Android开源项目xUtils HttpUtils模块分
  4. Android(安卓)基础-Activity的使用(二)
  5. 【Android】监听蓝牙状态变化
  6. android support Percent支持库开发
  7. Android异步下载网络图片(其三)
  8. android:Bitmap和Drawable相互转换方法
  9. 图片加载处理
  10. Java CRC16算法校验