【Android】联系人列表补充

真布局--叠起来垂直管

效果展示

部分代码(在activity_main)里面

复制代码
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
   android:layout_width="match_parent"
    android:layout_height="match_parent">

  <ImageView
        android:id="@+id/imgAdd"
        android:layout_gravity="bottom|end"
        android:layout_width="60dp"
        android:layout_height="60dp"
        android:layout_marginEnd="28dp"
        android:layout_marginBottom="20dp"
        android:src="@drawable/add"

       />

增加联系人

布局显示

部分代码(add_contact.xml)

复制代码
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="150dp"
    android:layout_height="wrap_content"
    android:padding="20dp"
    android:gravity="center"
    android:orientation="vertical">

    <EditText
        android:id="@+id/dtAddName"
        android:layout_width="match_parent"
        android:layout_height="45dp"
        android:layout_marginTop="10dp"
        android:hint="请输入姓名"/>
    <RadioGroup
        android:id="@+id/rgAddGender"
        android:layout_width="match_parent"
        android:orientation="horizontal"
        android:layout_marginTop="10dp"
        android:layout_height="45dp">
        <RadioButton
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="男"/>
        <RadioButton
            android:layout_marginStart="50dp"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="女"/>
    </RadioGroup>
    <EditText
        android:id="@+id/dtAddTel"
        android:layout_width="match_parent"
        android:layout_height="45dp"
        android:layout_marginTop="10dp"
        android:hint="请输入姓名"/>
    <EditText
        android:id="@+id/dtAddAddress"
        android:layout_width="match_parent"
        android:layout_height="45dp"
        android:layout_marginTop="10dp"
        android:hint="请输入地址"/>
    <EditText
        android:id="@+id/dtAddEmail"
        android:layout_width="match_parent"
        android:layout_height="45dp"
        android:layout_marginTop="10dp"
        android:hint="请输入邮箱"/>

    <Button
        android:id="@+id/btnAdd"
        android:layout_marginTop="20dp"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="确定"/>

</LinearLayout>
  1. sql

页面使用

相关推荐
信创DevOps先锋18 小时前
研发知识系统选型实战:从 Notion 到 Gitee Wiki 的迭代经验
gitee·devops
wzj_what_why_how1 天前
Android设备标识符详解:IMEI、ANDROID_ID与OAID
android·gitee
明月与玄武3 天前
2025最新国产用例管理工具评测:Gitee Test、禅道、蓝凌测试、TestOps 哪家更懂研发协同?
gitee·禅道·国产用例管理工具·testops·蓝凌测试
小川zs3 天前
gitee某个分支合并到gitlab目标分支
gitee·gitlab
云和数据.ChenGuang3 天前
gitlab-ci.yml
面试·职场和发展·gitee·运维面试题·运维技术总结
我是一只代码狗5 天前
idea中使用git
git·gitee·github
素雪风华6 天前
Jenkins+Gitee+Docker容器化部署
java·docker·gitee·jenkins·springboot·持续部署
乌云暮年7 天前
Git简单命令
git·gitee·github·batch命令
Python私教9 天前
如何通过配置gitee实现Claude Code的版本管理
gitee
SkyrimCitadelValinor9 天前
Git【开源分布式版本控制工具】安装-配置-常用指令-Git远程仓库-IDEA使用Git
分布式·git·gitee·开源·项目管理