| 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 23 matching lines...) Expand all Loading... |
| 34 | 34 |
| 35 | 35 |
| 36 SkTestFont(const SkTestFontData& ); | 36 SkTestFont(const SkTestFontData& ); |
| 37 virtual ~SkTestFont(); | 37 virtual ~SkTestFont(); |
| 38 int codeToIndex(SkUnichar charCode) const; | 38 int codeToIndex(SkUnichar charCode) const; |
| 39 void init(const SkScalar* pts, const unsigned char* verbs); | 39 void init(const SkScalar* pts, const unsigned char* verbs); |
| 40 #ifdef SK_DEBUG // detect missing test font data | 40 #ifdef SK_DEBUG // detect missing test font data |
| 41 mutable unsigned char fDebugBits[16]; | 41 mutable unsigned char fDebugBits[16]; |
| 42 mutable SkUnichar fDebugOverage[8]; | 42 mutable SkUnichar fDebugOverage[8]; |
| 43 const char* fDebugName; | 43 const char* fDebugName; |
| 44 SkTypeface::Style fDebugStyle; | 44 SkFontStyle fDebugStyle; |
| 45 const char* debugFontName() const { return fName; } | 45 const char* debugFontName() const { return fName; } |
| 46 #endif | 46 #endif |
| 47 private: | 47 private: |
| 48 const unsigned* fCharCodes; | 48 const unsigned* fCharCodes; |
| 49 const size_t fCharCodesCount; | 49 const size_t fCharCodesCount; |
| 50 const SkFixed* fWidths; | 50 const SkFixed* fWidths; |
| 51 const SkPaint::FontMetrics& fMetrics; | 51 const SkPaint::FontMetrics& fMetrics; |
| 52 const char* fName; | 52 const char* fName; |
| 53 SkPath** fPaths; | 53 SkPath** fPaths; |
| 54 friend class SkTestTypeface; | 54 friend class SkTestTypeface; |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 return 0; | 105 return 0; |
| 106 } | 106 } |
| 107 private: | 107 private: |
| 108 SkTestFont* fTestFont; | 108 SkTestFont* fTestFont; |
| 109 friend class SkTestScalerContext; | 109 friend class SkTestScalerContext; |
| 110 }; | 110 }; |
| 111 | 111 |
| 112 SkTypeface* CreateTestTypeface(const char* name, SkTypeface::Style style); | 112 SkTypeface* CreateTestTypeface(const char* name, SkTypeface::Style style); |
| 113 | 113 |
| 114 #endif | 114 #endif |
| OLD | NEW |