Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(131)

Side by Side Diff: third_party/WebKit/Source/core/layout/ng/inline/ng_inline_item.h

Issue 2871733003: [LayoutNG] Refactor NGLineBreaker for ShapingLineBreaker (Closed)
Patch Set: Cleanup Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 NGInlineItem_h 5 #ifndef NGInlineItem_h
6 #define NGInlineItem_h 6 #define NGInlineItem_h
7 7
8 #include "platform/LayoutUnit.h" 8 #include "platform/LayoutUnit.h"
9 #include "platform/fonts/FontFallbackPriority.h" 9 #include "platform/fonts/FontFallbackPriority.h"
10 #include "platform/fonts/SimpleFontData.h" 10 #include "platform/fonts/SimpleFontData.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 bidi_level_(UBIDI_LTR), 60 bidi_level_(UBIDI_LTR),
61 shape_options_(kPreContext | kPostContext), 61 shape_options_(kPreContext | kPostContext),
62 rotate_sideways_(false), 62 rotate_sideways_(false),
63 fallback_priority_(FontFallbackPriority::kInvalid) { 63 fallback_priority_(FontFallbackPriority::kInvalid) {
64 DCHECK_GE(end, start); 64 DCHECK_GE(end, start);
65 } 65 }
66 66
67 NGInlineItemType Type() const { return static_cast<NGInlineItemType>(type_); } 67 NGInlineItemType Type() const { return static_cast<NGInlineItemType>(type_); }
68 const char* NGInlineItemTypeToString(int val) const; 68 const char* NGInlineItemTypeToString(int val) const;
69 69
70 const ShapeResult* TextShapeResult() const { return shape_result_.Get(); }
70 NGLayoutInlineShapeOptions ShapeOptions() const { 71 NGLayoutInlineShapeOptions ShapeOptions() const {
71 return static_cast<NGLayoutInlineShapeOptions>(shape_options_); 72 return static_cast<NGLayoutInlineShapeOptions>(shape_options_);
72 } 73 }
73 74
74 unsigned StartOffset() const { return start_offset_; } 75 unsigned StartOffset() const { return start_offset_; }
75 unsigned EndOffset() const { return end_offset_; } 76 unsigned EndOffset() const { return end_offset_; }
76 unsigned Length() const { return end_offset_ - start_offset_; } 77 unsigned Length() const { return end_offset_ - start_offset_; }
77 TextDirection Direction() const { 78 TextDirection Direction() const {
78 return BidiLevel() & 1 ? TextDirection::kRtl : TextDirection::kLtr; 79 return BidiLevel() & 1 ? TextDirection::kRtl : TextDirection::kLtr;
79 } 80 }
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 167
167 private: 168 private:
168 NGInlineItem* start_item_; 169 NGInlineItem* start_item_;
169 unsigned size_; 170 unsigned size_;
170 unsigned start_index_; 171 unsigned start_index_;
171 }; 172 };
172 173
173 } // namespace blink 174 } // namespace blink
174 175
175 #endif // NGInlineItem_h 176 #endif // NGInlineItem_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698