OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The Android Open Source Project | 2 * Copyright 2006 The Android Open Source Project |
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 SkGlyph_DEFINED | 8 #ifndef SkGlyph_DEFINED |
9 #define SkGlyph_DEFINED | 9 #define SkGlyph_DEFINED |
10 | 10 |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 } else if (SkMask::kARGB32_Format == format) { | 87 } else if (SkMask::kARGB32_Format == format) { |
88 rb <<= 2; | 88 rb <<= 2; |
89 } else if (SkMask::kLCD16_Format == format) { | 89 } else if (SkMask::kLCD16_Format == format) { |
90 rb = SkAlign4(rb << 1); | 90 rb = SkAlign4(rb << 1); |
91 } else { | 91 } else { |
92 rb = SkAlign4(rb); | 92 rb = SkAlign4(rb); |
93 } | 93 } |
94 return rb; | 94 return rb; |
95 } | 95 } |
96 | 96 |
| 97 #ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK |
97 SK_ATTR_DEPRECATED("Temporary accessor for Android.") | 98 SK_ATTR_DEPRECATED("Temporary accessor for Android.") |
98 SkFixed advanceXFixed() const { return fAdvanceX; } | 99 SkFixed advanceXFixed() const { return fAdvanceX; } |
99 SK_ATTR_DEPRECATED("Temporary accessor for Android.") | 100 SK_ATTR_DEPRECATED("Temporary accessor for Android.") |
100 SkFixed advanceYFixed() const { return fAdvanceY; } | 101 SkFixed advanceYFixed() const { return fAdvanceY; } |
| 102 #endif |
101 | 103 |
102 unsigned rowBytes() const { | 104 unsigned rowBytes() const { |
103 return ComputeRowBytes(fWidth, (SkMask::Format)fMaskFormat); | 105 return ComputeRowBytes(fWidth, (SkMask::Format)fMaskFormat); |
104 } | 106 } |
105 | 107 |
106 bool isJustAdvance() const { | 108 bool isJustAdvance() const { |
107 return MASK_FORMAT_JUST_ADVANCE == fMaskFormat; | 109 return MASK_FORMAT_JUST_ADVANCE == fMaskFormat; |
108 } | 110 } |
109 | 111 |
110 bool isFullMetrics() const { | 112 bool isFullMetrics() const { |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 // FIXME - This is needed because the Android frame work directly | 202 // FIXME - This is needed because the Android frame work directly |
201 // accesses fID. Remove when fID accesses are cleaned up. | 203 // accesses fID. Remove when fID accesses are cleaned up. |
202 #ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK | 204 #ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK |
203 public: | 205 public: |
204 #endif | 206 #endif |
205 uint32_t fID; | 207 uint32_t fID; |
206 }; | 208 }; |
207 SK_END_REQUIRE_DENSE | 209 SK_END_REQUIRE_DENSE |
208 | 210 |
209 #endif | 211 #endif |
OLD | NEW |