Skip to content
This repository has been archived by the owner on Jan 27, 2023. It is now read-only.

RoundedImageView does not support ColorFilters / tint color #73

Closed
martyglaubitz opened this issue Jan 8, 2015 · 5 comments
Closed
Assignees

Comments

@martyglaubitz
Copy link

While the RoundedDrawable does implement setColorFilter, it does not seem that an tint/colorfilter applied to the RoundedImageView has any effect.

@vinc3m1 vinc3m1 self-assigned this Jan 9, 2015
vinc3m1 added a commit that referenced this issue Jan 26, 2015
@vinc3m1
Copy link
Owner

vinc3m1 commented Jan 26, 2015

can you test out the latest snapshot and make sure it works as expected?

@vinc3m1 vinc3m1 closed this as completed Mar 5, 2015
@martyglaubitz
Copy link
Author

@vinc3m1 sorry, i had no time to test this, but i totally trust you that this's fixed ^^

@sbatezat
Copy link

It seems to work on Nexus 4 / Nexus 5 but it doesn't work on xiaomi mi2. Did'nt had other devices to test on, sorry.
On mi-2, the color filter is applied to the square image view instead of the circle picture.
I've tried with two fonctions:

RoundedImageView.setColorFilter and
RoundedImageView.getDrawable().setColorFilter

Mi2: Android 4.1.1
Nexus: Android 5+

@softmarshmallow
Copy link

solutions?

@lzbrady
Copy link

lzbrady commented Jul 18, 2019

I believe I am running into this issue. Can't seem to get a tint over the top of the image.

XML:

    <com.makeramen.roundedimageview.RoundedImageView
        android:id="@+id/backgroundIV"
        android:layout_width="match_parent"
        android:layout_height="140dp"
        android:adjustViewBounds="true"
        android:alpha="0.6"
        android:background="@color/OrangeBtn"
        android:scaleType="centerCrop"
        android:src="@drawable/bg_image"
        android:tint="@color/OrangeTransparent"
        android:tintMode="src_atop"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        app:riv_corner_radius="8dip"
        app:riv_mutate_background="true"
        app:riv_oval="false" />

I would expect the OrangeTransparent color to be set on top of the image, but this is not the case.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants