Package-level declarations

Properties

Link copied to clipboard

The default icon tint for Glance (a ColorProvider) used when none is provided as a parameter of one of the FontIcon functions.

Functions

Link copied to clipboard
fun FontIcon(icon: Char, contentDescription: String?, modifier: GlanceModifier = GlanceModifier, size: Dp = LocalIconSize.current, tint: ColorProvider = LocalGlanceIconTint.current, weight: FontWeight = LocalIconWeight.current, iconFont: IconFont = LocalIconFont.current)

A component that draws the icon using iconFont (with a default value of LocalIconFont). The icon will be size × size dp, and will be tinted with tint. If iconFont is a variable font, weight will applied as a variation setting, or else the font with the nearest weight will be picked.

fun FontIcon(iconName: String, contentDescription: String?, modifier: GlanceModifier = GlanceModifier, size: Dp = LocalIconSize.current, tint: ColorProvider = LocalGlanceIconTint.current, weight: FontWeight = LocalIconWeight.current, iconFont: IconFont = LocalIconFont.current)

A component that draws the icon iconName using iconFont (with a default value of LocalIconFont). The icon will be size × size dp, and will be tinted with tint. If iconFont is a variable font, weight will applied as a variation setting, or else the font with the nearest weight will be picked.

Link copied to clipboard
fun ProvideGlanceIconParameters(iconFont: IconFont = LocalIconFont.current, size: Dp = LocalIconSize.current, tint: ColorProvider = LocalGlanceIconTint.current, weight: FontWeight = LocalIconWeight.current, content: @Composable () -> Unit)

A shortcut method to set default values for the Glance FontIcon composables. Might be better to use CompositionLocalProvider if it's for setting only one of the default values.

Link copied to clipboard
@RequiresApi(value = 26)
fun rememberVariableIconFont(path: String, weights: Array<FontWeight>, fontVariationSettings: Array<FontVariation.Setting> = emptyArray(), fontFeatureSettings: String? = null): IconFont

Creates a variable IconFont from a file in the assets directory