AIDE Tutorial - 6.2 Round Corner Button
Watch the video belowMain xml
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center" >
<Button
android:background="@drawable/round_corner_button"
android:text="Round Corner Button"
android:layout_width="wrap_content"
android:background="@drawable/round_corner_button"
android:text="Round Corner Button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="15dp"/>
android:padding="15dp"/>
</LinearLayout>
round_corner_button xml
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="rectangle">
<solid android:color="#EFE1E0"/>
<stroke android:color="#2CE20E"
android:width="3dp"/>
<corners android:radius="20dp"/>
</shape> </item></selector>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="rectangle">
<solid android:color="#EFE1E0"/>
<stroke android:color="#2CE20E"
android:width="3dp"/>
<corners android:radius="20dp"/>
</shape> </item></selector>
0 comments:
Post a Comment