SkTypeface::MakeFromName to take SkFontStyle.
SkTypeface::MakeFromName currently takes SkTypeface::Style,
which is quite limited. This starts the transition to this
function taking SkFontStyle instead.
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1818043002
TBR=reed
He said it sounded like a good idea.
Review-Url: https://codereview.chromium.org/1818043002
diff --git a/tests/FontMgrTest.cpp b/tests/FontMgrTest.cpp
index 414631c..dd280cd 100644
--- a/tests/FontMgrTest.cpp
+++ b/tests/FontMgrTest.cpp
@@ -64,12 +64,12 @@
};
for (size_t i = 0; i < SK_ARRAY_COUNT(inNames); ++i) {
- sk_sp<SkTypeface> first(SkTypeface::MakeFromName(inNames[i], SkTypeface::kNormal));
+ sk_sp<SkTypeface> first(SkTypeface::MakeFromName(inNames[i], SkFontStyle()));
if (nullptr == first.get()) {
continue;
}
for (int j = 0; j < 10; ++j) {
- sk_sp<SkTypeface> face(SkTypeface::MakeFromName(inNames[i], SkTypeface::kNormal));
+ sk_sp<SkTypeface> face(SkTypeface::MakeFromName(inNames[i], SkFontStyle()));
#if 0
SkString name;
face->getFamilyName(&name);