| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #ifndef SkTestScalerContext_DEFINED | 8 #ifndef SkTestScalerContext_DEFINED |
| 9 #define SkTestScalerContext_DEFINED | 9 #define SkTestScalerContext_DEFINED |
| 10 | 10 |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 void getPath(const SkGlyph& glyph, SkPath* path); | 67 void getPath(const SkGlyph& glyph, SkPath* path); |
| 68 protected: | 68 protected: |
| 69 SkScalerContext* onCreateScalerContext(const SkDescriptor* desc) const overr
ide; | 69 SkScalerContext* onCreateScalerContext(const SkDescriptor* desc) const overr
ide; |
| 70 void onFilterRec(SkScalerContextRec* rec) const override; | 70 void onFilterRec(SkScalerContextRec* rec) const override; |
| 71 SkAdvancedTypefaceMetrics* onGetAdvancedTypefaceMetrics( | 71 SkAdvancedTypefaceMetrics* onGetAdvancedTypefaceMetrics( |
| 72 PerGlyphInfo, | 72 PerGlyphInfo, |
| 73 const uint32_t* glyphIDs, | 73 const uint32_t* glyphIDs, |
| 74 uint32_t glyphIDsCount) const override; | 74 uint32_t glyphIDsCount) const override; |
| 75 | 75 |
| 76 SkStreamAsset* onOpenStream(int* ttcIndex) const override { | 76 SkStreamAsset* onOpenStream(int* ttcIndex) const override { |
| 77 return NULL; | 77 return nullptr; |
| 78 } | 78 } |
| 79 | 79 |
| 80 void onGetFontDescriptor(SkFontDescriptor* desc, bool* isLocal) const overri
de; | 80 void onGetFontDescriptor(SkFontDescriptor* desc, bool* isLocal) const overri
de; |
| 81 | 81 |
| 82 int onCharsToGlyphs(const void* chars, Encoding encoding, | 82 int onCharsToGlyphs(const void* chars, Encoding encoding, |
| 83 uint16_t glyphs[], int glyphCount) const override; | 83 uint16_t glyphs[], int glyphCount) const override; |
| 84 | 84 |
| 85 int onCountGlyphs() const override { | 85 int onCountGlyphs() const override { |
| 86 return (int) fTestFont->fCharCodesCount; | 86 return (int) fTestFont->fCharCodesCount; |
| 87 } | 87 } |
| (...skipping 15 matching lines...) Expand all Loading... |
| 103 return 0; | 103 return 0; |
| 104 } | 104 } |
| 105 private: | 105 private: |
| 106 SkTestFont* fTestFont; | 106 SkTestFont* fTestFont; |
| 107 friend class SkTestScalerContext; | 107 friend class SkTestScalerContext; |
| 108 }; | 108 }; |
| 109 | 109 |
| 110 SkTypeface* CreateTestTypeface(const char* name, SkTypeface::Style style); | 110 SkTypeface* CreateTestTypeface(const char* name, SkTypeface::Style style); |
| 111 | 111 |
| 112 #endif | 112 #endif |
| OLD | NEW |