posts - 296,comments - 1,views - 2995

一.所花时间

0.5h

二.代码量

30行

三.博客量

1篇

四.了解到的知识点

圆角矩形输入框

<?xml version="1.0" encoding="utf-8"?>
 <shape xmlns:android="http://schemas.android.com/apk/res/android" >
 <!-- 指定了形状内部的填充颜色 -->
 <solid android:color="#ffffff" />
 <!-- 指定了形状轮廓的粗细与颜色 -->
 <stroke
 android:width="1dp"
 android:color="#aaaaaa" />
 <!-- 指定了形状四个圆角的半径 -->
 <corners android:radius="5dp" />
 <!-- 指定了形状四个方向的间距 -->
 <padding
 android:bottom="2dp"
 android:left="2dp"
 android:right="2dp"
 android:top="2dp" />
 </shape>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:padding="5dp"
    android:orientation="vertical" >
    <EditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:inputType="text"
        android:hint="这是默认边框"
        android:textColor="@color/black"
        android:textSize="17sp" />
    
    <EditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="5dp"
        android:inputType="text"
        android:hint="我的边框不见了"
        android:background="@null"
        android:textColor="@color/black"
        android:textSize="17sp" />
    
    <EditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="5dp"
        android:inputType="text"
        android:hint="我的边框是圆角"
        android:background="@drawable/editext_selector"
        android:textColor="@color/black"
        android:textSize="17sp" />
    
</LinearLayout>

 

posted on   leapss  阅读(5)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 25岁的心里话
· 闲置电脑爆改个人服务器(超详细) #公网映射 #Vmware虚拟网络编辑器
· 零经验选手,Compose 一天开发一款小游戏!
· 因为Apifox不支持离线,我果断选择了Apipost!
· 通过 API 将Deepseek响应流式内容输出到前端
历史上的今天:
2023-05-13 每日打卡-22.2
2023-05-13 每日打卡-22.1
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

点击右上角即可分享
微信分享提示