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

Unified Diff: include/core/SkTypeface.h

Issue 1818043002: SkTypeface::MakeFromName to take SkFontStyle. (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Decrease the change scope for changing the width to a generic one. Created 4 years, 9 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 | src/core/SkTypeface.cpp » ('j') | src/core/SkTypeface.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkTypeface.h
diff --git a/include/core/SkTypeface.h b/include/core/SkTypeface.h
index 0b1ca6a4bdaf02c231fa61fe2e62a68f24b94672..75688665ed9a4ea8e3a9fcf2a6bfbd147b954c5b 100644
--- a/include/core/SkTypeface.h
+++ b/include/core/SkTypeface.h
@@ -99,16 +99,17 @@ public:
*/
static SkTypeface* RefDefault(Style style = SkTypeface::kNormal);
- /** Return a new reference to the typeface that most closely matches the
- requested familyName and style. Pass null as the familyName to return
- the default font for the requested style. Will never return null
+ /** Creates a new reference to the typeface that most closely matches the
+ requested familyName and fontStyle. This method allows extended font
+ face specifiers as in the SkFontStyle type. Will never return null.
@param familyName May be NULL. The name of the font family.
- @param style The style (normal, bold, italic) of the typeface.
+ @param fontStyle The style of the typeface.
@return reference to the closest-matching typeface. Call must call
unref() when they are done.
- */
- static SkTypeface* CreateFromName(const char familyName[], Style style);
+ */
+ static SkTypeface* CreateFromName(const char familyName[],
bungeman-skia 2016/03/22 20:16:43 You're not going to be able to change this signatu
Mikus 2016/03/24 12:08:26 Done. Added and ifdef for the legacy code.
+ SkFontStyle fontStyle);
/** Return a new reference to the typeface that most closely matches the
requested typeface and specified Style. Use this call if you want to
« no previous file with comments | « no previous file | src/core/SkTypeface.cpp » ('j') | src/core/SkTypeface.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698