another CJK related question: i followed the steps...
# compose-web
w
another CJK related question: i followed the steps in https://github.com/JetBrains/compose-multiplatform-core/pull/1400 to preload noto color emoji as fallback font, then i tried adding noto sans CJK too in the same font family but it seems like i can only see emoji and not any of CJK characters?
solved 1
Screenshot 2025-03-17 at 01.44.41.png
the preload looked like this,
Copy code
fontFamilyResolver.preload(
    FontFamily(
        Font("NotoColorEmoji", emojiFontByte),
        Font("NotoSansJP", japaneseFontByte),
        Font("NotoSansSC", simplifiedChineseFontByte),
        Font("NotoSansTC", traditionalChineseFontByte),
        Font("NotoSansKR", koreanFontByte),
    )
)
I tried comment out emoji, then the JP characters will appear, is it only one font that can be used as fallback?
oh... this worked instead
Copy code
fontFamilyResolver.preload(FontFamily(Font("NotoColorEmoji", emojiFontByte)))
fontFamilyResolver.preload(FontFamily(Font("NotoSansJP", japaneseFontByte)))            fontFamilyResolver.preload(FontFamily(Font("NotoSansSC", simplifiedChineseFontByte)))
fontFamilyResolver.preload(FontFamily(Font("NotoSansTC", traditionalChineseFontByte)))
fontFamilyResolver.preload(FontFamily(Font("NotoSansKR", koreanFontByte)))
uh......
for anyone else that wants to support all the languages font for some reason.. including emoji there's at least 23 non-english fonts you will need to preload (at least from my languages.json) JP + TC + SC + KR = 24.2MB other 19 languages added up = 1.1MB and I'm only including the Regular variant
The following language fonts were preloaded: • Emoji • Japanese • Simplified Chinese • Traditional Chinese • Korean • Devanagari • Kannada • Ethiopic • Arabic • Armenian • Myanmar • Thai • Georgian • Sinhala • Bengali • Hebrew • Khmer • Lao • Gujarati • Malayalam • Gurmukhi • Telugu • Tamil