rememberVariableIconFont
Creates a variable IconFont using a FontConstructor.
Parameters
a function returning a Font object, taking as parameters the weight (FontWeight) and the variation settings (FontVariation.Settings)
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a resource id.
Parameters
the Android resource identifier of the font (e.g. R.font.my_icon_font)
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont from a file.
Parameters
the font file
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a ParcelFileDescriptor. Requires Android Oreo or higher.
Parameters
the file descriptor for the font file
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont from a file in the assets directory.
Parameters
the full path starting from the assets directory
the supported weights for the font
the Android AssetManager
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a Compose Multiplatform FontResource.
This function is marked as experimental because its Android implementation is using experimental workarounds:
On Android 11 and higher this will shortly create an in-memory file descriptor.
On Android 8 and higher this will create a temporary file (this file will be deleted after the font is loaded).
On Android 7 and lower this will also create a temporary file, but the variation settings will be ignored.
Parameters
the Compose Multiplatform resource ID
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a Compose Multiplatform FontResource.
This function is marked as experimental because its Android implementation is using experimental workarounds:
On Android 11 and higher this will shortly create an in-memory file descriptor.
On Android 8 and higher this will create a temporary file (this file will be deleted after the font is loaded).
On Android 7 and lower this will also create a temporary file, but the variation settings will be ignored.
Parameters
the Compose Multiplatform resource ID
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a resource name.
Parameters
the resource name in classpath
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont from a file.
Parameters
the font file
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using a Skia Typeface.
Parameters
the internal name to differentiate the typeface
the base Skia SkTypeface that will be cloned for each required variation settings
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
the density of the screen, optionally used to convert density-dependent variation settings to pixels
Creates a variable IconFont using a byte array with loaded font data.
Parameters
the internal name to differentiate the typeface
a byte array with loaded font data
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
the density of the screen, optionally used to convert density-dependent variation settings to pixels
Creates a variable IconFont using a Compose Multiplatform FontResource.
This function is marked as experimental because its Android implementation is using experimental workarounds:
On Android 11 and higher this will shortly create an in-memory file descriptor.
On Android 8 and higher this will create a temporary file (this file will be deleted after the font is loaded).
On Android 7 and lower this will also create a temporary file, but the variation settings will be ignored.
Parameters
the Compose Multiplatform resource ID
the supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax
Creates a variable IconFont using the path of a font.
Parameters
fetch path of the font file as seen here
supported weights for the font
the font variation settings, should not include the optical size ('opsz') and must not include the weight ('wght')
the font feature settings, written in a CSS syntax