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

Unified Diff: include/ports/SkFontMgr.h

Issue 21149008: refactoring for SK_FONTHOST_USES_FONTMGR option (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase Created 7 years, 5 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 | « include/core/SkTypeface.h ('k') | src/core/SkFontHost.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/ports/SkFontMgr.h
diff --git a/include/ports/SkFontMgr.h b/include/ports/SkFontMgr.h
index 09df51e3817fffdbbad62ec15dedd1782c85fd67..d2438256b05ffbb4e3375c0f7ca21e12525b79d2 100644
--- a/include/ports/SkFontMgr.h
+++ b/include/ports/SkFontMgr.h
@@ -31,6 +31,8 @@ private:
typedef SkRefCnt INHERITED;
};
+class SkTypeface;
+
class SK_API SkFontMgr : public SkRefCnt {
public:
SK_DECLARE_INST_COUNT(SkFontMgr)
@@ -73,6 +75,9 @@ public:
*/
SkTypeface* createFromFile(const char path[], int ttcIndex = 0);
+ SkTypeface* legacyCreateTypeface(const char familyName[],
+ unsigned typefaceStyleBits);
+
/**
* Return a ref to the default fontmgr. The caller must call unref() on
* the returned object.
@@ -95,6 +100,9 @@ protected:
virtual SkTypeface* onCreateFromStream(SkStream*, int ttcIndex) = 0;
virtual SkTypeface* onCreateFromFile(const char path[], int ttcIndex) = 0;
+ // TODO: make this pure-virtual once all ports know about it
+ virtual SkTypeface* onLegacyCreateTypeface(const char familyName[],
+ unsigned styleBits);
private:
static SkFontMgr* Factory(); // implemented by porting layer
« no previous file with comments | « include/core/SkTypeface.h ('k') | src/core/SkFontHost.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698