
Library facilitates creation of Typography from font names or FontFamily for Android and Compose Multiplatform, enhancing customization and consistency in design projects.
A library for Android and Compose Multiplatform, provide functions that create Typography from font name or FontFamily.
app/build.gradle.kts
dependencies {
...
+ implementation("dev.yuyuyuyuyu:createtypography:0.1.0")
}composeApp/build.gradle.kts
kotlin {
...
sourceSets {
...
commonMain.dependencies {
...
+ implementation("dev.yuyuyuyuyu:createtypography:0.1.0")
}
}
}
app/src/main/java/dev/yuyuyuyuyu/createtypography/example/android/ui/theme/Type.kt
val Typography = createTypographyFrom(fontName = "Yomogi")composeApp/src/commonMain/kotlin/dev/yuyuyuyuyu/createtypography/example/multiplatform/App.kt
@Composable
fun App() {
MaterialTheme(
typography = createTypographyFrom(fontFamily = FontFamily(Font(Res.font.Yomogi_Regular))),
) {
Scaffold { innerPadding ->
Box(
modifier = Modifier.padding(innerPadding),
) {
Text(
text = "Hello, ${getPlatform().name}!",
)
}
}
}
}Apache License 2.0
Copyright 2025 yu
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
A library for Android and Compose Multiplatform, provide functions that create Typography from font name or FontFamily.
app/build.gradle.kts
dependencies {
...
+ implementation("dev.yuyuyuyuyu:createtypography:0.1.0")
}composeApp/build.gradle.kts
kotlin {
...
sourceSets {
...
commonMain.dependencies {
...
+ implementation("dev.yuyuyuyuyu:createtypography:0.1.0")
}
}
}
app/src/main/java/dev/yuyuyuyuyu/createtypography/example/android/ui/theme/Type.kt
val Typography = createTypographyFrom(fontName = "Yomogi")composeApp/src/commonMain/kotlin/dev/yuyuyuyuyu/createtypography/example/multiplatform/App.kt
@Composable
fun App() {
MaterialTheme(
typography = createTypographyFrom(fontFamily = FontFamily(Font(Res.font.Yomogi_Regular))),
) {
Scaffold { innerPadding ->
Box(
modifier = Modifier.padding(innerPadding),
) {
Text(
text = "Hello, ${getPlatform().name}!",
)
}
}
}
}Apache License 2.0
Copyright 2025 yu
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.