Addy Addy - 2 months ago 19
Android Question

How to make layout with rounded corners..?

Please anyone can help me . How to make layout with

rounded corners
..
i want to apply rounded corners to my
LinearLayout
.

Answer

1: Define layout_bg.xml in drawables:

<?xml version="1.0" encoding="UTF-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
    <solid android:color="#FFFFFF"/>
    <stroke android:width="3dip" android:color="#B1BCBE" />
    <corners android:radius="10dip"/>
    <padding android:left="0dip" android:top="0dip" android:right="0dip" android:bottom="0dip" />
</shape>

2: Add layout_bg.xml as background to your layout

android:background="@drawable/layout_bg"
Comments