| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef ShapeResultBuffer_h | 5 #ifndef ShapeResultBuffer_h |
| 6 #define ShapeResultBuffer_h | 6 #define ShapeResultBuffer_h |
| 7 | 7 |
| 8 #include "platform/fonts/shaping/ShapeResult.h" | 8 #include "platform/fonts/shaping/ShapeResult.h" |
| 9 #include "wtf/Allocator.h" | 9 #include "wtf/Allocator.h" |
| 10 #include "wtf/RefPtr.h" | 10 #include "wtf/RefPtr.h" |
| 11 #include "wtf/Vector.h" | 11 #include "wtf/Vector.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 struct CharacterRange; | 15 struct CharacterRange; |
| 16 class GlyphBuffer; | 16 class GlyphBuffer; |
| 17 struct GlyphData; |
| 17 class TextRun; | 18 class TextRun; |
| 18 | 19 |
| 19 class ShapeResultBuffer { | 20 class ShapeResultBuffer { |
| 20 WTF_MAKE_NONCOPYABLE(ShapeResultBuffer); | 21 WTF_MAKE_NONCOPYABLE(ShapeResultBuffer); |
| 21 STACK_ALLOCATED(); | 22 STACK_ALLOCATED(); |
| 22 | 23 |
| 23 public: | 24 public: |
| 24 ShapeResultBuffer() : m_hasVerticalOffsets(false) {} | 25 ShapeResultBuffer() : m_hasVerticalOffsets(false) {} |
| 25 | 26 |
| 26 void appendResult(PassRefPtr<const ShapeResult> result) { | 27 void appendResult(PassRefPtr<const ShapeResult> result) { |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 | 75 |
| 75 // Empirically, cases where we get more than 50 ShapeResults are extremely | 76 // Empirically, cases where we get more than 50 ShapeResults are extremely |
| 76 // rare. | 77 // rare. |
| 77 Vector<RefPtr<const ShapeResult>, 64> m_results; | 78 Vector<RefPtr<const ShapeResult>, 64> m_results; |
| 78 bool m_hasVerticalOffsets; | 79 bool m_hasVerticalOffsets; |
| 79 }; | 80 }; |
| 80 | 81 |
| 81 } // namespace blink | 82 } // namespace blink |
| 82 | 83 |
| 83 #endif // ShapeResultBuffer_h | 84 #endif // ShapeResultBuffer_h |
| OLD | NEW |