Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make offset parent queries less buggy. #14839

Merged
merged 22 commits into from Jan 18, 2017
Merged

Conversation

@Permutatrix
Copy link
Contributor

Permutatrix commented Jan 4, 2017

Offset parent queries, which are used in the getters for HTMLElement's offsetParent, offsetTop, offsetLeft, offsetWidth, and offsetHeight, are pretty busted. The most egregious bug is that, as reported in #12939, inline elements are treated as if they're not present in the document. This PR fixes that and all of the other bugs I could trace directly to the offset parent query code, but offsetTop and offsetLeft are still unreliable in certain circumstances for reasons I haven't looked into (#13708). Inline elements with no content are still treated as not present due to #13982, so #13944 isn't fixed with this PR, either.


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes fix #12939 and fix #12595
  • There are tests for these changes

This change is Reviewable

@highfive
Copy link

highfive commented Jan 4, 2017

Heads up! This PR modifies the following files:

  • @emilio: components/layout/query.rs
@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 4, 2017

I didn't update the test expectations because I couldn't figure out how to separate the gunk from the things that were actually affected by my changes. I do know that there are some tests that now fail with this PR because they were passing erroneously.

@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 4, 2017

And yeah, this little patch took me four months to get around to finishing. I'm the best, I'm totally in control of my life, hurr hurr. 😅

@emilio
Copy link
Member

emilio commented Jan 4, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Jan 4, 2017

Trying commit 2c8ac06 with merge 8ff3fa6...

bors-servo added a commit that referenced this pull request Jan 4, 2017
Make offset parent queries less buggy.

<!-- Please describe your changes on the following line: -->
Offset parent queries, which are used in the getters for HTMLElement's `offsetParent`, `offsetTop`, `offsetLeft`, `offsetWidth`, and `offsetHeight`, are pretty busted. The most egregious bug is that, as reported in #12939, inline elements are treated as if they're not present in the document. This PR fixes that and all of the other bugs I could trace directly to the offset parent query code, but `offsetTop` and `offsetLeft` are still terribly unreliable for reasons I haven't looked into (#13708). Inline elements with no content are still treated as not present due to #13982, so #13944 isn't fixed with this PR, either.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12939, #12595

<!-- Either: -->
- [X] There are tests for these changes

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14839)
<!-- Reviewable:end -->
@@ -527,21 +530,58 @@ impl FragmentBorderBoxIterator for UnioningFragmentScrollAreaIterator {
// https://drafts.csswg.org/cssom-view/#extensions-to-the-htmlelement-interface
impl FragmentBorderBoxIterator for ParentOffsetBorderBoxIterator {
fn process(&mut self, fragment: &Fragment, level: i32, border_box: &Rect<Au>) {
match self.node_offset_box {

This comment has been minimized.

@emilio

emilio Jan 4, 2017

Member

nit: Use if self.node_offset_box.is_none().

// TODO: `position: fixed` on inline elements doesn't seem to work
// as of Sep 25, 2016, so I don't know how one will check if an
// inline element has it when it does.
} else if let Some(_) = self.node_offset_box {

This comment has been minimized.

@emilio

emilio Jan 4, 2017

Member

similarly, I think it's better to use self.node_offset_box.is_some() here.

// Found a fragment in the flow tree that matches a child
// of the DOM node being looked for.
// Since we haven't found an exact match, the node must be
// inline. Hopefully.

This comment has been minimized.

@emilio

emilio Jan 4, 2017

Member

Gah, this feels quite a lot like a hack... No better ideas right now though :(

This comment has been minimized.

@Permutatrix

Permutatrix Jan 4, 2017

Author Contributor

@emilio Yes, this entire thing is truly horrible and relies on a lot of unenforced invariants. You could break it from some entirely separate part of layout, and the tests probably wouldn't tell you.

A much better way of handling this particular section has occurred to me, using InlineFragmentNodeFlags. In fact, the current strategy fails when applied to an element containing an {ib} split (never mind that KHTML/WebKit/Blink-based browsers all fail in such a situation as well!). I'm afraid this code hasn't aged quite as well as I thought, but no matter. I'll fix it.

// inline. Hopefully.
match self.node_offset_box {
Some(NodeOffsetBoxInfo { ref mut rectangle, .. }) => {
*rectangle = rectangle.union(border_box);

This comment has been minimized.

@emilio

emilio Jan 4, 2017

Member

under which circumstances can this change the origin of the rectangle?

This comment has been minimized.

@Permutatrix

Permutatrix Jan 4, 2017

Author Contributor

@emilio Text that starts in the middle of a line and has a line break will have boxes further to the left than the first one, so they'll change the origin. I imagine right-to-left text will do so as well.

The offset properties are very confusing. The position (offsetLeft, offsetTop) doesn't actually correspond to the upper-left corner of a rectangle with dimensions offsetWidth x offsetHeight.

Come to think of it, right-to-left text might mess up the result of offsetLeft from this code. Then again, off the top of my head it seems like the "messed-up" results I'm imagining, unintuitive though they are, may actually be the correct ones according the spec. I'll have to look into that.

This comment has been minimized.

@Permutatrix

Permutatrix Jan 5, 2017

Author Contributor

Okay, Firefox (and Konqueror, remarkably enough) measure offsetLeft based on the first line box, which is technically correct, but WebKit/Blink-based browsers just use the first node like this patch currently does. It's the same story for getClientRects(), actually—Gecko correctly returns each whole line's border box, whereas WebKit/Blink and Servo split it up into nodes. This should be a separate issue, I suppose.

@bors-servo
Copy link
Contributor

bors-servo commented Jan 4, 2017

💔 Test failed - linux-rel-css

@jdm
Copy link
Member

jdm commented Jan 4, 2017

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-break-all-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-break-all-002.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-break-all-003.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-break-all-001.htm

  ▶ FAIL [expected PASS] /css-text-3_dev/html/word-break-break-all-007.htm
  └   → /css-text-3_dev/html/word-break-break-all-007.htm 00bb7e6788e64311c3be796d1ccae00e76fc1802
/css-text-3_dev/html/reference/word-break-break-all-ref-007.htm e646b685dec341a3d6988b6e3f52423167e70952
Testing 00bb7e6788e64311c3be796d1ccae00e76fc1802 == e646b685dec341a3d6988b6e3f52423167e70952

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-keep-all-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-keep-all-001.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-break-all-005.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-keep-all-002.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-bo-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-hi-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-001.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-en-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-ja-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-ja-001.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-ja-002.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-ja-004.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-ko-000.htm

  ▶ PASS [expected FAIL] /css-text-3_dev/html/word-break-normal-zh-000.htm

  ▶ FAIL [expected PASS] /css21_dev/html4/abs-pos-non-replaced-vlr-137.htm
  └   → /css21_dev/html4/abs-pos-non-replaced-vlr-137.htm 3eb0ba81d5108e1d42ff482ad8689ea624b567d3
/css21_dev/html4/reference/abs-pos-non-replaced-vrl-004-ref.htm 82d6b4e7e7a391559f9819448a87076b00477338
Testing 3eb0ba81d5108e1d42ff482ad8689ea624b567d3 == 82d6b4e7e7a391559f9819448a87076b00477338

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-002.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 140 but got 148
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-002.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-001.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 84 but got 92
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-001.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] multiple linebreaks \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:33:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:32:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] multiple linebreaks \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] linebreak only \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:21:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:20:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] spaces linebreak spaces \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] linebreak spaces \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:27:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:26:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] linebreak spaces \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] spaces linebreak spaces \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:30:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:29:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] linebreak only \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:36:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:35:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] spaces linebreak \u20a9\uff12\uff14
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-004.htm:
  │ FAIL [expected PASS] spaces linebreak \uff12\uff14\u20a9
  │   → assert_equals: expected 54 but got 62
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:24:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-004.htm:23:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-003.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 56 but got 64
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-003.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-008.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 124 but got 132
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-008.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-006.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 132 but got 164
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-006.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-006.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:18:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:17:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:15:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:14:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:6:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:5:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:9:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:8:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-009.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 86 but got 94
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:12:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-009.htm:11:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:38:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:37:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:31:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:30:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:24:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:23:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:17:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:16:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-017.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:10:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-017.htm:9:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] multiple linebreaks
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:31:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:30:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] multiple linebreaks + spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:38:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:37:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] spaces linebreak spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:24:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:23:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] linebreak only
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:3:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:2:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] linebreak spaces
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:17:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:16:1

  ▶ Unexpected subtest result in /css-text-3_dev/html/seg-break-transformation-016.htm:
  │ FAIL [expected PASS] spaces linebreak
  │   → assert_equals: expected 98 but got 106
  │ 
  │ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:10:1
  │ Test.prototype.step@http://web-platform.test:8000/resources/testharness.js:1227:20
  │ test@http://web-platform.test:8000/resources/testharness.js:428:9
  └ @http://web-platform.test:8000/css-text-3_dev/html/seg-break-transformation-016.htm:9:1

  ▶ TIMEOUT [expected OK] /cssom-1_dev/html/css-style-declaration-modifications.htm
  │ 
  │ VMware, Inc.
  │ Gallium 0.4 on softpipe
  └ 3.3 (Core Profile) Mesa 12.0.1
@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 4, 2017

I just noticed that my code can't detect when the offsetParent should be an inline element. That's even a little broken in Konqueror and its descendants, including Chrome:

<!DOCTYPE html>
<style>
  .parent {
    position: relative;
  }
</style>
<div class="parent">
  <span class="parent">
    <span id="this">ABC</span>
  </span>
</div>
<span class="parent">
  <div>
    <span id="that">ABC</span>
  </div>
</span>
<script>
  // should be: SPAN. Gecko: SPAN. KHTML/WebKit/Blink: SPAN. Patched Servo: DIV.
  console.log(document.getElementById('this').offsetParent.tagName);
  // should be: SPAN. Gecko: SPAN. KHTML/WebKit/Blink: BODY. Patched Servo: BODY.
  console.log(document.getElementById('that').offsetParent.tagName);
</script>

This may be pretty easy to fix, or it may be very hard. I'll look into it.

@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 5, 2017

Okay, I believe that it will be impossible to fix the bug I described in #14839 (comment) until #13982 is fixed. I'll file a separate issue after this is merged.

@highfive highfive removed the S-tests-failed label Jan 5, 2017
@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 5, 2017

Alright, I addressed the issues @emilio brought up and updated the test expectations. (Hopefully these new changes won't change which tests are passing.)

@Manishearth
Copy link
Member

Manishearth commented Jan 5, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Jan 5, 2017

Trying commit 82afb27 with merge d9c0b46...

bors-servo added a commit that referenced this pull request Jan 5, 2017
Make offset parent queries less buggy.

<!-- Please describe your changes on the following line: -->
Offset parent queries, which are used in the getters for HTMLElement's `offsetParent`, `offsetTop`, `offsetLeft`, `offsetWidth`, and `offsetHeight`, are pretty busted. The most egregious bug is that, as reported in #12939, inline elements are treated as if they're not present in the document. This PR fixes that and all of the other bugs I could trace directly to the offset parent query code, but `offsetTop` and `offsetLeft` are still terribly unreliable for reasons I haven't looked into (#13708). Inline elements with no content are still treated as not present due to #13982, so #13944 isn't fixed with this PR, either.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12939, #12595

<!-- Either: -->
- [X] There are tests for these changes

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14839)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jan 5, 2017

💔 Test failed - linux-rel-css

@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 5, 2017

Ran 9977 tests finished in 762.0 seconds.
  • 9974 ran as expected. 146 tests skipped.
  • 2 tests failed unexpectedly
  • 1 tests timed out unexpectedly

Tests with unexpected results:
  ▶ FAIL [expected PASS] /css21_dev/html4/abs-pos-non-replaced-vrl-064.htm
  └   → /css21_dev/html4/abs-pos-non-replaced-vrl-064.htm 3eb0ba81d5108e1d42ff482ad8689ea624b567d3
/css21_dev/html4/reference/abs-pos-non-replaced-vrl-004-ref.htm 82d6b4e7e7a391559f9819448a87076b00477338
Testing 3eb0ba81d5108e1d42ff482ad8689ea624b567d3 == 82d6b4e7e7a391559f9819448a87076b00477338

  ▶ FAIL [expected PASS] /css21_dev/html4/abs-pos-non-replaced-vrl-136.htm
  └   → /css21_dev/html4/abs-pos-non-replaced-vrl-136.htm 3eb0ba81d5108e1d42ff482ad8689ea624b567d3
/css21_dev/html4/reference/abs-pos-non-replaced-vrl-004-ref.htm 82d6b4e7e7a391559f9819448a87076b00477338
Testing 3eb0ba81d5108e1d42ff482ad8689ea624b567d3 == 82d6b4e7e7a391559f9819448a87076b00477338

  ▶ TIMEOUT [expected OK] /cssom-1_dev/html/css-style-declaration-modifications.htm
  │ 
  │ VMware, Inc.
  │ Gallium 0.4 on softpipe
  └ 3.3 (Core Profile) Mesa 12.0.1

Those are all intermittent, right?

@Manishearth
Copy link
Member

Manishearth commented Jan 5, 2017

Third one is, first two are not, as far as we know.

The filtered-intermittents file will filter out intermittents and tell you what's left. It's possible that those two are intermittents since we've seen their type before, but since we're changing layout I'd rather be sure. Retrying

@bors-servo try

@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 5, 2017

@Manishearth Really? It looks like the first two are covered by #13919. Unless I'm missing something about how this works...?

@Manishearth
Copy link
Member

Manishearth commented Jan 5, 2017

Oh, that's due to a bug in the intermittents tracker, sorry 😄

(It doesn't notice when issues are renamed)

@stshine
Copy link
Contributor

stshine commented Jan 5, 2017

Interesting to see that the fails is quite valid since we do not implement the wide character breaks properly (and neither Blink nor Gecko).

@Manishearth
Copy link
Member

Manishearth commented Jan 5, 2017

Yeah, but they're intermittent failures, so they don't always happen and we can't mark them as "expected fail" in the manifest.

@stshine
Copy link
Contributor

stshine commented Jan 5, 2017

Problem with inline elements is that they are Fragment, which is leaf of the flow tree and assumed not be able to have children . But they actully can, and can have both inline-level (span in span) and block-level (inline block) children. To fix this we may eventually need some radical modifications to our layout system, and before which no need to worry too much about using some hacky methods to get around this.

@highfive highfive removed the S-tests-failed label Jan 5, 2017
@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 5, 2017

I removed some baroque functional business I had naïvely put in "for later" because I didn't think hard enough about how #14839 (comment) should ultimately be resolved.

@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

Testing commit 2cd5384 with merge 6013e99...

@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

💔 Test failed - mac-rel-css

@jdm
Copy link
Member

jdm commented Jan 18, 2017

  ▶ FAIL [expected PASS] /css-text-3_dev/html/word-break-normal-zh-000.htm
  └   → /css-text-3_dev/html/word-break-normal-zh-000.htm 863b6d869523cf6e8f08efd5f96884ddb7da36f0
/css-text-3_dev/html/reference/word-break-normal-zh-ref-000.htm 12c02c1c6a388e0deaaaa119c22260a4caf6256c
Testing 863b6d869523cf6e8f08efd5f96884ddb7da36f0 == 12c02c1c6a388e0deaaaa119c22260a4caf6256c

This PR removed the ini file for this test, but it's not passing on the builder.

@jdm
Copy link
Member

jdm commented Jan 18, 2017

Non-reference:
screen shot 2017-01-18 at 8 39 02 am
Reference:
screen shot 2017-01-18 at 8 39 42 am

Only mac failed, and it appears to be a font-based issue, so let's mark this as an expected failure on mac only.

@notriddle
Copy link
Contributor

notriddle commented Jan 18, 2017

@bors-servo r=emilio

@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

💡 This pull request was already approved, no need to approve it again.

  • This pull request previously failed. You should add more commits to fix the bug, or use retry to trigger a build again.
  • There's another pull request that is currently being tested, blocking this pull request: #15091
@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

📌 Commit 2cd5384 has been approved by emilio

@Permutatrix
Copy link
Contributor Author

Permutatrix commented Jan 18, 2017

@jdm Done.

@jdm
Copy link
Member

jdm commented Jan 18, 2017

@bors-servo: r=emilio
Thanks @Permutatrix!

@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

📌 Commit 400a267 has been approved by emilio

@bors-servo
Copy link
Contributor

bors-servo commented Jan 18, 2017

Testing commit 400a267 with merge b08d4a7...

bors-servo added a commit that referenced this pull request Jan 18, 2017
Make offset parent queries less buggy.

<!-- Please describe your changes on the following line: -->
Offset parent queries, which are used in the getters for HTMLElement's `offsetParent`, `offsetTop`, `offsetLeft`, `offsetWidth`, and `offsetHeight`, are pretty busted. The most egregious bug is that, as reported in #12939, inline elements are treated as if they're not present in the document. This PR fixes that and all of the other bugs I could trace directly to the offset parent query code, but `offsetTop` and `offsetLeft` are still unreliable in certain circumstances for reasons I haven't looked into (#13708). Inline elements with no content are still treated as not present due to #13982, so #13944 isn't fixed with this PR, either.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12939 and fix #12595

<!-- Either: -->
- [X] There are tests for these changes

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14839)
<!-- Reviewable:end -->
@bors-servo bors-servo merged commit 400a267 into servo:master Jan 18, 2017
2 of 3 checks passed
2 of 3 checks passed
continuous-integration/appveyor/pr Waiting for AppVeyor build to complete
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
@Permutatrix Permutatrix deleted the Permutatrix:iss-12939 branch Jan 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

9 participants
You can’t perform that action at this time.