| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 UI_GFX_RENDER_TEXT_HARFBUZZ_H_ | 5 #ifndef UI_GFX_RENDER_TEXT_HARFBUZZ_H_ |
| 6 #define UI_GFX_RENDER_TEXT_HARFBUZZ_H_ | 6 #define UI_GFX_RENDER_TEXT_HARFBUZZ_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/memory/scoped_vector.h" | 9 #include "base/memory/scoped_vector.h" |
| 10 #include "third_party/harfbuzz-ng/src/hb.h" | 10 #include "third_party/harfbuzz-ng/src/hb.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 // Returns whether the given shaped run contains any missing glyphs. | 32 // Returns whether the given shaped run contains any missing glyphs. |
| 33 bool HasMissingGlyphs() const; | 33 bool HasMissingGlyphs() const; |
| 34 | 34 |
| 35 // Returns the X coordinate of the leading or |trailing| edge of the glyph | 35 // Returns the X coordinate of the leading or |trailing| edge of the glyph |
| 36 // starting at |text_index|, relative to the left of the text (not the view). | 36 // starting at |text_index|, relative to the left of the text (not the view). |
| 37 int GetGlyphXBoundary(size_t text_index, bool trailing) const; | 37 int GetGlyphXBoundary(size_t text_index, bool trailing) const; |
| 38 | 38 |
| 39 int width; | 39 int width; |
| 40 int preceding_run_widths; | 40 int preceding_run_widths; |
| 41 Range range; | 41 Range range; |
| 42 UBiDiDirection direction; | 42 bool is_rtl; |
| 43 UBiDiLevel level; | 43 UBiDiLevel level; |
| 44 UScriptCode script; | 44 UScriptCode script; |
| 45 | 45 |
| 46 scoped_ptr<uint16[]> glyphs; | 46 scoped_ptr<uint16[]> glyphs; |
| 47 scoped_ptr<SkPoint[]> positions; | 47 scoped_ptr<SkPoint[]> positions; |
| 48 scoped_ptr<uint32[]> glyph_to_char; | 48 scoped_ptr<uint32[]> glyph_to_char; |
| 49 size_t glyph_count; | 49 size_t glyph_count; |
| 50 | 50 |
| 51 skia::RefPtr<SkTypeface> skia_face; | 51 skia::RefPtr<SkTypeface> skia_face; |
| 52 int font_size; | 52 int font_size; |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 std::vector<int32_t> logical_to_visual_; | 117 std::vector<int32_t> logical_to_visual_; |
| 118 | 118 |
| 119 bool needs_layout_; | 119 bool needs_layout_; |
| 120 | 120 |
| 121 DISALLOW_COPY_AND_ASSIGN(RenderTextHarfBuzz); | 121 DISALLOW_COPY_AND_ASSIGN(RenderTextHarfBuzz); |
| 122 }; | 122 }; |
| 123 | 123 |
| 124 } // namespace gfx | 124 } // namespace gfx |
| 125 | 125 |
| 126 #endif // UI_GFX_RENDER_TEXT_HARFBUZZ_H_ | 126 #endif // UI_GFX_RENDER_TEXT_HARFBUZZ_H_ |
| OLD | NEW |