siyamed / android-shape-imageview

Custom shaped android imageview components
MIT License
2.67k stars 599 forks source link

How can i set border width dynamically and Change its color? #73

Open mnikunjm13 opened 6 years ago

mnikunjm13 commented 6 years ago

i tried this and also from xml default but not working

imageView0 = findViewById(R.id.imageView0); imageView0.setOnTouchListener(this); imageView0.setImageURI(uri); imageView0.setBorderWidth(100); imageView0.setBorderColor(Color.parseColor("#ff0000"));

<com.github.siyamed.shapeimageview.RoundedImageView android:id="@+id/imageView0" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_gravity="center" android:adjustViewBounds="true" android:scaleType="centerCrop"

        app:siBorderColor="@color/md_blue_400"
        app:siBorderWidth="41dp"
         />