Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(363)

Unified Diff: gm/fontmgr.cpp

Issue 670243002: Update fontMgr to take list of bcp47 language tags. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | include/ports/SkFontMgr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/fontmgr.cpp
diff --git a/gm/fontmgr.cpp b/gm/fontmgr.cpp
index a1e7ff2a6861cf27b608d4aa687548c51350cd05..be2b11a272fbf6f04d6f607d58c6d70417f8f649 100644
--- a/gm/fontmgr.cpp
+++ b/gm/fontmgr.cpp
@@ -38,7 +38,11 @@ static SkScalar drawCharacter(SkCanvas* canvas, uint32_t character, SkScalar x,
// find typeface containing the requested character and draw it
SkString ch;
ch.appendUnichar(character);
+#ifdef SK_FM_NEW_MATCH_FAMILY_STYLE_CHARACTER
+ SkTypeface* typeface = fm->matchFamilyStyleCharacter(fontName, fontStyle, &bpc47, 1, character);
+#else
SkTypeface* typeface = fm->matchFamilyStyleCharacter(fontName, fontStyle, bpc47, character);
+#endif
SkSafeUnref(paint.setTypeface(typeface));
x = drawString(canvas, ch, x, y, paint) + 20;
« no previous file with comments | « no previous file | include/ports/SkFontMgr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698