Stay organized with collections
Save and categorize content based on your preferences.
TextAppearanceConfig
public
class
TextAppearanceConfig
extends Object
java.lang.Object
|
↳ |
com.google.android.material.resources.TextAppearanceConfig
|
This class is deprecated.
The class is no longer needed because TextAppearance checks internally whether the
desired typeface has already been fetched and cached.
Utility for configuring TextAppearance.
Summary
Inherited methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
Public constructors
TextAppearanceConfig
public TextAppearanceConfig ()
Public methods
setShouldLoadFontSynchronously
public static void setShouldLoadFontSynchronously (boolean flag)
Specifies whether font resources should be loaded synchronously. By default, they are loaded
asynchronously to avoid ANR. Preload font resources and set this to true in emulator /
instrumentation tests to avoid flakiness.
shouldLoadFontSynchronously
public static boolean shouldLoadFontSynchronously ()
Returns flag indicating whether font resources should be loaded synchronously.
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# TextAppearanceConfig\n\nSummary: [Ctors](#pubctors) \\| [Methods](#pubmethods) \\| [Inherited Methods](#inhmethods) \n\nTextAppearanceConfig\n====================\n\n\n`\npublic\n\n\nclass\nTextAppearanceConfig\n`\n\n\n`\n\nextends Object\n\n\n`\n\n`\n\n\n`\n\n|---|------------------------------------------------------------|\n| java.lang.Object ||\n| ↳ | com.google.android.material.resources.TextAppearanceConfig |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\n\n**This class is deprecated.** \n\nThe class is no longer needed because TextAppearance checks internally whether the\ndesired typeface has already been fetched and cached.\n\nUtility for configuring TextAppearance.\n\nSummary\n-------\n\n| ### Public constructors ||\n|------------------------------------------------------------------------------------------------------------------------------|---|\n| ` `[TextAppearanceConfig](/reference/com/google/android/material/resources/TextAppearanceConfig#TextAppearanceConfig())`() ` |\n\n| ### Public methods ||\n|-------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` static void` | ` `[setShouldLoadFontSynchronously](/reference/com/google/android/material/resources/TextAppearanceConfig#setShouldLoadFontSynchronously(boolean))`(boolean flag) ` Specifies whether font resources should be loaded synchronously. |\n| ` static boolean` | ` `[shouldLoadFontSynchronously](/reference/com/google/android/material/resources/TextAppearanceConfig#shouldLoadFontSynchronously())`() ` Returns flag indicating whether font resources should be loaded synchronously. |\n\n| ### Inherited methods |\n|-----------------------|---|\n| From class ` java.lang.Object ` |-------------------|-------------------------------| | ` Object` | ` clone() ` | | ` boolean` | ` equals(Object arg0) ` | | ` void` | ` finalize() ` | | ` final Class\u003c?\u003e` | ` getClass() ` | | ` int` | ` hashCode() ` | | ` final void` | ` notify() ` | | ` final void` | ` notifyAll() ` | | ` String` | ` toString() ` | | ` final void` | ` wait(long arg0, int arg1) ` | | ` final void` | ` wait(long arg0) ` | | ` final void` | ` wait() ` | ||\n\nPublic constructors\n-------------------\n\n### TextAppearanceConfig\n\n```\npublic TextAppearanceConfig ()\n```\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\nPublic methods\n--------------\n\n### setShouldLoadFontSynchronously\n\n```\npublic static void setShouldLoadFontSynchronously (boolean flag)\n```\n\nSpecifies whether font resources should be loaded synchronously. By default, they are loaded\nasynchronously to avoid ANR. Preload font resources and set this to true in emulator /\ninstrumentation tests to avoid flakiness.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|--------|------------------|\n| `flag` | `boolean` \u003cbr /\u003e |\n\n### shouldLoadFontSynchronously\n\n```\npublic static boolean shouldLoadFontSynchronously ()\n```\n\nReturns flag indicating whether font resources should be loaded synchronously.\n\n\u003cbr /\u003e\n\n| Returns ||\n|-----------|--------|\n| `boolean` | \u003cbr /\u003e |"]]