Replies: 2 comments 2 replies
-
Avalonia has not officially supported HarmonyOS yet. The existing support for HarmonyOS from Avalonia is from third parties, so I think it is likely that the problem cannot be solved (or can only be solved by modifying the Avalonia source code). |
Beta Was this translation helpful? Give feedback.
2 replies
-
You should no longer replace the font manager, but register a custom system font collection. Skia's font manager will not work on HarmonyOS so your font manager can't rely on the system. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am adapting Avalonia to a new platform and I am currently facing a problem where the default font manager cannot find the default font and causes a crash, so I used the CustomFontManagerImpl class and now I can successfully display text on HarmonyOS, but only English characters can be displayed.
https://github.com/CeSun/OpenHarmony.Avalonia/blob/main/Src/Avalonia.OpenHarmony/CustomFontManagerImpl.cs
https://github.com/CeSun/OpenHarmony.Avalonia/blob/main/Src/Avalonia.OpenHarmony/OpenHarmonyPlatform.cs#L22
Beta Was this translation helpful? Give feedback.
All reactions