Android ImageView with Rounded Corners not working -
this question has answer here:
- how make imageview rounded corners? 35 answers
i have definied file thumb_rounded.xml , placed inside res/drawable folder in android application. file want rounded corners in imageviewthat contains news thumb,
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle" > <corners android:radius="13.0dip" /> </shape>
and setting background of imageview, however, dont rounded corners, image remains rectangle. have idea on how that? want achieve same effect screen:
many thanks
t
you're lacking couple of tags. here's new sample:
<?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <solid android:color="#ffffff"/> <stroke android:width="3dp" android:color="#ff000000"/> <padding android:left="1dp" android:top="1dp" android:right="1dp" android:bottom="1dp"/> <corners android:radius="30px"/> </shape>
seen here
also, aware of roundrectshape?
Comments
Post a Comment