约束布局ConstraintLayout

复制代码
  <Button
        android:id="@+id/button"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintHorizontal_bias="0.5"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        app:layout_constraintVertical_bias="0.5" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="123123123"
        android:textSize="45dp"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintHorizontal_bias="0"
        app:layout_constraintStart_toStartOf="@+id/button"
        app:layout_constraintTop_toBottomOf="@+id/button"
        app:layout_constraintVertical_bias="0" />
相关推荐
传奇开心果编程37 分钟前
【Flutter踩坑排雷】第25课:ScrollController 误用坑|跳转失效、监听泄漏与“控制器未附加”
android·flutter·ios·移动开发·跨平台·dart·声明式ui
慕容雪_4 小时前
Capacitor8-Android打包完整手册
android·打包·capacitor
阿杰m8 小时前
Android源码第十三章:Bluetooth——沿一次发现走到控制器
android
booboosui8 小时前
派活给另一个 AI:前后两次文件夹快照,就是交付清单
android
普通人613 小时前
MySQL_FIND_IN_SET函数详解
android·数据库·mysql
好的佩奇1 天前
Dart 之集合元素
android·flutter·dart
Easyhood1 天前
Android 开发入门实践(十四):Compose 副作用入门与四个常用 API
android·开发语言·kotlin·android jetpack·compose
FlightYe1 天前
音视频修炼之容器与协议(四):RTSP详解
android·linux·ffmpeg·音视频·dash
疯华整猫1 天前
删掉 LeakCanary 那天,我用 Trae 自己撸了一套:最难的不是分析堆,是决定什么时候 dump
android·人工智能·性能优化
mmsx1 天前
耳切法切带洞多边形:论文能跑通,真实数据为什么崩
android·kotlin