-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setColorFilter not work #10
Comments
Hello,
I also tried to set simply the: view.setColorFilter(ContextCompat.getColor(view.context, colorId)) |
This worked: GlideToVectorYou
|
It is possible to add something like tintList to an image with this lib? |
For PNG i am doing it as below: |
It does not work properly. When you set tint color all of the shape colored as solid. |
i am load image and set color filter but not work, can you help me ?
GlideToVectorYou
.init()
.with(context)
.withListener(new GlideToVectorYouListener() {
@OverRide
public void onLoadFailed() {
}
@OverRide
public void onResourceReady() {
if (Build.VERSION.SDK_INT > Build.VERSION_CODES.P) {
holder.imgCategory.setColorFilter(BlendModeColorFilterCompat.createBlendModeColorFilterCompat(ContextCompat.getColor(context, R.color.colorWhite), BlendModeCompat.SRC_ATOP));
} else {
holder.imgCategory.setColorFilter(new
PorterDuffColorFilter(ContextCompat.getColor(context, R.color.colorWhite), PorterDuff.Mode.SRC_IN));
}
}
})
.load(Uri.parse(category.getAvatar()), holder.imgCategory);
The text was updated successfully, but these errors were encountered: