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 SkTextBlob_DEFINED | 8 #ifndef SkTextBlob_DEFINED |
9 #define SkTextBlob_DEFINED | 9 #define SkTextBlob_DEFINED |
10 | 10 |
(...skipping 29 matching lines...) Expand all Loading... | |
40 public: | 40 public: |
41 RunIterator(const SkTextBlob* blob); | 41 RunIterator(const SkTextBlob* blob); |
42 | 42 |
43 bool done() const; | 43 bool done() const; |
44 void next(); | 44 void next(); |
45 | 45 |
46 uint32_t glyphCount() const; | 46 uint32_t glyphCount() const; |
47 const uint16_t* glyphs() const; | 47 const uint16_t* glyphs() const; |
48 const SkScalar* pos() const; | 48 const SkScalar* pos() const; |
49 const SkPoint& offset() const; | 49 const SkPoint& offset() const; |
50 const SkPaint& font() const; | 50 void applyFont(SkPaint&) const; |
reed1
2014/08/21 21:42:15
Nit:
- mutable arguments (expect ReadBuffer for so
f(malita)
2014/08/21 21:54:05
Done.
| |
51 GlyphPositioning positioning() const; | 51 GlyphPositioning positioning() const; |
52 | 52 |
53 private: | 53 private: |
54 const SkTextBlob* fBlob; | 54 const SkTextBlob* fBlob; |
55 int fIndex; | 55 int fIndex; |
56 }; | 56 }; |
57 | 57 |
58 // A run is a sequence of glyphs sharing the same font metrics and positioni ng mode. | 58 // A run is a sequence of glyphs sharing the same font metrics and positioni ng mode. |
59 struct Run { | 59 struct Run { |
60 uint32_t count; | 60 uint32_t count; |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
170 SkTDArray<SkScalar> fPosBuffer; | 170 SkTDArray<SkScalar> fPosBuffer; |
171 SkTArray<SkTextBlob::Run>* fRuns; | 171 SkTArray<SkTextBlob::Run>* fRuns; |
172 | 172 |
173 SkRect fBounds; | 173 SkRect fBounds; |
174 bool fDeferredBounds; | 174 bool fDeferredBounds; |
175 | 175 |
176 RunBuffer fCurrentRunBuffer; | 176 RunBuffer fCurrentRunBuffer; |
177 }; | 177 }; |
178 | 178 |
179 #endif // SkTextBlob_DEFINED | 179 #endif // SkTextBlob_DEFINED |
OLD | NEW |