package defpackage;

import android.graphics.Typeface;
import android.graphics.fonts.Font;
import android.net.Uri;
import android.text.TextUtils;
import j$.util.Objects;
import java.io.IOException;

/* renamed from: ᵬˆᵻᵺ, reason: contains not printable characters */
/* loaded from: classes3.dex */
public final class C4023 extends C0552 {
    @Override // defpackage.C0552
    /* renamed from: ﾞⁱ */
    public final Font mo2354(C3491 c3491) {
        Font fontM11036;
        Uri uri = c3491.f13069;
        boolean zEquals = Objects.equals(uri.getScheme(), "systemfont");
        String str = c3491.f13066;
        String authority = zEquals ? uri.getAuthority() : null;
        if (authority != null) {
            Typeface typefaceCreate = Typeface.create(authority, 0);
            Typeface typefaceCreate2 = Typeface.create(Typeface.DEFAULT, 0);
            if (typefaceCreate == null || typefaceCreate.equals(typefaceCreate2)) {
                typefaceCreate = null;
            }
            if (typefaceCreate != null && (fontM11036 = AbstractC5382.m11036(typefaceCreate)) != null) {
                if (TextUtils.isEmpty(str)) {
                    return fontM11036;
                }
                try {
                    return new Font.Builder(fontM11036).setFontVariationSettings(str).build();
                } catch (IOException unused) {
                }
            }
        }
        return null;
    }
}
