gpt4 book ai didi

android - 如何在android中创建带圆角的编辑文本

转载 作者:太空狗 更新时间:2023-10-29 15:39:44 28 4
gpt4 key购买 nike

谁能告诉我如何在 android 中创建带圆角的可编辑文本框?

我试过这段代码,但它不起作用:

<?xml version="1.0" encoding="utf-8"?> 
<!-- res/drawable/rounded_edittext.xml -->
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle" android:padding="10dp">
<solid android:color="#FFFFFF" />
<corners android:bottomRightRadius="0dp"
android:bottomLeftRadius="0dp" android:topLeftRadius="15dp"
android:topRightRadius="15dp" />
</shape>

谢谢

最佳答案

嘿,看看这个讨论中的问题:How to create EditText with rounded corners? ..我相信它一定会对您有所帮助。

关于android - 如何在android中创建带圆角的编辑文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5538121/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com