Skip to content

Commit

Permalink
Use CultureInfo.Name instead of ISOLanguageName for character matching (
Browse files Browse the repository at this point in the history
  • Loading branch information
Gillibald authored Jun 19, 2024
1 parent b718045 commit 0df64c5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/Skia/Avalonia.Skia/FontManagerImpl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,8 @@ public bool TryMatchCharacter(int codepoint, FontStyle fontStyle,

culture ??= CultureInfo.CurrentUICulture;

t_languageTagBuffer ??= new string[2];
t_languageTagBuffer[0] = culture.TwoLetterISOLanguageName;
t_languageTagBuffer[1] = culture.ThreeLetterISOLanguageName;
t_languageTagBuffer ??= new string[1];
t_languageTagBuffer[0] = culture.Name;

using var skTypeface = _skFontManager.MatchCharacter(null, skFontStyle, t_languageTagBuffer, codepoint);

Expand Down

0 comments on commit 0df64c5

Please sign in to comment.