title: Adding custom radio buttons in android
body: <h2>I am trying to get radiobutton effect for regular buttons in android</h2>
  
  <p>I have a simple android radio button below </p>
  
  <p><img src="https://i.stack.imgur.com/Ngv2E.png" alt="enter image description here"></p>
  
  <p><strong>Code for this is</strong> ::</p>
  
  <p><strong>activity_main.xml</strong></p>
  
  <pre><code>&lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:paddingBottom="@dimen/activity_vertical_margin"
      android:paddingLeft="@dimen/activity_horizontal_margin"
      android:paddingRight="@dimen/activity_horizontal_margin"
      android:paddingTop="@dimen/activity_vertical_margin"
      tools:context=".MainActivity" &gt;
  
      &lt;RadioGroup
          android:id="@+id/radioGroup1"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_centerHorizontal="true"
          android:layout_centerVertical="true" &gt;
  
          &lt;RadioButton
              android:id="@+id/radio0"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:checked="true"
              android:text="RadioButton1" /&gt;
  
          &lt;RadioButton
              android:id="@+id/radio1"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:text="RadioButton2" /&gt;
  
          &lt;RadioButton
              android:id="@+id/radio2"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:text="RadioButton3" /&gt;
      &lt;/RadioGroup&gt;
  
  
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <hr>
  
  <h2>How to customize it as below::</h2>
  
  <p><img src="https://i.stack.imgur.com/YugYd.png" alt="enter image description here"></p>
  
  <p><strong>Thanks</strong> ! </p>
  
  <h2>[EDIT] using code from one of the answers</h2>
  
  <p><img src="https://i.stack.imgur.com/bou73.png" alt="enter image description here"></p>
  
  <p><strong>But the button name is overshadowed by the select option how to remove it ?</strong></p>
  
  <hr>
  
  <h2>{EDIT} more changes</h2>
  
  <p>Finall changes should atleast i should know which button i have selected out of three radio buttons  .... is it possible to get as below ?</p>
  
  <p><img src="https://i.stack.imgur.com/3yYyg.png" alt="enter image description here"></p>