[LFC][IFC] Decouple baseline ascent/descent and baseline offset.
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Jun 2019 20:41:59 +0000 (20:41 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Jun 2019 20:41:59 +0000 (20:41 +0000)
commit720aac40e1116e82dcf126cddd9bcfca934d8e5e
treec7dea4c7ef8e265963c7c73e18da9acf68f627b5
parent44728a1846b8c67b6b921fd43b4c2f39cf502ca5
[LFC][IFC] Decouple baseline ascent/descent and baseline offset.
https://bugs.webkit.org/show_bug.cgi?id=198901
<rdar://problem/51782393>

Reviewed by Antti Koivisto.

Baseline offset is the baseline's distance from the line's logical top -and it is not necessarily the same as the baseline's ascent.
It's easier to track the baseline and its top separately since certain properties only change one or the other.

* layout/inlineformatting/InlineFormattingContextLineLayout.cpp:
(WebCore::Layout::InlineFormattingContext::LineLayout::placeInlineItems const):
(WebCore::Layout::InlineFormattingContext::LineLayout::createDisplayRuns const):
* layout/inlineformatting/InlineLine.cpp:
(WebCore::Layout::Line::Line):
(WebCore::Layout::Line::close):
(WebCore::Layout::Line::adjustBaselineAndLineHeight):
(WebCore::Layout::Line::halfLeadingMetrics):
* layout/inlineformatting/InlineLine.h:
(WebCore::Layout::Line::Content::baselineOffset const):
(WebCore::Layout::Line::Content::setBaselineOffset):
(WebCore::Layout::Line::baselineOffset const):
* layout/inlineformatting/InlineLineBox.h:
(WebCore::Layout::LineBox::baselineOffset const):
(WebCore::Layout::LineBox::LineBox):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@246484 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/layout/inlineformatting/InlineFormattingContextLineLayout.cpp
Source/WebCore/layout/inlineformatting/InlineLine.cpp
Source/WebCore/layout/inlineformatting/InlineLine.h
Source/WebCore/layout/inlineformatting/InlineLineBox.h