use simplified chinese because and check for that before japanese.

fixes https://github.com/fiatjaf/njump/issues/17
This commit is contained in:
fiatjaf
2023-11-23 22:30:33 -03:00
parent 6574fc3493
commit 3e4cb2a11c
3 changed files with 5 additions and 5 deletions

BIN
fonts/NotoSansSC.ttf Normal file

Binary file not shown.

Binary file not shown.

View File

@@ -260,6 +260,11 @@ func getLanguage(text string) (*truetype.Font, bool, error) {
fontName string
breakWords bool
}{
{
unicode.Han,
"fonts/NotoSansSC.ttf",
true,
},
{
unicode.Katakana,
"fonts/NotoSansJP.ttf",
@@ -270,11 +275,6 @@ func getLanguage(text string) (*truetype.Font, bool, error) {
"fonts/NotoSansJP.ttf",
true,
},
{
unicode.Han,
"fonts/NotoSansTC.ttf",
true,
},
{
unicode.Hangul,
"fonts/NotoSansKR.ttf",