android shap画圆(空心圆、实心圆)
实心圆:
<?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval" android:useLevel="false"> <solid android:color="@color/colorWhite" /> <stroke android:width="1dp" android:color="@color/colorWhite" /> <size android:width="10dp" android:height="10dp" /> </shape>
空心圆:
<?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval" android:useLevel="false"> <!--<solid android:color="@color/red"/>--> <stroke android:width="1dp" android:color="@color/colorWhite" /> <size android:width="10dp" android:height="10dp" /> </shape>
带白边的红圆
<?xml version="1.0" encoding="utf-8"?> <shape xmlns:android= "http://schemas.android.com/apk/res/android" android:shape= "oval" android:useLevel= "false" > <solid android:color= "@color/red" /> <stroke android:width= "1dp" android:color= "@color/white" /> <size android:width= "20dp" android:height= "20dp" /> </shape>