Package-level declarations

Types

Link copied to clipboard
data class MaterialSymbolFonts(val outlined: FontFamily, val outlinedFilled: FontFamily, val rounded: FontFamily, val roundedFilled: FontFamily, val sharp: FontFamily, val sharpFilled: FontFamily)

The 6 loaded Material Symbols font family variants — one per (outlined/rounded/sharp) × (regular/filled) combination — built once by loadMaterialSymbolFonts.

Link copied to clipboard
data class MaterialSymbolFontsConfig(val weight: FontWeight = FontWeight.Normal, val grade: Int = 0, val opticalSize: TextUnit = 24.sp)

Variable-font axis configuration applied uniformly to every Material Symbol glyph in the app — passed via MosaicThemeConfig.materialSymbolFontsConfig in MosaicApplication.

Link copied to clipboard

Which of the 3 bundled Material Symbols font families a glyph draws from — matches IconSchema.Style one-to-one (see IconSchema.Style.toMaterialSymbolStyle()).

Functions

Link copied to clipboard

Builds the 6 MaterialSymbolFonts variants from config's variable-font axis settings — called once by MosaicTheme to populate LocalMaterialSymbolFonts. Every glyph in the app shares the same config, since Compose's variable-font variation settings are baked into the FontFamily itself rather than adjustable per-glyph at draw time.

Link copied to clipboard
fun MaterialSymbol(iconName: String, modifier: Modifier = Modifier, filled: Boolean = false, style: MaterialSymbolStyle? = null, size: Dp? = null, tint: Color? = null, contentDescription: String? = null)

Renders one Google Material Symbol glyph as a single-character Text, using the variable font loaded via LocalMaterialSymbolFonts (MaterialSymbolFonts.loadMaterialSymbolFonts must have run and provided that CompositionLocalMosaicApplication/MosaicTheme does this automatically). The bottom-level primitive behind Icon — reach for that instead unless working with an IconSchema-independent icon name directly.