Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion resources/android/TextRenderer.kt
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,8 @@ private fun resolveFontStyle(style: Int): FontStyle {
}

// 0/absent = default (sans); only override for serif/mono so a custom default
// font isn't clobbered.
// font isn't clobbered. 3 (`font-rounded`) has no system face on Android and
// keeps the default, like iOS designs Compose can't draw.
private fun resolveFontFamily(family: Int): FontFamily? = when (family) {
1 -> FontFamily.Serif
2 -> FontFamily.Monospace
Expand Down
1 change: 1 addition & 0 deletions resources/ios/NativeUITextRenderer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,7 @@ struct NativeUITextRenderer: View {
switch family {
case 1: return .serif
case 2: return .monospaced
case 3: return .rounded
default: return .default
}
}
Expand Down
Loading