1、同时设置四个角
a、静态设置
graphic下新建 background_supertext_red.xml
ohos:shape="rectangle">
ohos:color="$color:white"/>
ohos:width="2"
ohos:color="$color:red"/>
ohos:radius="20"/>
layout.xml中引用
ohos:height="50vp"
ohos:width="match_parent"
ohos:background_element="$graphic:background_supertext_red"
ohos:margin="20vp"
ohos:text="按钮"
ohos:text_size="20fp"/>
b、动态设置,不在layout.xml中通过ohos:background_element引用,通过代码动态设置
Button button = (Button) findComponentById(Re