Hi i am developing an app where i have a custom curve shape which i'm using in an imageview now this shpae is in white color and i have created another similar custom shape in black color so now what i'm trying to do is make the black shape as shadow of white shape as a thin black line acting as a outline to white shape. Now my problem is when i run the app the black shape is getting completely overlapped by white shape. So please f anyone can help me out here My xml code
<android.support.v4.widget.NestedScrollView android:layout_height="match_parent"
android:layout_width="match_parent"
android:fillViewport="true"
android:fitsSystemWindows="true"
android:id="@+id/profile_scroll"
xmlns:android="http://schemas.android.com/apk/res/android" >
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/background_image"
android:layout_width="match_parent"
android:layout_height="200dp"
android:background="@drawable/curved_toolbar"
>
<ImageView
android:layout_width="match_parent"
android:layout_height="250dp"
android:src="@drawable/curved_toolbar"
android:visibility="gone" />
<ImageView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:layout_marginBottom="20dp"
android:src="@drawable/profile_black_shadow"/>
<ImageView
android:id="@+id/second_image"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:layout_marginBottom="20dp"
android:src="@drawable/profile_second_image" />
<ImageView
android:id="@+id/pencil_image"
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_alignParentRight="true"
android:layout_marginRight="30dp"
android:scaleType="centerCrop"
android:adjustViewBounds="true"
android:layout_marginTop="25dp"
android:src="@drawable/pencil" />
</RelativeLayout>
<LinearLayout
android:id="@+id/linear"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
</LinearLayout>
<de.hdodenhof.circleimageview.CircleImageView
android:id="@+id/circle_image"
android:layout_width="116dp"
android:layout_height="120dp"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
android:layout_marginEnd="125dp"
android:layout_marginRight="125dp"
android:layout_marginTop="113dp"
android:src="@drawable/heath_ledger"
/>
<LinearLayout
android:id="@+id/person_name_layout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginTop="10dp"
android:layout_below="@+id/circle_image"
android:layout_centerInParent="true"
>
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="Jhon Doe"
android:id="@+id/person_name_text"
android:textColor="@color/White"
android:textSize="16sp"/>
</LinearLayout>
<LinearLayout
android:id="@+id/points_layout"
android:layout_marginBottom="8dp"
android:layout_below="@+id/person_name_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="6dp">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginLeft="20dp">
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/first_follow_count"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="200"
android:textColor="@color/White"
android:layout_marginLeft="13dp"
android:textSize="15sp"/>
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/first_follow_text"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textSize="13sp"
android:text="Followers"
android:textColor="@color/White"
android:layout_marginTop="5dp"/>
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginLeft="51dp">
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/second_follow_count"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="200"
android:layout_marginLeft="40dp"
android:textColor="@color/White"
android:textSize="15sp"/>
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/second_follow_text"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textSize="13sp"
android:text="Following"
android:textColor="@color/White"
android:layout_marginLeft="25dp"
android:layout_marginTop="5dp"/>
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginLeft="100dp">
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/third_follow_count"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="1.5K"
android:textColor="@color/White"
android:textSize="15sp"/>
<com.ct.listrtrial.Custom.CustomTextViewMedium
android:id="@+id/third_follow_text"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textSize="13sp"
android:text="Points"
android:textColor="@color/White"
android:layout_marginTop="5dp"/>
</LinearLayout>
</LinearLayout>
<View
android:id="@+id/divider_view"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/black"
android:layout_above="@+id/leaderboard_recycler"/>
<android.support.v7.widget.RecyclerView
android:id="@+id/leaderboard_recycler"
android:layout_below="@+id/points_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
>
</android.support.v7.widget.RecyclerView>
<View
android:id="@+id/divider_view1"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/black"
android:layout_below="@+id/leaderboard_recycler"
/>
</RelativeLayout>
</android.support.v4.widget.NestedScrollView>
and my custom white shape
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="#FFFFFF"/>
<size
android:width="30dp"
android:height="15dp"/>
<corners
android:bottomLeftRadius="20dp"
android:bottomRightRadius="20dp"/>
</shape>
and my black shape
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="#000000"/>
<size
android:width="18dp"
android:height="9.1dp"/>
<corners
android:bottomLeftRadius="55dp"
android:bottomRightRadius="55dp"
/>
</shape>