SpanStyle

expect class SpanStyle(source)

Initially supported subset of androidx.compose.ui.text.SpanStyle.

The following Compose UI parameters are not yet supported:

  • fontSynthesis: FontSynthesis? — requires porting FontSynthesis; CSS supports font-synthesis but with different semantics

  • fontFamily: FontFamily? — requires porting FontFamily; complex to unify across platforms

  • fontFeatureSettings: String? — requires CSS font-feature-settings support on JS DOM

  • baselineShift: BaselineShift? — requires porting BaselineShift; CSS supports vertical-align but with different semantics

  • textGeometricTransform: TextGeometricTransform? — no direct CSS equivalent

  • localeList: LocaleList? — requires porting LocaleList; CSS supports lang attribute

  • background: Color — can be supported with CSS background-color, but may need careful unification

  • shadow: Shadow? — requires porting Shadow; CSS supports text-shadow

  • platformStyle: PlatformSpanStyle? — platform-specific, not applicable to common API

  • drawStyle: DrawStyle? — requires porting DrawStyle; no direct CSS equivalent

actual class SpanStyle(source)
actual class SpanStyle(source)

Constructors

Link copied to clipboard
expect constructor(color: Color? = null, fontSize: TextUnit = TextUnit.Unspecified, fontWeight: FontWeight? = null, fontStyle: FontStyle? = null, letterSpacing: TextUnit = TextUnit.Unspecified, textDecoration: TextDecoration? = null)
constructor(platformValue: SpanStyle)
actual constructor(color: Color?, fontSize: TextUnit, fontWeight: FontWeight?, fontStyle: FontStyle?, letterSpacing: TextUnit, textDecoration: TextDecoration?)
actual constructor(color: Color?, fontSize: TextUnit, fontWeight: FontWeight?, fontStyle: FontStyle?, letterSpacing: TextUnit, textDecoration: TextDecoration?)

Properties

Link copied to clipboard
expect val color: Color?
actual val color: Color?
actual val color: Color?
Link copied to clipboard
expect val fontSize: TextUnit
actual val fontSize: TextUnit
actual val fontSize: TextUnit
Link copied to clipboard
expect val fontStyle: FontStyle?
actual val fontStyle: FontStyle?
actual val fontStyle: FontStyle?
Link copied to clipboard
expect val fontWeight: FontWeight?
actual val fontWeight: FontWeight?
actual val fontWeight: FontWeight?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard