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

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

Issue 2892293002: Add a basic support of text-align:right property to NGInlineLayoutAlgorithm. (Closed)
Patch Set: fix comments 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 NGLineBoxFragmentBuilder_h 5 #ifndef NGLineBoxFragmentBuilder_h
6 #define NGLineBoxFragmentBuilder_h 6 #define NGLineBoxFragmentBuilder_h
7 7
8 #include "core/layout/ng/geometry/ng_logical_offset.h" 8 #include "core/layout/ng/geometry/ng_logical_offset.h"
9 #include "core/layout/ng/inline/ng_inline_break_token.h" 9 #include "core/layout/ng/inline/ng_inline_break_token.h"
10 #include "core/layout/ng/inline/ng_line_height_metrics.h" 10 #include "core/layout/ng/inline/ng_line_height_metrics.h"
(...skipping 13 matching lines...) Expand all
24 24
25 NGLineBoxFragmentBuilder& SetDirection(TextDirection); 25 NGLineBoxFragmentBuilder& SetDirection(TextDirection);
26 26
27 NGLineBoxFragmentBuilder& SetInlineSize(LayoutUnit); 27 NGLineBoxFragmentBuilder& SetInlineSize(LayoutUnit);
28 28
29 NGLineBoxFragmentBuilder& AddChild(RefPtr<NGPhysicalFragment>, 29 NGLineBoxFragmentBuilder& AddChild(RefPtr<NGPhysicalFragment>,
30 const NGLogicalOffset&); 30 const NGLogicalOffset&);
31 void MoveChildrenInBlockDirection(LayoutUnit); 31 void MoveChildrenInBlockDirection(LayoutUnit);
32 void MoveChildrenInBlockDirection(LayoutUnit, unsigned start, unsigned end); 32 void MoveChildrenInBlockDirection(LayoutUnit, unsigned start, unsigned end);
33 33
34 void MoveChildrenInInlineDirection(LayoutUnit delta);
35
34 const Vector<RefPtr<NGPhysicalFragment>>& Children() const { 36 const Vector<RefPtr<NGPhysicalFragment>>& Children() const {
35 return children_; 37 return children_;
36 } 38 }
37 39
38 void SetMetrics(const NGLineHeightMetrics&); 40 void SetMetrics(const NGLineHeightMetrics&);
39 const NGLineHeightMetrics& Metrics() const { return metrics_; } 41 const NGLineHeightMetrics& Metrics() const { return metrics_; }
40 42
41 // Set the break token for the fragment to build. 43 // Set the break token for the fragment to build.
42 // A finished break token will be attached if not set. 44 // A finished break token will be attached if not set.
43 void SetBreakToken(RefPtr<NGInlineBreakToken>); 45 void SetBreakToken(RefPtr<NGInlineBreakToken>);
(...skipping 12 matching lines...) Expand all
56 Vector<NGLogicalOffset> offsets_; 58 Vector<NGLogicalOffset> offsets_;
57 59
58 NGLineHeightMetrics metrics_; 60 NGLineHeightMetrics metrics_;
59 61
60 RefPtr<NGInlineBreakToken> break_token_; 62 RefPtr<NGInlineBreakToken> break_token_;
61 }; 63 };
62 64
63 } // namespace blink 65 } // namespace blink
64 66
65 #endif // NGLineBoxFragmentBuilder 67 #endif // NGLineBoxFragmentBuilder
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698