Issue #1970 - Part 6: Rename CalcLineHeight(), and cache used line height

To better distinguish the calculation of line height (still present with args)
and simply getting the line height without args, it's now called GetLineHeight()
This also introduces `mLineHeight` to cache specifically calculated line heights
that aren't "auto" (which is a magic value), and it opens up the possibility to
override it in Part 7.
This commit is contained in:
Moonchild 2022-07-23 23:35:18 +00:00 committed by roytam1
commit 7203916733
5 changed files with 23 additions and 16 deletions

View file

@ -363,7 +363,7 @@ nsRubyBaseContainerFrame::Reflow(nsPresContext* aPresContext,
// Line number is useless for ruby text
// XXX nullptr here may cause problem, see comments for
// nsLineLayout::mBlockRI and nsLineLayout::AddFloat
lineLayout->Init(nullptr, reflowInput->CalcLineHeight(), -1);
lineLayout->Init(nullptr, reflowInput->GetLineHeight(), -1);
reflowInput->mLineLayout = lineLayout;
// Border and padding are suppressed on ruby text containers.