| Index: third_party/WebKit/Source/core/layout/ng/inline/ng_line_height_metrics.h
|
| diff --git a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_height_metrics.h b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_height_metrics.h
|
| index 46125ce733afffc8af686351765028660088c7d7..8c171a1762efc351e65ccb900462e781c3f1ba61 100644
|
| --- a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_height_metrics.h
|
| +++ b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_height_metrics.h
|
| @@ -19,7 +19,8 @@ class FontMetrics;
|
| // compute metrics for line boxes.
|
| // https://drafts.csswg.org/css2/visudet.html#line-height
|
| struct NGLineHeightMetrics {
|
| - NGLineHeightMetrics() {}
|
| + NGLineHeightMetrics()
|
| + : ascent(LayoutUnit::Min()), descent(LayoutUnit::Min()) {}
|
| NGLineHeightMetrics(LayoutUnit initial_ascent, LayoutUnit initial_descent)
|
| : ascent(initial_ascent), descent(initial_descent) {}
|
|
|
| @@ -30,10 +31,15 @@ struct NGLineHeightMetrics {
|
| // Compute from FontMetrics. The leading is not included.
|
| NGLineHeightMetrics(const FontMetrics&, FontBaseline);
|
|
|
| + bool IsEmpty() const { return ascent == LayoutUnit::Min(); }
|
| +
|
| // Add the leading. Half the leading is added to ascent and descent each.
|
| // https://drafts.csswg.org/css2/visudet.html#leading
|
| void AddLeading(LayoutUnit line_height);
|
|
|
| + // Move the metrics by the specified amount, in line progression direction.
|
| + void Move(LayoutUnit);
|
| +
|
| // Unite a metrics for an inline box to a metrics for a line box.
|
| void Unite(const NGLineHeightMetrics&);
|
|
|
|
|