kotlin round border in xml
snippet in kotlin

kotlin round border in xml

user8028

<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" >
 
  <!-- we define background color -->
  <solid android:color="#c0c0c0" />
 
  <!-- we define border color and thick -->
  <stroke
    android:width="3dp"
    android:color="#5b8bc7" />
 
  <!-- add some padding for text inside -->
  <padding
    android:bottom="15dp"
    android:left="15dp"
    android:right="15dp"
    android:top="15dp" />
 
  <!-- we define corner radius, note that radius can be different for each corner -->
  <corners android:radius="10dp" />
 
</shape>