I have an ImageView
as shown below:
<ImageView
android:id="@+id/barchart"
android:layout_width="100dp"
android:layout_height="6dp"
android:layout_below="@+id/stats"
android:layout_marginTop="9dp"
android:layout_toRightOf="@+id/model"
android:background="@android:color/white" />
So, this image will be basically represented in the form of an white horizontal strip. Now, I want to color its ImageView
width depending on a dynamic value. If value is 30dp then, 30dp of the image will be in one color and rest 70dp will be in white color.
So, the aim is basically to represent in the form of bar chart.