Package org.robolectric.shadows
Class ShadowLegacyTypeface
java.lang.Object
org.robolectric.shadows.ShadowTypeface
org.robolectric.shadows.ShadowLegacyTypeface
@Implements(value=android.graphics.Typeface.class,
            isInAndroidSdk=false)
public class ShadowLegacyTypeface
extends ShadowTypeface
Shadow for 
Typeface.- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic final classShadow picker forTypeface.CustomFallbackBuilder.static classShadow forTypeface.Builderstatic classShadow forTypeface.CustomFallbackBuilderthat populatesdescriptionNested classes/interfaces inherited from class org.robolectric.shadows.ShadowTypefaceShadowTypeface.FontDesc, ShadowTypeface.Picker
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionprotected static voidprotected static voidbuildSystemFallback(String xmlPath, String fontDir, ArrayMap<String, Typeface> fontMap, ArrayMap<String, ?> fallbackMap) protected static Typefaceprotected static Typefaceprotected static Typefaceprotected static TypefacecreateFromAsset(AssetManager mgr, String path) protected static TypefacecreateFromFamilies(Object families) protected static TypefacecreateFromFamiliesWithDefault(Object families) protected static TypefacecreateFromFamiliesWithDefault(Object families, int weight, int italic) protected static TypefacecreateFromFamiliesWithDefault(Object families, String fallbackName, int weight, int italic) protected static TypefacecreateFromFile(File path) protected static TypefacecreateFromFile(String path) protected static TypefacecreateFromResources(AssetManager mgr, String path, int cookie) protected static TypefacecreateFromResources(Object entry, AssetManager mgr, String path) protected static TypefacecreateUnderlyingTypeface(String familyName, int style) booleanReturns the font description.protected intgetStyle()inthashCode()protected static voidinit()Avoid spurious error message about /system/etc/fonts.xmlprotected static voidinitSystemDefaultTypefaces(Map<String, Typeface> systemFontMap, Map<String, ?> fallbacks, Object aliases) protected static longnativeCreateFromArray(long[] familyArray, int weight, int italic) protected static longnativeCreateFromArray(long[] familyArray, long fallbackTypeface, int weight, int italic) protected static voidnativeForceSetStaticFinalField(String fieldname, Typeface typeface) 
- 
Constructor Details- 
ShadowLegacyTypefacepublic ShadowLegacyTypeface()
 
- 
- 
Method Details- 
__staticInitializer__
- 
create@Implementation(minSdk=28) protected static Typeface create(Typeface family, int weight, boolean italic) 
- 
create
- 
create
- 
createFromAsset
- 
createFromResources@Implementation(minSdk=26, maxSdk=28) protected static Typeface createFromResources(AssetManager mgr, String path, int cookie) 
- 
createFromResources@Implementation(minSdk=26) protected static Typeface createFromResources(Object entry, AssetManager mgr, String path) 
- 
createFromFile
- 
createFromFile
- 
getStyle
- 
equals
- 
hashCode
- 
createFromFamilies
- 
createFromFamiliesWithDefault@HiddenApi @Implementation(maxSdk=25) protected static Typeface createFromFamiliesWithDefault(Object families) 
- 
createFromFamiliesWithDefault@Implementation(minSdk=26, maxSdk=27) protected static Typeface createFromFamiliesWithDefault(Object families, int weight, int italic) 
- 
createFromFamiliesWithDefault@Implementation(minSdk=28) protected static Typeface createFromFamiliesWithDefault(Object families, String fallbackName, int weight, int italic) 
- 
buildSystemFallback
- 
initAvoid spurious error message about /system/etc/fonts.xml
- 
initSystemDefaultTypefaces@HiddenApi @Implementation(minSdk=29, maxSdk=30) protected static void initSystemDefaultTypefaces(Map<String, Typeface> systemFontMap, Map<String, ?> fallbacks, Object aliases) 
- 
createUnderlyingTypeface
- 
nativeCreateFromArray@Implementation(minSdk=26, maxSdk=30) protected static long nativeCreateFromArray(long[] familyArray, int weight, int italic) 
- 
getFontDescriptionReturns the font description.- Specified by:
- getFontDescriptionin class- ShadowTypeface
- Returns:
- Font description.
 
- 
nativeForceSetStaticFinalField@Implementation(minSdk=31) protected static void nativeForceSetStaticFinalField(String fieldname, Typeface typeface) 
- 
nativeCreateFromArray@Implementation(minSdk=31) protected static long nativeCreateFromArray(long[] familyArray, long fallbackTypeface, int weight, int italic) 
 
-