From 5038924a1a9d05504340c16597256b4ca3a1d779 Mon Sep 17 00:00:00 2001 From: Joel Feenstra Date: Thu, 20 Jun 2013 21:39:37 -0400 Subject: [PATCH] Fix line height for "normal" line-height styles. --- src/components/main/layout/inline.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/main/layout/inline.rs b/src/components/main/layout/inline.rs index 2dd258594cd..80ff4b62108 100644 --- a/src/components/main/layout/inline.rs +++ b/src/components/main/layout/inline.rs @@ -797,8 +797,7 @@ impl InlineFlowData { let text_bounds = run.metrics_for_range(range).bounding_box; let em_size = text_bounds.size.height; let line_height = match cur_box.line_height() { - // use the font's leading for normal - CSSLineHeightNormal => text_box.run.font.metrics.leading, + CSSLineHeightNormal => em_size.scale_by(1.14f), CSSLineHeightNumber(l) => em_size.scale_by(l), CSSLineHeightLength(Em(l)) => em_size.scale_by(l), CSSLineHeightLength(Px(l)) => Au::from_frac_px(l),