Commit Graph
68 Commits
Author SHA1 Message Date
Ian Kilpatrick 517d8bb742 Bug 1488882 [wpt PR 12854] - [LayoutNG] Add CalculateChildPercentageSize utility function., a=testonly
Automatic update from web-platform-tests[LayoutNG] Add CalculateChildPercentageSize utility function.

Fixes percentage sized floats which were previously not using the
correct percentage resolution size.

Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: Ie57909b7f452f5d59b8dfe2f899bedf253ab90ac
Reviewed-on: https://chromium-review.googlesource.com/1205200
Commit-Queue: Ian Kilpatrick <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#588959}

--

wpt-commits: 687bba2b04f6279af734274514048f9a3c74ba37
wpt-pr: 12854
2018-09-10 10:12:07 +00:00
Koji Ishii 5ef3656776 Bug 1487663 [wpt PR 12777] - [LayoutNG] Fix when 'vertical-align: top' is nested, a=testonly
Automatic update from web-platform-tests[LayoutNG] Fix when 'vertical-align: top' is nested

The 'vertical-align: top' and 'bottom' require the size of
the ancestor line box and thus are put into pending queue
while applying the baseline shift.

When they are nested, processing all pending queue at the
root line box applies the shift multiple times. This patch
puts into the queue of the nearest ancestor that has 'top'
or 'bottom' if exists.

Bug: 877977
Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: I6541d138267a6e42658b601901b673352e625440
Reviewed-on: https://chromium-review.googlesource.com/1198887
Commit-Queue: Koji Ishii <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Cr-Commit-Position: refs/heads/master@{#588042}

--

wpt-commits: b81e490a7032404418b325277312884b07208ed3
wpt-pr: 12777
2018-09-10 10:11:25 +00:00
Emilio Cobos Álvarez b1a6f33407 Bug 1488294 - Add reftests for groove / ridge borders with default colors. r=jrmuizel
Note that they are negative (!=) tests. Also note that they don't run because
bug 1488472. I'm fixing that as well, will ensure that's fixed before this
lands.

Differential Revision: https://phabricator.services.mozilla.com/D4947
2018-09-07 16:02:35 +00:00
Tien-Ren Chen 19e8b0f98d Bug 1487254 [wpt PR 12749] - [Blink] Remove negative offset compensation for rel-pos inline, a=testonly
Automatic update from web-platform-tests[Blink] Remove negative offset compensation for rel-pos inline

Consider the following case:
<span style="position:relative; left:-100px;">
  <div style="display:inline-block; position:absolute;"></div>
</span>

In our implementation the absolute positioned element will have a
counter offset applied, to ignore the negative offset on its rel-pos
parent.

The compensation was added in https://codereview.chromium.org/423173003/
which wasn't covered by the added test, and isn't consistent with other
browser implementations. (Checked with Safari, IE, and Firefox.)

BUG=398164

Change-Id: I44127ff42446a7483d7e4ebb3197ecdc915db39d
Reviewed-on: https://chromium-review.googlesource.com/1195084
Reviewed-by: Morten Stenshorne <[email protected]>
Commit-Queue: Tien-Ren Chen <[email protected]>
Cr-Commit-Position: refs/heads/master@{#587745}

--

wpt-commits: 8ff2bb67c6b61799c2b25f60c6919580a3e104fc
wpt-pr: 12749
2018-09-05 13:09:11 +00:00
Aleks Totic e052bbfcf3 Bug 1486688 [wpt PR 12714] - [LayoutNG] Fix legacy initiated abspos invalidation, a=testonly
Automatic update from web-platform-tests[LayoutNG] Fix legacy initiated abspos invalidation

Bug:

LayoutBlock::LayoutPositionedObject had a static position check whether
child reflow was necessary:
  if (.... ||
       (!IsLayoutNGBlockFlow() &&
        NeedsLayoutDueToStaticPosition(positioned_object))))
    layout_scope.SetChildNeedsLayout(positioned_object);
This check would skip reflow for all NGBlockFlow children.
This is incorrect. If child abspos layout was initiated by Legacy,
we should check static position.

Fix:
There was no way to tell in current code whether child abspos layout
was initiated by legacy.
Added a flag is_legacy_initiated_out_of_flow_layout_.
Flag was added to LayoutBlock per ikilpatrick recommendation.
Flag is set to true in LayoutNGBlockFlow::UpdateOutOfFlowBlockLayout
Flag is set to false in NGOutOfFlowLayout.

With this fix, checkboxes on code review page are correct.

Bug: 863865
Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: Ifc55ac03b76dd1aa2113181681bca1b5a2832fb2
Reviewed-on: https://chromium-review.googlesource.com/1190723
Commit-Queue: Aleks Totic <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#586791}

--

wpt-commits: cab4439e4ed25884ba7c6bb0165b56521c7ef029
wpt-pr: 12714
2018-09-05 13:08:34 +00:00
Ciure Andrei 58a237c74e Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-09-01 02:43:10 +03:00
Emilio Cobos Álvarez 7db70df092 Bug 1485669: Upstream the tests from bug 488725. r=dbaron
Differential Revision: https://phabricator.services.mozilla.com/D4076
2018-08-23 15:29:01 +02:00
Andreea Pavel e195677f29 Backed out changeset f6753d3d9db1 (bug 1485669) for failing mochitest chrome at layout/base/tests/chrome/test_printpreview.xul on a CLOSED TREE 2018-08-31 23:39:58 +03:00
Emilio Cobos Álvarez 8233a2c5c3 Bug 1485669: Upstream the tests from bug 488725. r=dbaron
Differential Revision: https://phabricator.services.mozilla.com/D4076
2018-08-31 21:50:38 +02:00
Koji Ishii ed516f3ca3 Bug 1486484 [wpt PR 12694] - Fix fast/table/column-in-inline.html not to rely on wrong behavior, a=testonly
Automatic update from web-platform-testsFix fast/table/column-in-inline.html not to rely on wrong behavior

fast/table/column-in-inline.html says it tests "a table-column
with a table-cell sibling are wrapped inside an inline-table
when the parent is inline" but it also tests:
1. Anonymous inline box inherits non-inherited properties,
   which contradicts with the spec (crbug.com/877946).
2. If the above was fixed, it tests baseline alignment of
   inline tables.

LayoutNG fails because it does not have crbug.com/877946.
This patch changes the test to focus on what it says, and
creates a separate test for crbug.com/869877.

Bug: 869877, 877946
Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: I0b53ec68d5ea59a93010d49891d6bfe3a6688158
Reviewed-on: https://chromium-review.googlesource.com/1179736
Reviewed-by: Emil A Eklund <[email protected]>
Commit-Queue: Emil A Eklund <[email protected]>
Cr-Commit-Position: refs/heads/master@{#586261}

--

wpt-commits: 5b93258a68e80156f410570483b4b0cd19ce6761
wpt-pr: 12694
2018-08-31 10:29:17 +00:00
Aleks Totic 2c44c21be7 Bug 1481979 [wpt PR 12363] - [LayoutNG] Propagate abspos inline container, a=testonly
Automatic update from web-platform-tests[LayoutNG] Propagate abspos inline container

OOF elements with inline container that were not direct descendants
of container did not have their inline container set correctly.
This caused Google SERP page to display a menu incorrectly.

Test

Bug: 867307
Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: Iefc78785d296c87d7fc1f34abe3980c0783d6818
Reviewed-on: https://chromium-review.googlesource.com/1165953
Commit-Queue: Aleks Totic <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#582139}

--

wpt-commits: a827a82cd6be5bfca648b98904c45e2fa3777d20
wpt-pr: 12363
2018-08-15 16:50:27 +00:00
Ian Kilpatrick 50199f9849 Bug 1478963 [wpt PR 12204] - [LayoutNG] Add support for negative margins and new formatting contexts, a=testonly
Automatic update from web-platform-tests[LayoutNG] Add support for negative margins and new formatting contexts

This does two things:
1. Allows a new formatting context to be sized and positioned outside
   its layout opportunity when negative margins are present.
   This occurs when a layout opportunity inline dimensions matches the
   initial child available space (ignoring floats).
   Additionally when a new formatting context "jumps out" of its layout
   opportunity it ignores any floats which might impede it.
2. Performs layout inside an opportunity, and then checks if the result
   can fit within the same opportunity. Previously we were trying to
   position in an arbitrary layout opportunity, which fails the
   new-fc-relayout.html test.

Cq-Include-Trybots: luci.chromium.try​:linux_layout_tests_layout_ng
Change-Id: I6b44b6273be5c0f633e39a8875cc54ea0bc54480
Bug: 635619
Reviewed-on: https://chromium-review.googlesource.com/1150849
Commit-Queue: Ian Kilpatrick <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#579064}

--

wpt-commits: fe2c977518e90340f1a88606fa8844577d577028
wpt-pr: 12204
2018-08-03 09:33:58 +00:00
Philip Jägenstedt faab950fe0 Bug 1476293 [wpt PR 12024] - Add spec links to META.yml, a=testonly
Automatic update from web-platform-testsMerge pull request #12024 from web-platform-tests/meta-specs

Add spec links to META.yml
--

wpt-commits: eeded53153beba20a9c2c8bf35a02ae1d48103cd
wpt-pr: 12024
2018-07-29 18:49:42 +01:00
moz-wptsync-bot ae016b6d13 Bug 1476048 [wpt PR 12000] - [LayoutNG] Support rewinding unpositioned floats, a=testonly
Automatic update from web-platform-tests[LayoutNG] Support rewinding unpositioned floats

This patch supports NGLineBreaker to rewind unpositioned
floats.

When rewinding floats occurs, LayoutNG either position them
incorrectly, or hit DCHECK in paint due to duplicated ID.
This patch fixes it for unpositioned foats by matching to
Edge and Gecko.

Blink considers such floats as if it were committed
(positioned in LayoutNG terminologies) and thus the position
is incorrect.

Bug: 636993
Cq-Include-Trybots: luci.chromium.try :linux_layout_tests_layout_ng
Change-Id: I884879b2034d2f63ae248f70de3edeb27d71cafe
Reviewed-on: https://chromium-review.googlesource.com/1136262
Commit-Queue: Koji Ishii <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Cr-Commit-Position: refs/heads/master@{#575357}

--

wpt-commits: 53702f14ec8b654a9c1beb9a013cdc652703cb40
wpt-pr: 12000
MozReview-Commit-ID: 9ea37E6Spi2
2018-07-29 18:48:24 +01:00
Philip Jägenstedt 977036d752 Bug 1474669 [wpt PR 11888] - Remove reviewers who have not joined the web-platform-tests org, a=testonly
Automatic update from web-platform-testsRemove reviewers who have not joined the web-platform-tests org (#11888)

Part of https://github.com/web-platform-tests/wpt/issues/11293.

Reminder also in https://github.com/web-platform-tests/wpt/issues/11568.

This does not fully resolve #11293, as a few non-responders where
there would be no remaining reviewers are left, and one known to be
out-of-office. These will be handled separately to finish this.
--

wpt-commits: 8fea122cf1ed5b392c86aae5e445e7553ad83deb
wpt-pr: 11888
2018-07-24 21:46:17 +00:00
Morten Stenshorne e4af769f14 Bug 1471744 [wpt PR 11697] - [LayoutNG] Non-"inline" abspos needs to ignore floats and text-indent., a=testonly
Automatic update from web-platform-tests[LayoutNG] Non-"inline" abspos needs to ignore floats and text-indent.

This fixes two tests, but will also eventually benefit
floats-wrap-inside-inline-00[1234].htm in fast/block/float/, which are
currently passing because the absolutely positioned box in the test forces
its container to have block children. There's special-code for NG (which we
should remove) in LayoutBlockFlow::AddChild() that forces this (and causes
other problems).

Added a new test, to make it clear what this fix is about.

Bug: 734554
Cq-Include-Trybots: luci.chromium.try :linux_layout_tests_layout_ng
Change-Id: Ia2c0e0b2ab61999207114fdf935880fabc2e677c
Reviewed-on: https://chromium-review.googlesource.com/1116959
Reviewed-by: Aleks Totic <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#571054}

--

wpt-commits: 12b9b4c9d40504a6d5df9339d7680a8a89184f18
wpt-pr: 11697
MozReview-Commit-ID: 9VzFxid8Ry8
2018-07-11 08:01:02 +01:00
Morten Stenshorne fb5b1169a8 Bug 1469487 [wpt PR 11560] - Reland: Floats and out-of-flow objects may not be adjacent to anonymous blocks., a=testonly
Automatic update from web-platform-testsReland: Floats and out-of-flow objects may not be adjacent to anonymous blocks.

Floats and out-of-flow objects need to be true layout siblings of the
inlines, or rendering will be wrong. This means that such objects should
never be siblings of anonymous blocks, but rather inside them. This
already works correctly for initial layout tree building, and also for
many DOM manipulations. However, code was missing to satisfy this
requirement if we removed a regular block that was a sibling of an
anonymous block and either a float or out-of-flow positioned object.

This even caused a crash triggered by ruby code, which ended up mixing
inline and block children within the same container. That is not
allowed. This happened in the MoveAllChildrenIncludingFloatsTo() call
inside LayoutRubyBase::MoveBlockChildren(). Added a DCHECK to
MoveAllChildrenIncludingFloatsTo() (which could fail prior to this fix);
When moving children from one container to another, either both or none
of the containers must have inline children.

This is a reland of https://chromium-review.googlesource.com/1102690
with some modifications to avoid bug 853552.

Bug: 852640
Change-Id: I0f8a0aa5523e8fe60c841164d25aad088f4b728f
Reviewed-on: https://chromium-review.googlesource.com/1104900
Commit-Queue: Morten Stenshorne <[email protected]>
Commit-Queue: Emil A Eklund <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Cr-Commit-Position: refs/heads/master@{#568196}

--

wpt-commits: 28b5323e37274805b1d1416273e3a941c9c7e08e
wpt-pr: 11560
2018-07-11 07:53:16 +01:00
Abhishek Arya a2d407868e Bug 1469210 [wpt PR 11542] - Revert "Floats and out-of-flow objects may not be adjacent to anonymous blocks.", a=testonly
Automatic update from web-platform-testsRevert "Floats and out-of-flow objects may not be adjacent to anonymous blocks."

This reverts commit 2394d0acf8bf0b0236b2646e4c823a57de7bd941.

Reason for revert: Caused ClusterFuzz regressions - 853522, 853537, 853538, 853540.

Original change's description:
> Floats and out-of-flow objects may not be adjacent to anonymous blocks.
>
> Floats and out-of-flow objects need to be true layout siblings of the
> inlines, or rendering will be wrong. This means that such objects should
> never be siblings of anonymous blocks, but rather inside them. This
> already works correctly for initial layout tree building, and also for
> many DOM manipulations. However, code was missing to satisfy this
> requirement if we removed a regular block that was a sibling of an
> anonymous block and either a float or out-of-flow positioned object.
>
> This even caused a crash triggered by ruby code, which ended up mixing
> inline and block children within the same container. That is not
> allowed. This happened in the MoveAllChildrenIncludingFloatsTo() call
> inside LayoutRubyBase::MoveBlockChildren(). Added a DCHECK to
> MoveAllChildrenIncludingFloatsTo() (which could fail prior to this fix);
> When moving children from one container to another, either both or none
> of the containers must have inline children.
>
> Bug: 852640
> Change-Id: I51d3de12c73ddd07d6b4c1aa55221b4f92359ca7
> Reviewed-on: https://chromium-review.googlesource.com/1102690
> Reviewed-by: Emil A Eklund <[email protected]>
> Commit-Queue: Morten Stenshorne <[email protected]>
> Cr-Commit-Position: refs/heads/master@{#567882}

[email protected],[email protected]

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: 852640
Change-Id: I0af60d9eac770f21b6a0fbeccf88bb43d5efd6fb
Reviewed-on: https://chromium-review.googlesource.com/1103503
Reviewed-by: Abhishek Arya <[email protected]>
Commit-Queue: Abhishek Arya <[email protected]>
Cr-Commit-Position: refs/heads/master@{#567914}

--

wpt-commits: f055233bad9aab52e77148f36b79ca4f34dfa822
wpt-pr: 11542
2018-07-11 07:52:00 +01:00
Morten Stenshorne 7012af1f18 Bug 1469043 [wpt PR 11535] - Floats and out-of-flow objects may not be adjacent to anonymous blocks., a=testonly
Automatic update from web-platform-testsFloats and out-of-flow objects may not be adjacent to anonymous blocks.

Floats and out-of-flow objects need to be true layout siblings of the
inlines, or rendering will be wrong. This means that such objects should
never be siblings of anonymous blocks, but rather inside them. This
already works correctly for initial layout tree building, and also for
many DOM manipulations. However, code was missing to satisfy this
requirement if we removed a regular block that was a sibling of an
anonymous block and either a float or out-of-flow positioned object.

This even caused a crash triggered by ruby code, which ended up mixing
inline and block children within the same container. That is not
allowed. This happened in the MoveAllChildrenIncludingFloatsTo() call
inside LayoutRubyBase::MoveBlockChildren(). Added a DCHECK to
MoveAllChildrenIncludingFloatsTo() (which could fail prior to this fix);
When moving children from one container to another, either both or none
of the containers must have inline children.

Bug: 852640
Change-Id: I51d3de12c73ddd07d6b4c1aa55221b4f92359ca7
Reviewed-on: https://chromium-review.googlesource.com/1102690
Reviewed-by: Emil A Eklund <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#567882}

--

wpt-commits: ab2182ad1005c11556cf3c0c1ee063d57d13f63e
wpt-pr: 11535
2018-07-11 07:51:57 +01:00
moz-wptsync-bot 69e12b5cd9 Bug 1468897 [wpt PR 11515] - Update wpt metadata, a=testonly
wpt-pr: 11515
wpt-type: metadata
MozReview-Commit-ID: Ep3hCydnRdA
2018-07-11 07:51:26 +01:00
Morten Stenshorne f7d911bd04 Bug 1468482 [wpt PR 11485] - [LayoutNG] Avoid creating empty lines at bogus (unset) BFC offset 0,0., a=testonly
Automatic update from web-platform-tests[LayoutNG] Avoid creating empty lines at bogus (unset) BFC offset 0,0.

This affects auto-positioned out-of-flow nodes that are handled as part
of inline layout, and other things too.

This fix will also make it possible to use the position of the last
child fragment to calculate the block size of a block (which I happen to
be working on).

Cq-Include-Trybots: luci.chromium.try :linux_layout_tests_layout_ng;master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ie3f99d850de81bd349e89c624f86cce95b38eede
Reviewed-on: https://chromium-review.googlesource.com/1098925
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#567170}

--

wpt-commits: f556cda8f3ab2c14851a63ecd3def3c03de8182d
wpt-pr: 11485
MozReview-Commit-ID: 2sGbGrFgRze
2018-07-11 07:50:24 +01:00
Jonathon Kereliuk b19084d093 Bug 1464894 [wpt PR 11201] - Rename of OWNER files to META.yml, a=testonly
Automatic update from web-platform-testsRename of OWNER files to META.yml

--

wpt-commits: e600ea2e919641566238cef57ff59f1ee21e50d3
wpt-pr: 11201
2018-07-11 07:49:41 +01:00
Chris Lilley 70350c577e Bug 1473870 [wpt PR 11480] - Fix c563-list-type-000-ref to match the test, a=testonly
Automatic update from web-platform-testsMerge pull request #11480 from gsnedders/c563-list-type-000-ref-fix

Fix c563-list-type-000-ref to match the test
--

wpt-commits: e4ef2f7446056974dfcda1c05a0876c3260d1419
wpt-pr: 11480
2018-07-11 07:49:34 +01:00
Morten Stenshorne ee4e697e14 Bug 1462030 [wpt PR 11033] - [LayoutNG] Improve support for negative clearance., a=testonly
Automatic update from web-platform-tests[LayoutNG] Improve support for negative clearance.

When there are adjoining floats that need to be separated from a cleared
block, clearance is predetermined, and we have to force it on the block.
Any large top margin on the child will just be eaten by negative
clearance. There's nothing that can be done to prevent clearance in such
cases. So make sure that we don't try to determine whether to apply
clearance or not based on the clearance offset set in the constraint
space. When clearance has been predetermined (which may have triggered a
BFC offset resolution and what not), refusing to apply it to the child is
a bug.

This aligns the implementation with the "alternative" way of calculating
clearance in the spec [1]. Everyone but Edge does this. I think what
Edge does here is problematic, because it requires us to use a
hypothetical position that was calculated before clearance got applied
(clearance causes margins that would otherwise collapse to be
separated). We'd end up using a hypothetical position not based on the
actual layout situation.[2]

[1] https://www.w3.org/TR/CSS22/visuren.html#flow-control
[2] https://github.com/w3c/csswg-drafts/issues/2608

This fixes one existing test. Added a few new ones as well. Not all of
them failed prior to this CL, but they serve as regression tests for
things I found to lack coverage while working on this.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ia45e9048c75c338477eee4923ff16eea3245bc6a
Reviewed-on: https://chromium-review.googlesource.com/1061470
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#560208}

--

wpt-commits: 499bf362082f5ca8679ad981536cbb38a98fccb3
wpt-pr: 11033
2018-05-22 09:40:45 +00:00
David Grogan 2ecc802f8c Bug 1460155 [wpt PR 10910] - [LayoutNG] LayoutNG table-caption implementation, a=testonly
Automatic update from web-platform-tests[LayoutNG] LayoutNG table-caption implementation

New passes fast/writing-mode/table-hit-test.html and
tables/mozilla_expected_failures/marvin* had been failing in LayoutNG
because the captions were not centered above the table, for some reason.

The rebased test fast/table/multiple-captions-display-expected.png
failed due to differences on the edges of text inside the caption.

New failure accessibility/table-caption.html fails because the js
accessibility controller can no longer see the caption as a table child,
for some reason.

Making tables/mozilla_expected_failures/bugs/bug3166-16.html pass will
need some digging. Legacy and NG before this patch centered the caption
above the table. But after this patch, it is moved left. Further,
hovering over the caption triggers a DCHECK in the hit testing stack, so
maybe we need to set an offset after all.

ng_physical_fragment.h(144)] Check failed: is_placed_.
blink::NGPhysicalFragment::Offset()
blink::NGPaintFragment::Offset()
blink::NGBoxFragmentPainter::NodeAtPoint()
blink::NGBlockFlowPainter::NodeAtPoint()
blink::LayoutNGMixin<>::NodeAtPoint()
blink::LayoutTable::NodeAtPoint()

Bug: 635619
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I7fcb33e791a9f0d812674a5f7f63cb5964c02a6e
Reviewed-on: https://chromium-review.googlesource.com/1050414
Commit-Queue: David Grogan <[email protected]>
Reviewed-by: Robert Ma <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#557632}

--

wpt-commits: c650b3ea9ac78640b1ec4bf7e476db95154a41e5
wpt-pr: 10910
2018-05-18 11:15:13 +01:00
Morten Stenshorne b290156bd7 Bug 1459954 [wpt PR 10897] - [LayoutNG] Avoid false positives for clearance., a=testonly
Automatic update from web-platform-tests[LayoutNG] Avoid false positives for clearance.

Clearance inhibits margin collapsing and thus makes it possible to
resolve the BFC offset of its parent. In that regard we sometimes
incorrectly assumed that a child would get clearance. The only case
where we can tell for sure up front, is when there are adjoining floats
that match the value of the 'clear' property. In all other cases, we
first need to calculate the block-start border edge of the child.

Added a few new tests. Only two of them failed in NG prior to this CL,
but coverage seemed low, so I added them anyway. Two of them fail in the
legacy engine.

Move the code that detects pending child floats a bit further down, to
give HandleInflow() an opportunity to re-layout the child without
aborting container layout. Otherwise clearance on an empty block will
be lost when positioning the float. Added two tests for this
(second-float-inside-empty-cleared-block*), since nothing except a
multicol test (that happened to do complicated clearance stuff)
regressed.

Removed now unused bits from NGExclusionSpace.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I73b4aa02e5e88d1063f345db271cde1ad31ea9f5
Reviewed-on: https://chromium-review.googlesource.com/1049974
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#557282}

--

wpt-commits: 857126e062ef13c28981a9a1a01df4695f74715d
wpt-pr: 10897
2018-05-18 11:15:13 +01:00
Bert Bos c5fbf7ce24 Bug 1460236 [wpt PR 7579] - Baseline of inline-block for different values of overflow, for an errata to CSS2, a=testonly
Automatic update from web-platform-testsBaseline of inline-block for different values of overflow, for an errata to CSS2 (#7579)

* Test for errata http://www.w3.org/Style/css2-updates/REC-CSS2-20110607-errata.html#s.10.8.1 (baseline of inline-block)

* Typo in rel=author link.

--

wpt-commits: 62a50ada791ff3dfb6a660fa33ad8a9dc1a8e423
wpt-pr: 7579
2018-05-14 09:55:09 +00:00
David Grogan 7dde2fb938 Bug 1458766 [wpt PR 10812] - [LayoutNG] Add caption tests that NG fails, a=testonly
Automatic update from web-platform-tests[LayoutNG] Add caption tests that NG fails

There are no existing tests (or any imported that I could find) that
verify captions' BFCs behave properly.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I56398bdd1ab6b993eaf8898e09b8aaa4b0ce0100
Bug: 635619
Reviewed-on: https://chromium-review.googlesource.com/1041219
Commit-Queue: David Grogan <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#555822}

--

wpt-commits: 8b7ef0c6aba16661e995d2ab656c3376e4285463
wpt-pr: 10812
2018-05-14 09:54:51 +00:00
Morten Stenshorne aab51464d3 Bug 1458107 [wpt PR 10725] - [LayoutNG] Improve handling of adjoining floats., a=testonly
Automatic update from web-platform-tests[LayoutNG] Improve handling of adjoining floats.

A float always needs to be positioned by its block parent, so passing
them around to children, parents or siblings really shouldn't be
necessary (and it *was* somewhat confusing, since nobody but the direct
float parent is allowed to touch them anyway, apart from placing them
into temporary exclusion spaces). The main reason for passing them
around like that, was for other blocks to determine, based on the list
of floats being empty or not, the need for relayout once the BFC offset
was resolved.

Instead, confine the list of unpositioned floats to the block parent of
those floats, and introduce the concept of adjoining float types (none,
left, right, both). Adjoining floats occur when the BFC offset is
unknown, meaning that their position may be affected by the current
layout algorithm.

Adjoining float types will now be the thing that's both input to and
output from the layout algorithms. Having something other than "none"
means that a block's BFC offset is unknown, but that doesn't
automatically mean that we have to abort and re-layout if the BFC offset
gets resolved. If the "floats BFC offset" is known, for instance, those
adjoining floats may be positioned right away. Still we need to know
about them (positioned or not), to get clearance correct.

We're going to need to treat adjoining floats specially when applying
clearance. Will deal with that in a later CL. For now, we just keep
track of the adjoining float types, so that the clearance machinery can
tell that there are floats there that may not yet be positioned. That
used to be taken care of the list of unpositioned floats, but, as
previously stated, adjoining floats are special, and we need to know
about them, whether they are positioned or not. This is a preparatory CL
for that.

Each time we add an unpositioned float, we need to update the types of
adjoining floats, so that these can be returned from the algorithm if
necessary. Whether they end up being positioned right away or not isn't
relevant. Adjoining is adjoining.

Note that we don't have to #include the header file for unpositioned
floats as much as before now, but I'll clean that up in a follow-up CL,
because it turned out that there were quite a few translation units that
got stuff for free via that header file, instead of explicitly including
what they need.

Had to rewrite how we deal with floats in HandleNewFormattingContext()
and LayoutNewFormattingContext(), since those depended on a list of all
preceding unpositioned floats to place them into a temporary exclusion
space, to figure out whether to let the child's margin be adjoining with
the current margin strut or not. Instead of using a temporary exclusion
space, we now position floats via the regular mechanisms, and initially
assume that the child's margin is going to be adjoining. This means that
we have to abort and roll back if there are preceding unpositioned
floats. This is no different from how we lay out regular blocks, though.
What *is* different is that if it turns out that the child's margin has
to be separated from the strut, we'll have to abort and roll back
once *again* (but only once).

The algorithms now need to keep track of whether they need to abort if
the BFC offset *changes*, rather than if it is *resolved*. We only allow
the offset to resolve and optionally change *once* afterwards, though.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ie527d659213049f180ebedc764e1d7f4926a5876
Reviewed-on: https://chromium-review.googlesource.com/1030191
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#555314}

--

wpt-commits: 39563cf141605683bb8d76abb74eaa0c764d6c65
wpt-pr: 10725
2018-05-08 15:51:26 +01:00
Koji Ishii 149e6e39e8 Bug 1458286 [wpt PR 10737] - Disable kerning in wpt/css/CSS2/floats-clear/floats-143.xht, a=testonly
Automatic update from web-platform-testsDisable kerning in wpt/css/CSS2/floats-clear/floats-143.xht

This patch fixes wpt/css/CSS2/floats-clear/floats-143.xht not
to rely on kerning table.

This test has "PA" and "SS" in two different floats, assuming
either of the below is true:
a. The font does not have a kerning pair between "A" and "S".
b. UA applies kerning across two different floats.

This patch changes this test not to rely on these conditions.

This fix is another test fix needed for CL:1022191.

Change-Id: I78ea57b619fd08a9d671d507ebbb005b556fc183
Reviewed-on: https://chromium-review.googlesource.com/1036825
Reviewed-by: Emil A Eklund <[email protected]>
Commit-Queue: Emil A Eklund <[email protected]>
Cr-Commit-Position: refs/heads/master@{#555066}

--

wpt-commits: fe5aaaf49f48a36dd468213e00734725109d7b90
wpt-pr: 10737
2018-05-08 15:51:20 +01:00
Morten Stenshorne 7db2eedb40 Bug 1457476 [wpt PR 10685] - Add tests for floats next to new formatting contexts., a=testonly
Automatic update from web-platform-testsAdd tests for floats next to new formatting contexts.

Whether an in-flow block-level box that establishes a new formatting
context fits beside a float or not determines whether the float is
adjoining with the new formatting context box or not.

This matters if the box that establishes a new formatting context has a
top margin. If the float turns out to be adjoining, it's affected by
that margin, but not otherwise, i.e. if the new formatting context box
needs to go below the float due to insufficient available width.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I66455845974cbcd5bef36927876512b05a15f435
Reviewed-on: https://chromium-review.googlesource.com/1032732
Reviewed-by: Ian Kilpatrick <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#554510}

--

wpt-commits: ea89515a92d0580fc85e9cff8aa6895c9aa509f5
wpt-pr: 10685
2018-05-02 07:48:57 +01:00
Geoffrey Sneddon 76384b3b53 Bug 1442094 [wpt PR 9727] - Add alternate reference for z-index-020, a=testonly
Automatic update from web-platform-testsAdd alternate reference for z-index-020

--

wpt-commits: 5e8ee10e0752b03c8eecdb38ce0d8e6f4a34b7d1
wpt-pr: 9727
2018-04-30 14:36:21 +00:00
Morten Stenshorne 9f07163195 Bug 1454635 [wpt PR 10504] - Fix wpt/css/CSS2/floats-clear/clear-on-parent-with-margins-no-clearance.html, a=testonly
Automatic update from web-platform-testsFix wpt/css/CSS2/floats-clear/clear-on-parent-with-margins-no-clearance.html

The test was incorrect, which is why it failed in legacy layout. It
passed in LayoutNG because of a bug there.

Add an (invisible) top border on the outer DIV to prevent clearance on
the child. Otherwise the outer DIV and the child with 'clear' would have
adjacent margins, which in turn would enable the child with 'clear' to
pull the float along with itself, which in turn would guarantee
clearance, which is precisely what this test wanted to avoid.

Still passes in LayoutNG.

Change-Id: I6b36d8196b93720453d6e398509705d2cf32f8e4
Reviewed-on: https://chromium-review.googlesource.com/1014975
Reviewed-by: Ian Kilpatrick <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#551443}

--

wpt-commits: 4a0df34066201cfe683293de6e93cf093dde9e6d
wpt-pr: 10504
2018-04-28 19:30:50 +00:00
Geoffrey Sneddon 2ff71763a4 Bug 1446953 [wpt PR 10092] - Remove dependency on external server for background-attachment-004, a=testonly
Automatic update from web-platform-testsRemove dependency on external server for background-attachment-004 (#10092)

wpt-commits: 5bb0c8321fd284fa76d8e3e00e6c97de453ee1b5
wpt-pr: 10092
wpt-commits: 5bb0c8321fd284fa76d8e3e00e6c97de453ee1b5
wpt-pr: 10092
2018-04-15 08:33:49 +01:00
Morten Stenshorne 619314b3dd Bug 1452181 [wpt PR 10019] - [LayoutNG] Don't resolve unresolvable percentage min-height and max-height., a=testonly
Automatic update from web-platform-tests[LayoutNG] Don't resolve unresolvable percentage min-height and max-height.

We cannot use the content size (intrinsic block size) as min-height or
max-height (min-width or max-width, if writing mode is vertical).
Doing so would cause min-height to incorrectly override any specified
height or max-height that is less than the intrinsic block size, and
max-height to override any specified height that's greater than the
intrinsic block size. Do what the spec says [1] instead: max-height
to become 'none', and min-height to become 0.

This fixes the final rendering problem with Acid2 (this was about the
min-height issue). It now renders correctly with LayoutNG!

Since no other tests than Acid2 started to pass with this change, I wrote
a couple.

[1] https://www.w3.org/TR/CSS22/visudet.html#min-max-heights

     XXXXXX
   XX      XX
  X          X
 X   O    O   X
 X            X
X      /\      X
X      \/      X
X              X
 X X        X X
 X  XXXXXXXX  X
  X          X
   XX      XX
     XXXXXX

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ic4f2c3c1dbc2bd66956ed4b270b08058999bc351
Reviewed-on: https://chromium-review.googlesource.com/960085
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Aleks Totic <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#543018}

wpt-commits: 6573773339b47b2e255df1e274788257aa50ad92
wpt-pr: 10019
wpt-commits: 6573773339b47b2e255df1e274788257aa50ad92
wpt-pr: 10019
2018-04-15 08:31:17 +01:00
Morten Stenshorne 6d1422a88d Bug 1445064 [wpt PR 9984] - [LayoutNG] Need parent's clearance offset when positioning child., a=testonly
Automatic update from web-platform-tests[LayoutNG] Need parent's clearance offset when positioning child.

If clear is specified on an element whose first piece of content is
inside a child (so that the element's BFC offset cannot be determined at
the beginning of layout), we need this child to know about the clearance
offset on the parent, or it will not be pushed below adjacent floats as
it should. Just pushing the parent, but leaving the children unaffected
by clearance won't do. We need this in order to be able to lay out in a
single pass (and apply clearance when we detect it, rather than doing
it on the element with 'clear' and relayout the children if something
moved).

Since a constraint space's clearance offset is now "inherited" down the
tree, as long as we're within the same block formatting context, we now
also need to propagate the "is pushed by floats" flag upwards, or we
won't detect class C break points correctly. Without this the unit test
ClassCBreakPointBeforeBlockMarginCollapsing in
NGColumnLayoutAlgorithmTest would regress, because it would incorrectly
detect a class C break point before the break-inside:avoid block.
We must make sure that class C break points are only detected on the
outermost block that got pushed by floats, because it's there that
we'll get the gap between the inner edge of the container and the outer
edge of the child.

Added some tests. One of them fails in legacy (but not in NG). One of
the tests, clear-on-child-with-margins.html, passes both with and
without this code change, but I started to wonder if we'd suddenly
could end up pulling the parent of the box with 'clear' downwards, so
thought I better add it, to make sure we don't regress in this regard.

The test NoClassCBreakPointBeforeBfc in
NGColumnLayoutAlgorithmTest no longer needs its workaround,
because the display:flow-root child of #container now sets its
position correctly (past the float) right away.

Acid2 also looks slightly better now!

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I732b19398bd43b9874f6bb8c57ce435d1c510754
Reviewed-on: https://chromium-review.googlesource.com/957045
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#542769}

wpt-commits: b5b3c1f0c2c224e863e50ad3f78ed5af0d73981e
wpt-pr: 9984
wpt-commits: b5b3c1f0c2c224e863e50ad3f78ed5af0d73981e
wpt-pr: 9984
2018-04-15 08:30:43 +01:00
Morten Stenshorne f248d4fac4 Bug 1444940 [wpt PR 9923] - Don't pixel-snap the top and bottom of lines., a=testonly
Automatic update from web-platform-testsDon't pixel-snap the top and bottom of lines.

That might cause incorrect detection of overflow, since the height of
the block isn't pixel-snapped.

Bug: 818873
Change-Id: I864be9dfedf6f008fe19ce02088ac6488ec274d0
Reviewed-on: https://chromium-review.googlesource.com/954022
Reviewed-by: Emil A Eklund <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#542080}

wpt-commits: 6cca5247026215cbea027426cb22f4e517b43566
wpt-pr: 9923
wpt-commits: 6cca5247026215cbea027426cb22f4e517b43566
wpt-pr: 9923
2018-03-31 22:33:45 +01:00
Kriti Singh 5fd1a68a0a Bug 1444145 [wpt PR 9930] - removed tests g,h,q,r from cascade-import-002.xht, a=testonly
Automatic update from web-platform-testsRemove tests testing <meta http-equiv=link> from cascade-import-002.xht (#9930)

Remove tests g,h,q,r from cascade-import-002.xht because they test the obsoleted and removed <meta http-equiv=link>.

Closes #9910

wpt-commits: df0b73bd250883fa768b6925cf7deed49abc65be
wpt-pr: 9930
wpt-commits: df0b73bd250883fa768b6925cf7deed49abc65be
wpt-pr: 9930
2018-03-31 22:33:21 +01:00
Manuel Rego Casasnovas 364b93b71a Bug 1441943 [wpt PR 9718] - Remove duplicated fonts and put them under /fonts/, a=testonly
Automatic update from web-platform-testsRemove duplicated fonts and put them under /fonts/ (#9718)

This patch removes the duplicated fonts we have in the repository
by copying them under /fonts/ and removing the duplicates.
The paths are updated accordingly to point to the new location.

In addition this patch moves the content of /css/fonts/ under /fonts/,
so there is a single common "fonts" folder on the repository.

wpt-commits: e45d0cf81b1ed64f877279a75c0ffd112fa7741e
wpt-pr: 9718
wpt-commits: e45d0cf81b1ed64f877279a75c0ffd112fa7741e
wpt-pr: 9718
2018-03-31 22:32:12 +01:00
Morten Stenshorne 4392d96dfd Bug 1441151 [wpt PR 9673] - [LayoutNG] Need to lay out legacy objects to figure out their inline size., a=testonly
Automatic update from web-platform-tests[LayoutNG] Need to lay out legacy objects to figure out their inline size.

NG cannot always calculate the correct size of objects that are laid out
by the legacy engine, so just lay them out if we need to know their
size.

The computed CSS width on a table may not end up as its used value, for
instance.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Iaa327ad21055d6c1af96241b5403193c8b4b5ba3
Reviewed-on: https://chromium-review.googlesource.com/937261
Reviewed-by: Ian Kilpatrick <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#539201}

wpt-commits: c3e1a513c1d09c2b4544ad05ea3f03ba8483af27
wpt-pr: 9673
wpt-commits: c3e1a513c1d09c2b4544ad05ea3f03ba8483af27
wpt-pr: 9673
2018-03-31 22:27:16 +01:00
Morten Stenshorne 3938eb93d1 Bug 1439981 [wpt PR 9607] - [LayoutNG] The available space on a line may be affected by text-indent., a=testonly
Automatic update from web-platform-tests[LayoutNG] The available space on a line may be affected by text-indent.

Corrected a DCHECK and added a test that used to crash (but otherwise
pass).

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I139fda3ce912c9138fc055ca7d55d568d5017092
Reviewed-on: https://chromium-review.googlesource.com/928653
Commit-Queue: Koji Ishii <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#538346}

wpt-commits: 48a72dd95fcf0352f30297cd5d8293331aabed7e
wpt-pr: 9607
wpt-commits: 48a72dd95fcf0352f30297cd5d8293331aabed7e
wpt-pr: 9607
2018-03-31 22:25:00 +01:00
Morten Stenshorne 4a901a5383 Bug 1439633 [wpt PR 9589] - [LayoutNG] Use containing block size correctly for abspos., a=testonly
Automatic update from web-platform-tests[LayoutNG] Use containing block size correctly for abspos.

UpdateOutOfFlowBlockLayout() needs to deal with both the actual
containing block size, as specified by CSS (i.e. the padding box size),
and the border-box size of the object that is the containing block of an
absolutely positioned descendant.

Some light cleanup. We always need the border sizes, so just calculate
them once, unconditionally. Also, there seems no need for a special path
for grid/flex, so I removed it.

Some tests start to pass. All but one are still expected to fail in legacy.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I85462d76aa9fa3d0105bf079e59f7c2a7a70f117
Reviewed-on: https://chromium-review.googlesource.com/926004
Reviewed-by: Aleks Totic <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#537918}

wpt-commits: 58462b6f92aab3eea03ad1ea70923855889ed1e2
wpt-pr: 9589
wpt-commits: 58462b6f92aab3eea03ad1ea70923855889ed1e2
wpt-pr: 9589
2018-03-31 22:23:50 +01:00
Morten Stenshorne ab1d1b04b8 Bug 1438515 [wpt PR 9538] - [LayoutNG] Don't add zero-width floats to the exclusion space., a=testonly
Automatic update from web-platform-tests[LayoutNG] Don't add zero-width floats to the exclusion space.

The only thing such floats should affect is the block position of
subsequent floats (float rule §5 [1] and clearance). They should not
affect the inline position or inline size of subsequent floats or new
formatting contexts.

The spec isn't actually clear here, although the browsers agree on the
above. Submitted https://github.com/w3c/csswg-drafts/issues/2312

[1] https://www.w3.org/TR/CSS22/visuren.html#float-position

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Ia9e724c8a58fcb017f86f26bdf90394f09414f4e
Reviewed-on: https://chromium-review.googlesource.com/919065
Reviewed-by: Ian Kilpatrick <[email protected]>
Commit-Queue: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/master@{#537274}

wpt-commits: ae06fa4ce5d170f7f34e979b014315e318344ec4
wpt-pr: 9538
wpt-commits: ae06fa4ce5d170f7f34e979b014315e318344ec4
wpt-pr: 9538
2018-03-31 22:22:26 +01:00
Morten Stenshorne a9df9cb1c6 Bug 1438047 [wpt PR 9503] - [LayoutNG] Allow zero-width layout opportunities., a=testonly
Automatic update from web-platform-tests[LayoutNG] Allow zero-width layout opportunities.

Zero-width floats or in-flow block-level objects that establish a new formatting
context may fit beside preceding floats even if there's zero inline space left.

With this change, a couple of tests start passing, but coverage seems a
bit low, so I added a few new ones.

Had to rebaseline fast/text/word-break.html because a zero-width line
may now fit beside a float that takes up all available inline
space. There was a <br clear=all> in the test that used to insert the
line below such a float. We're now compatible with the others (and our
old selves).

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Iaf394b7039545eea235b2841457f1662e5890ba9
Reviewed-on: https://chromium-review.googlesource.com/916262
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#537000}

wpt-commits: e2b2513a9ab764bcec7ccf616a35835d13020e32
wpt-pr: 9503
wpt-commits: e2b2513a9ab764bcec7ccf616a35835d13020e32
wpt-pr: 9503
2018-03-31 22:22:03 +01:00
Mike Bremford 7c165fdaac Bug 1438386 [wpt PR 9533] - CSS2 tests were only correct if the default font has two weights., a=testonly
Automatic update from web-platform-testsCSS2 tests were only correct if the default font has two weights. (#9533)

font-weight-rule 005 and 007 both made the incorrect
assumption that there were no weights lighter than 400
or greater than 700 in the default font. Added new
references for them which don't depend on that.

wpt-commits: 30c492f9078d50bff86b4459e78d31cc0d7bf47b
wpt-pr: 9533
wpt-commits: 30c492f9078d50bff86b4459e78d31cc0d7bf47b
wpt-pr: 9533
2018-03-31 22:21:34 +01:00
Morten Stenshorne 6c5c2c69a9 Bug 1437045 [wpt PR 9442] - [LayoutNG] Improve min/max calculation wrt. floats., a=testonly
Automatic update from web-platform-tests[LayoutNG] Improve min/max calculation wrt. floats.

The presence of floats complicate min/max intrinsic inline size
calculation. They affect lines and child blocks in the same block
formatting context. Therefore, when calculating min/max sizes of a
child, we need to pass along information about floats adjacent to the
current "virtual" block position.

This change actually makes NG slightly "better" than legacy Blink
layout, Edge and Firefox. This may be an issue for compatibility. It
should be fairly easy to "dumb down" the machinery to be compatible with
the others, though, if this should become an issue. Two tests regressed
because of this. Reported bug 810370. This change also caused
grid-item-margins-not-collapse-expected.html to make room for the floats to
fit beside each other, so I modified it. Also removed bogus "margin"
attributes.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I59730d7333fa7699a42ab93d2c4674c267d834aa
Reviewed-on: https://chromium-review.googlesource.com/908753
Commit-Queue: Morten Stenshorne <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Reviewed-by: Christian Biesinger <[email protected]>
Reviewed-by: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/master@{#536044}

wpt-commits: 84696c45e08c43b0e26888ac0a4823769c067228
wpt-pr: 9442
wpt-commits: 84696c45e08c43b0e26888ac0a4823769c067228
wpt-pr: 9442
2018-03-31 22:19:38 +01:00
Florian Rivoal 1551fc6f2e Bug 1444346 [wpt PR 9468] - Fix broken markup for content-height-005-ref.html, a=testonly
Automatic update from web-platform-testsMerge pull request #9468 from w3c/jdm-patch-3

Fix broken markup for content-height-005-ref.html

wpt-commits: 6eb6ede694a6ba8c070828a601562590d0cdc060
wpt-pr: 9468
wpt-commits: 6eb6ede694a6ba8c070828a601562590d0cdc060
wpt-pr: 9468
2018-03-31 22:19:08 +01:00
Morten Stenshorne 3a79ce1155 Bug 1436558 [wpt PR 9430] - [LayoutNG] Mild cleanup and bugfixing of end margin strut handling., a=testonly
Automatic update from web-platform-tests
Also some more documentation.

Tried to make the various situations a bit clearer, with documentation
and code. And shared code for layout abortion.

The code used to call MaybeUpdateFragmentBfcOffset() quite
unconditionally based on an *end* offset inside the block. I found it
confusing to use an end offset as a BFC start offset. The code was
correct, though, since MaybeUpdateFragmentBfcOffset() wouldn't do
anything if the BFC offset was already known (which would be the case
if had children with actual size, for instance, making for a strange
BFC offset in that case). We'll now only call
MaybeUpdateFragmentBfcOffset() if BFC offset is unknown.
That's the only time end_bfc_block_offset can actually be used as a BFC
start offset.

Fixed one bug, though: A block with explicit height:0 ate the input
margin, rather than letting it collapse through and propagate to
subsequent layout input nodes. The intention of the code was just to get
rid of the last child margin, since height was non-auto. Now we check if
we have a BFC offset before doing so. If we have BFC offset, it means
that no input margins should collapse through. And if we DON'T have a
BFC offset, leave the margins alone for subsequent layout input nodes.
Otherwise we'd just lose them.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Iec8cea316015c6d36ef6bab9acbe826513222b1d
Reviewed-on: https://chromium-review.googlesource.com/907549
Commit-Queue: Morten Stenshorne <[email protected]>
Commit-Queue: Emil A Eklund <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#535273}

<!-- Reviewable:start -->

<!-- Reviewable:end -->

wpt-commits: 19b995f0100dcc3c163153bd7e0a32249d736034
wpt-pr: 9430
reapplied-commits: 370e267e160568862f1fd9ec246ab5bb840f586e, fe4514c84e7ad28e46bad5da93381deb99b177f3, 7806af854343c043a2645a4034fdc7812f65daad, 9ddfd21554293dec5a4bf2e5375ae4f3c9f2ded0, 75f63c4d1ebc949647184fd60972fc7b9fd4affb, 1f3a5b496acd2288cc8cf0c32af86cb35157ea4e, 88b42bd5847abac58a62c4d6b33c1509bfce5f3d, 15c2e4c690700c6c115f8afe5e44ded10d943538, c8d461ef1437641ae7d4ea1d21e1e60cd62910b0, a6088a5f48ee299386a84d2f771902267d7355b1, 0634cd8f08ebe0905a9188fb1398c7b5f889c5dc, c8ee4a012dae506ae06bb5b2ad50942b04c1aaaa, c2c352456a4cf62dcc12f851138b04397675a445, b93a8879555d2fa7e7d4e00a275513a3a6338b35, b86e1331cb36634fd33677043b61fc0c1d8485bc, 44ddf14fd3346658c3223f13652073fafbfa48fa, a1a5840a6bb53e305ba02bcbeb215659342d0edb, 7465cb110ae5ec2e2ca73182caf5293f0efc8fd5, aad5349b3458bc3414e274b33fa86a1123901ff2, eca0907980d2769c449894a6277c60c1a306792f, 38626987c0cfd6e715cfcc6f4f1a1209191a03c5, e4a67f7ddcde6cd99348e9104bd7ed07074da44a, bb3c9990840a0fae2afc840b5952d7874785b112, 042d7adef0bdb9dc80e825c3997ace7519477c42, 99f1ea44fc7915b8b7b33bce4732fa8765fd3ac2, b81999f30c1516a70c153de51a0331d14c8faead
2018-03-09 10:23:13 +00:00
Cosmin Sabou 1f10e98400 Backed out 28 changesets (bug 1436506, bug 1436451, bug 1436996, bug 1436991, bug 1436558, bug 1436398, bug 1443501, bug 1437067, bug 1436436, bug 1436497, bug 1441364, bug 1436405, bug 1441367, bug 1436440, bug 1436416, bug 1436522, bug 1443192) for mass wpt failures after backout for bug 1443558. a=backout
Backed out changeset 09992ffb6a0d (bug 1437067)
Backed out changeset 340be2f71abf (bug 1437067)
Backed out changeset fd8dcd647f0e (bug 1436996)
Backed out changeset 15ff3b2ed202 (bug 1441367)
Backed out changeset bb0cf2a57f10 (bug 1441367)
Backed out changeset 9a8713e25d0e (bug 1436522)
Backed out changeset c5e6aba65927 (bug 1436522)
Backed out changeset 9673a31cbd06 (bug 1436991)
Backed out changeset 260c6ce91561 (bug 1436558)
Backed out changeset aae516e4f973 (bug 1443501)
Backed out changeset ce2b417e9261 (bug 1443501)
Backed out changeset 8daa68e631db (bug 1441364)
Backed out changeset 6015bfa88dd2 (bug 1441364)
Backed out changeset 176a3931afef (bug 1436497)
Backed out changeset ed58e17e8abe (bug 1436497)
Backed out changeset 40628dced2b8 (bug 1436506)
Backed out changeset 0901be04972f (bug 1443192)
Backed out changeset 3f1f453a3cdd (bug 1443192)
Backed out changeset fef37d4246d4 (bug 1436451)
Backed out changeset 99fd7a7dcbca (bug 1436405)
Backed out changeset 0ee344617508 (bug 1436405)
Backed out changeset b84b7682d105 (bug 1436440)
Backed out changeset 1f8ba818cab9 (bug 1436436)
Backed out changeset 010c0213dab3 (bug 1436436)
Backed out changeset 3a2ddfdae7d9 (bug 1436398)
Backed out changeset 68ef54b2b9e0 (bug 1436398)
Backed out changeset 1ce98b09f438 (bug 1436416)
Backed out changeset 7b7d1504387a (bug 1436416)
2018-03-08 08:12:16 +02:00
Morten Stenshorne e7c42c0ca5 Bug 1436558 [wpt PR 9430] - [LayoutNG] Mild cleanup and bugfixing of end margin strut handling., a=testonly
Automatic update from web-platform-tests
Also some more documentation.

Tried to make the various situations a bit clearer, with documentation
and code. And shared code for layout abortion.

The code used to call MaybeUpdateFragmentBfcOffset() quite
unconditionally based on an *end* offset inside the block. I found it
confusing to use an end offset as a BFC start offset. The code was
correct, though, since MaybeUpdateFragmentBfcOffset() wouldn't do
anything if the BFC offset was already known (which would be the case
if had children with actual size, for instance, making for a strange
BFC offset in that case). We'll now only call
MaybeUpdateFragmentBfcOffset() if BFC offset is unknown.
That's the only time end_bfc_block_offset can actually be used as a BFC
start offset.

Fixed one bug, though: A block with explicit height:0 ate the input
margin, rather than letting it collapse through and propagate to
subsequent layout input nodes. The intention of the code was just to get
rid of the last child margin, since height was non-auto. Now we check if
we have a BFC offset before doing so. If we have BFC offset, it means
that no input margins should collapse through. And if we DON'T have a
BFC offset, leave the margins alone for subsequent layout input nodes.
Otherwise we'd just lose them.

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: Iec8cea316015c6d36ef6bab9acbe826513222b1d
Reviewed-on: https://chromium-review.googlesource.com/907549
Commit-Queue: Morten Stenshorne <[email protected]>
Commit-Queue: Emil A Eklund <[email protected]>
Reviewed-by: Emil A Eklund <[email protected]>
Reviewed-by: Ian Kilpatrick <[email protected]>
Cr-Commit-Position: refs/heads/master@{#535273}

<!-- Reviewable:start -->

<!-- Reviewable:end -->

wpt-commits: 19b995f0100dcc3c163153bd7e0a32249d736034
wpt-pr: 9430
reapplied-commits: 370e267e160568862f1fd9ec246ab5bb840f586e, fe4514c84e7ad28e46bad5da93381deb99b177f3, 7806af854343c043a2645a4034fdc7812f65daad, 9ddfd21554293dec5a4bf2e5375ae4f3c9f2ded0, 75f63c4d1ebc949647184fd60972fc7b9fd4affb, 1f3a5b496acd2288cc8cf0c32af86cb35157ea4e, 88b42bd5847abac58a62c4d6b33c1509bfce5f3d, 15c2e4c690700c6c115f8afe5e44ded10d943538, c8d461ef1437641ae7d4ea1d21e1e60cd62910b0, a6088a5f48ee299386a84d2f771902267d7355b1, 0634cd8f08ebe0905a9188fb1398c7b5f889c5dc, c8ee4a012dae506ae06bb5b2ad50942b04c1aaaa, c2c352456a4cf62dcc12f851138b04397675a445, b93a8879555d2fa7e7d4e00a275513a3a6338b35, b86e1331cb36634fd33677043b61fc0c1d8485bc, 44ddf14fd3346658c3223f13652073fafbfa48fa, a1a5840a6bb53e305ba02bcbeb215659342d0edb, 7465cb110ae5ec2e2ca73182caf5293f0efc8fd5, aad5349b3458bc3414e274b33fa86a1123901ff2, eca0907980d2769c449894a6277c60c1a306792f, 38626987c0cfd6e715cfcc6f4f1a1209191a03c5, e4a67f7ddcde6cd99348e9104bd7ed07074da44a, bb3c9990840a0fae2afc840b5952d7874785b112, 042d7adef0bdb9dc80e825c3997ace7519477c42, 99f1ea44fc7915b8b7b33bce4732fa8765fd3ac2, b81999f30c1516a70c153de51a0331d14c8faead
2018-03-07 15:49:53 +00:00