package com.ossovita.stopwatch; import android.content.Context; import android.graphics.Typeface; import androidx.core.content.res.ResourcesCompat; public class Fonts { Context context; Typeface MLight; Typeface MMedium; Typeface MRegular; public Fonts() { } public Typeface getMLight(Context context) { MLight = Typeface.createFromAsset(context.getAssets(),"fonts/MLight.ttf"); return MLight; } public Typeface getMMedium(Context context) { MMedium = Typeface.createFromAsset(context.getAssets(),"fonts/MMedium.ttf"); return MMedium; } public Typeface getMRegular(Context context) { MRegular = Typeface.createFromAsset(context.getAssets(),"fonts/MRegular.ttf"); return MRegular; } }