How to display border to image inside an image view,I wish to accomplish something like a line with arrow head on the side and bottom of the image to display the length and breadth in text above the line . I have referred to Is there an easy way to add a border to the top and bottom of an Android View? and Border for an Image view in Android? but both of these create a border for the image view as a whole while I need a border for the image itself .
Asked
Active
Viewed 72 times
1
-
can you share a image ?it will b easy to understand – Sunisha Guptan Jul 17 '17 at 11:18
-
Post what is reqiured – Lakhwinder Singh Jul 17 '17 at 11:32
-
https://www.google.co.in/url?sa=i&rct=j&q=&esrc=s&source=images&cd=&cad=rja&uact=8&ved=0ahUKEwjH7NrTm5DVAhVLe7wKHVFYBrwQjRwIBw&url=http%3A%2F%2Fwww.blinn.edu%2Fbrazos%2Fmatheng%2Fjcoffelt%2Fgraphics%2Ffiles%2Fege%2Fdim%2Fdim_page3.htm&psig=AFQjCNHu07IkrQFoS25ywKhzL7ZvbNOn5w&ust=1500377435037009 – Vishal Bisht Jul 17 '17 at 11:32
-
i want something like that line inside my image view – Vishal Bisht Jul 17 '17 at 11:33
1 Answers
0
if you want border around imageview you can try this
You can use CirlcleImageView
library for rounded ImageView
:
compile this libray
compile 'de.hdodenhof:circleimageview:2.1.0'
use like below in your layout
<de.hdodenhof.circleimageview.CircleImageView
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/profile_image"
android:layout_width="96dp"
android:layout_height="96dp"
android:src="@drawable/profile"
app:civ_border_width="2dp"
app:civ_border_color="#FF000000"/>
for more information follow this link

AskNilesh
- 67,701
- 16
- 123
- 163