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

Unified Diff: include/core/SkTypeface.h

Issue 869763002: SkTypeface to use SkStreamAsset. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 11 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/SkFontConfigInterface.h » ('j') | no next file with comments »
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 ecf582bd88243a47b6d9b52f6f6feb60bca6a2e0..618e16d636dd8a0959a6392c03b14bf21697dd4d 100644
--- a/include/core/SkTypeface.h
+++ b/include/core/SkTypeface.h
@@ -20,6 +20,7 @@ class SkFontDescriptor;
class SkScalerContext;
struct SkScalerContextRec;
class SkStream;
+class SkStreamAsset;
class SkAdvancedTypefaceMetrics;
class SkWStream;
@@ -130,7 +131,7 @@ public:
not a valid font file, returns null. Ownership of the stream is
transferred, so the caller must not reference it again.
*/
- static SkTypeface* CreateFromStream(SkStream* stream, int index = 0);
+ static SkTypeface* CreateFromStream(SkStreamAsset* stream, int index = 0);
/** Write a unique signature to a stream, sufficient to reconstruct a
typeface referencing the same font when Deserialize is called.
@@ -279,7 +280,7 @@ public:
* collection.
* The caller is responsible for deleting the stream.
*/
- SkStream* openStream(int* ttcIndex) const;
+ SkStreamAsset* openStream(int* ttcIndex) const;
/**
* Return a scalercontext for the given descriptor. If this fails, then
@@ -324,7 +325,7 @@ protected:
const uint32_t* glyphIDs,
uint32_t glyphIDsCount) const = 0;
- virtual SkStream* onOpenStream(int* ttcIndex) const = 0;
+ virtual SkStreamAsset* onOpenStream(int* ttcIndex) const = 0;
virtual void onGetFontDescriptor(SkFontDescriptor*, bool* isLocal) const = 0;
virtual int onCharsToGlyphs(const void* chars, Encoding, uint16_t glyphs[],
« no previous file with comments | « no previous file | include/ports/SkFontConfigInterface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698