<commit_before>package com.livinglifetechway.k4kotlin

import android.content.Context
import android.support.annotation.DrawableRes
import android.support.v4.content.ContextCompat

/**
 * Get color from ContextCompat.getColor(context,color)
 */
fun Context.getDrawableCompat(@DrawableRes drawable: Int) = ContextCompat.getDrawable(this, drawable)<commit_msg>setTintCompat method for tinting drawables<commit_after>package com.livinglifetechway.k4kotlin

import android.content.Context
import android.graphics.drawable.Drawable
import android.support.annotation.DrawableRes
import android.support.v4.content.ContextCompat
import android.support.v4.graphics.drawable.DrawableCompat

/**
 * Get color from ContextCompat.getColor(context,color)
 */
fun Context.getDrawableCompat(@DrawableRes drawable: Int) = ContextCompat.getDrawable(this, drawable)

fun Drawable.setTintCompat(color: Int) = DrawableCompat.setTint(DrawableCompat.wrap(this), color)
{'fraction_non_alphanumeric': 0.09312169312169312, 'fraction_numerical': 0.005291005291005291, 'mean_word_length': 7.678899082568807, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6614436', 'n_tokens_mistral': 272, 'n_tokens_neox': 275, 'n_words': 48}