Border with title in Android?

admin

Administrator
Staff member
We can use
Code:
shape
to create a simple border,for example I saw this code <a href="http://zaman91.wordpress.com/2010/12/30/android-how-to-create-rounded-border-or-background/" rel="nofollow noreferrer">here</a>:

Code:
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;layer-list xmlns:android="http://schemas.android.com/apk/res/android"&gt;
    &lt;item&gt;
        &lt;shape android:shape="rectangle"&gt;
            &lt;corners android:radius="5dip" /&gt;
            &lt;solid android:color="@color/black" /&gt;
            &lt;stroke android:width="2dip" android:color="@color/white" /&gt;
        &lt;/shape&gt;
    &lt;/item&gt;
&lt;/layer-list&gt;

But I need a border with a title like this image:

<img src=" " alt="enter image description here">

How I can do that?