OLD | NEW |
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 NGInlineItemResult_h | 5 #ifndef NGInlineItemResult_h |
6 #define NGInlineItemResult_h | 6 #define NGInlineItemResult_h |
7 | 7 |
8 #include "core/layout/ng/geometry/ng_box_strut.h" | 8 #include "core/layout/ng/geometry/ng_box_strut.h" |
9 #include "core/layout/ng/ng_layout_result.h" | 9 #include "core/layout/ng/ng_layout_result.h" |
10 #include "platform/LayoutUnit.h" | 10 #include "platform/LayoutUnit.h" |
(...skipping 21 matching lines...) Expand all Loading... |
32 // Inline size of this item. | 32 // Inline size of this item. |
33 LayoutUnit inline_size; | 33 LayoutUnit inline_size; |
34 | 34 |
35 // ShapeResult for text items. Maybe different from NGInlineItem if re-shape | 35 // ShapeResult for text items. Maybe different from NGInlineItem if re-shape |
36 // is needed in the line breaker. | 36 // is needed in the line breaker. |
37 RefPtr<ShapeResult> shape_result; | 37 RefPtr<ShapeResult> shape_result; |
38 | 38 |
39 // NGLayoutResult for atomic inline items. | 39 // NGLayoutResult for atomic inline items. |
40 RefPtr<NGLayoutResult> layout_result; | 40 RefPtr<NGLayoutResult> layout_result; |
41 | 41 |
42 // NGBoxStrut for atomic inline items. | 42 // Margins for atomic inline items and open/close tags. |
43 NGBoxStrut margins; | 43 NGBoxStrut margins; |
44 | 44 |
| 45 // Borders/padding for open tags. |
| 46 LayoutUnit borders_paddings_block_start; |
| 47 LayoutUnit borders_paddings_block_end; |
| 48 |
45 // Inside of this is not breakable. | 49 // Inside of this is not breakable. |
46 // Used only during line breaking. | 50 // Used only during line breaking. |
47 unsigned no_break_opportunities_inside : 1; | 51 unsigned no_break_opportunities_inside : 1; |
48 | 52 |
49 // Lines must not break after this. | 53 // Lines must not break after this. |
50 // Used only during line breaking. | 54 // Used only during line breaking. |
51 unsigned prohibit_break_after : 1; | 55 unsigned prohibit_break_after : 1; |
52 | 56 |
53 NGInlineItemResult(); | 57 NGInlineItemResult(); |
54 NGInlineItemResult(unsigned index, unsigned start, unsigned end); | 58 NGInlineItemResult(unsigned index, unsigned start, unsigned end); |
55 }; | 59 }; |
56 | 60 |
57 // Represents a set of NGInlineItemResult that form a line box. | 61 // Represents a set of NGInlineItemResult that form a line box. |
58 using NGInlineItemResults = Vector<NGInlineItemResult, 32>; | 62 using NGInlineItemResults = Vector<NGInlineItemResult, 32>; |
59 | 63 |
60 } // namespace blink | 64 } // namespace blink |
61 | 65 |
62 #endif // NGInlineItemResult_h | 66 #endif // NGInlineItemResult_h |
OLD | NEW |