Avalonia icon indicating copy to clipboard operation
Avalonia copied to clipboard

Kylin V10 Default font family name can't be null or empty

Open netsmallhao opened this issue 1 year ago • 3 comments

Avalonia 11.0.0
Kylin V10 system Startup error image

I don't know how to solve it

.With(new FontManagerOptions
            {
                DefaultFamilyName = "avares://AvaloniaTest/Assets/Fonts/微软雅黑.ttf#Microsoft YaHei",
                FontFallbacks = new[]
                {
                    new FontFallback
                    {
                        FontFamily = new FontFamily("avares://AvaloniaTest/Assets/Fonts/微软雅黑.ttf#Microsoft YaHei")
                    }
                }
            });

This method cannot solve the problem

netsmallhao avatar Jul 11 '23 09:07 netsmallhao

issues 和 discussions 里搜一下就会发现这个问题已经被问过很多次且有解决方法了
请确认系统的 LC_CTYPE 值为 en_US.UTF-8 我在另一个仓库同样问题下面完整的回答


Just need to set system LC_CTYPE to en_US.UTF-8 before launch the application
can execute export LC_CTYPE=en_US.UTF-8

memorydream avatar Jul 11 '23 20:07 memorydream

Can someone add require user try set LC_CTYPE tips to exception message on Linux?

memorydream avatar Jul 11 '23 21:07 memorydream

Can someone add require user try set LC_CTYPE tips to exception message on Linux? I set export Lang=en_ US.UTF-8 can be started now, no more errors will be reported

netsmallhao avatar Jul 12 '23 01:07 netsmallhao

Avalonia 11.0.0 Kylin V10 system Startup error image

I don't know how to solve it

.With(new FontManagerOptions
            {
                DefaultFamilyName = "avares://AvaloniaTest/Assets/Fonts/微软雅黑.ttf#Microsoft YaHei",
                FontFallbacks = new[]
                {
                    new FontFallback
                    {
                        FontFamily = new FontFamily("avares://AvaloniaTest/Assets/Fonts/微软雅黑.ttf#Microsoft YaHei")
                    }
                }
            });

This method cannot solve the problem

这个是可以解决的,检查下你这个tt是否存在avares://AvaloniaTest/Assets/Fonts/微软雅黑.ttf#Microsoft YaHei

Guyiming avatar Aug 06 '23 10:08 Guyiming