Commit graph

27147 commits

Author SHA1 Message Date
bors-servo
ece35f9caa Auto merge of #17581 - mbrubeck:incremental, r=pcwalton
Fix incremental layout bugs for absolute and cleared elements

Fixes #17307.  <del>There were two underlying bugs:</del>

* <del>Nodes were not marked dirty when their style attribute changed.</del>

* BaseFlow flags set during flow construction could get out of sync with the element's style if repair_style was called.

---

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #17307
- [x] There are tests for these changes

<!-- 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/17581)
<!-- Reviewable:end -->
2017-06-30 22:15:26 -07:00
Matt Brubeck
2aef2af9b8 Update flags for absolutely positioned elements on style changes
Fixes #17307.
2017-06-30 22:14:28 -07:00
bors-servo
90cf19151a Auto merge of #17434 - canaltinova:moz-linear-gradient, r=Manishearth,nox
stylo: Implement -moz-prefixed gradients

---
<!-- 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 [Bug 1366544](https://bugzilla.mozilla.org/show_bug.cgi?id=1366544)

<!-- 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/17434)
<!-- Reviewable:end -->
2017-06-30 18:00:50 -07:00
Nazım Can Altınova
b33545ca3b Move Position::parse_legacy logic to LegacyPosition type 2017-06-30 17:54:04 -07:00
Nazım Can Altınova
d589645ee9 stylo: Implement -moz-prefixed radial gradients 2017-06-30 17:54:01 -07:00
Nazım Can Altınova
3e42684d3c stylo: Implement -moz-prefixed linear gradients 2017-06-30 17:53:01 -07:00
Matt Brubeck
f01e1da01e Reconstruct flows if the 'clear' property changes.
This is necessary because the CLEARS_LEFT and CLEARS_RIGHT flags are set
during flow construction.
2017-06-30 17:11:30 -07:00
bors-servo
a9fea0653a Auto merge of #17326 - asajeffrey:script-paint-worklets-rendering-context, r=jdm
Implement paint worklets rendering context

<!-- Please describe your changes on the following line: -->

Implement the rendering context for paint worklets. They really paint things now!

---
<!-- 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 do not require tests because the existing reftest now passes

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/17326)
<!-- Reviewable:end -->
2017-06-30 15:40:26 -07:00
Alan Jeffrey
328fb25a65 Implemented paint worklet rendering context. 2017-06-30 16:41:08 -05:00
bors-servo
d16ef3cd33 Auto merge of #17561 - servo:rustup, r=nox
Upgrade to rustc 1.20.0-nightly (69c65d296 2017-06-28)

Fixes #17575.

<!-- 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/17561)
<!-- Reviewable:end -->
2017-06-30 14:34:56 -07:00
Simon Sapin
7fbb658224 Upgrade to rustc 1.20.0-nightly (3bfc18a96 2017-06-29) 2017-06-30 23:22:38 +02:00
bors-servo
a24600d626 Auto merge of #17577 - mbrubeck:inactive, r=emilio
Bug 1348489 - stylo: Implement :-moz-window-inactive.

https://bugzilla.mozilla.org/show_bug.cgi?id=1348489

<!-- 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/17577)
<!-- Reviewable:end -->
2017-06-30 10:13:01 -07:00
Matt Brubeck
17f4d0c5d9 Bug 1348489 - stylo: Implement :-moz-window-inactive. 2017-06-30 09:31:01 -07:00
bors-servo
ff19e69d23 Auto merge of #17570 - bzbarsky:visited-pseudos, r=jryans
Implement :visited support for lazy pseudo-elements

<!-- Please describe your changes on the following line: -->

---
<!-- 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 https://bugzilla.mozilla.org/show_bug.cgi?id=1364242

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/17570)
<!-- Reviewable:end -->
2017-06-30 09:11:41 -07:00
bors-servo
a04725fa1c Auto merge of #17569 - upsuper:fullscreen, r=emilio
Support :-moz-full-screen pseudo-class

This fixes [bug 1374901](https://bugzilla.mozilla.org/show_bug.cgi?id=1374901).

<!-- 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/17569)
<!-- Reviewable:end -->
2017-06-30 08:08:00 -07:00
Simon Sapin
6b523302e1 Fetch "alt" rust std build when we do so for rustc 2017-06-30 15:44:03 +02:00
bors-servo
d47de6ccfc Auto merge of #17574 - heycam:experimental, r=Manishearth
style: Make "internal" and "experimental" interact in the same way as Gecko.

From https://bugzilla.mozilla.org/show_bug.cgi?id=1375374.

<!-- 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/17574)
<!-- Reviewable:end -->
2017-06-30 06:09:29 -07:00
bors-servo
7b82d3b97b Auto merge of #17573 - atouchet:vs-readme, r=jdm
Update Visual Studio instructions in Readme

<!-- Please describe your changes on the following line: -->

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

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/17573)
<!-- Reviewable:end -->
2017-06-30 05:14:44 -07:00
bors-servo
008f90517c Auto merge of #17566 - canaltinova:font-var-alt, r=emilio
stylo: Fix font-variant-alternates property

`font-variant-alternates` was just parsing values as keywords. But many of the alternates are actually functions instead of keywords. This fixes that.

r=emilio on bugzilla side.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix [Bug 1356124](https://bugzilla.mozilla.org/show_bug.cgi?id=1356124)

<!-- 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/17566)
<!-- Reviewable:end -->
2017-06-30 04:13:15 -07:00
bors-servo
683a53b080 Auto merge of #17563 - julian-seward1:master, r=bholley
Bug 1368302 - stylo: possible stack overflow when processing very dee…

…p DOM.  r=bholley.

Whilst working with variants of the bloom-basic test for Stylo perf
profiling, I noticed that it is easy to cause Firefox to segfault on DOMs
with a depth of more than about 1500 elements.  This fix limits the use of
tail recursion to 150 elements.  This isn't externally observable to content
-- we're still completely correct, just not using tail recursion any more.

<!-- Please describe your changes on the following line: -->

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

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/17563)
<!-- Reviewable:end -->
2017-06-30 03:01:08 -07:00
bors-servo
39da6d4674 Auto merge of #17239 - asajeffrey:script-paint-worklets-invoke-worklet-scripts, r=jdm
Implemented paint worklets invoking worklet scripts.

<!-- Please describe your changes on the following line: -->

Implemented the "invoke a paint callback" functionality of paint worklets (https://drafts.css-houdini.org/css-paint-api/#invoke-a-paint-callback).

This PR does not implement the 2D rendering context, and just generates a placeholder image.

---
<!-- 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 do not require tests because we can't write reftests until we have 2D rendering contexts implemented.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/17239)
<!-- Reviewable:end -->
2017-06-30 01:16:09 -07:00
Boris Zbarsky
824139e615 Make sure to compute visited style if our parent has visited style.
Part 4 of the fix for Gecko bug 1364242: https://bugzilla.mozilla.org/show_bug.cgi?id=1364242
2017-06-29 22:26:14 -07:00
Boris Zbarsky
759038e687 Add a helper method for getting our style parent and its ComputedValues while matching.
Part 3 of the fix for Gecko bug 1364242: https://bugzilla.mozilla.org/show_bug.cgi?id=1364242
2017-06-29 22:22:38 -07:00
Cameron McCormack
477a69d725 style: Make "internal" and "experimental" interact in the same way as Gecko. 2017-06-29 22:21:40 -07:00
Alex Touchet
4a6a204d0e Update Visual Studio instructions in Readme 2017-06-29 22:09:32 -07:00
bors-servo
8029f1a1bb Auto merge of #17571 - emilio:jwatt, r=emilio
style: Update Stylo bindings for new LookAndFeel_ColorID variants

Rebase of https://github.com/servo/servo/pull/17449

<!-- 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/17571)
<!-- Reviewable:end -->
2017-06-29 17:39:23 -07:00
Emilio Cobos Álvarez
65bbd6c23a
style: Update Stylo bindings for new LookAndFeel_ColorID variants 2017-06-29 17:38:14 -07:00
Boris Zbarsky
52d1b59515 Implement :visited handling for lazy pseudo-elements in stylo.
Part 2 of the fix for Gecko bug 1364242: https://bugzilla.mozilla.org/show_bug.cgi?id=1364242
2017-06-29 16:22:13 -07:00
Boris Zbarsky
351c7f7859 Change lazily_compute_pseudo_element_style to take an &Arc for the parent style.
This makes it easier to do later changes that want to pass an Arc here.

Part 1 of the fix for Gecko bug 1364242: https://bugzilla.mozilla.org/show_bug.cgi?id=1364242
2017-06-29 16:20:47 -07:00
bors-servo
527273cd1c Auto merge of #17567 - moz-servo-sync:gecko-backout, r=moz-servo-sync
Backed out changeset 90036d4d378e (bug 17564) because gecko-side patch caused bustage on Windows. r=backout on a CLOSED TREE

Backed out changeset 90036d4d378e (bug 17564) because gecko-side patch caused bustage on Windows. r=backout on a CLOSED TREE

Backs out https://github.com/servo/servo/pull/17564

<!-- 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/17567)
<!-- Reviewable:end -->
2017-06-29 16:16:04 -07:00
Xidorn Quan
3ea38020f7 Support :-moz-full-screen pseudo-class 2017-06-29 15:44:30 -07:00
Alan Jeffrey
3db4761767 Implemented paint worklets invoking worklet scripts. 2017-06-29 17:32:21 -05:00
Julian Seward
4aa9829889 Bug 1368302 - stylo: possible stack overflow when processing very deep DOM. r=bholley.
Whilst working with variants of the bloom-basic test for Stylo perf
profiling, I noticed that it is easy to cause Firefox to segfault on DOMs
with a depth of more than about 1500 elements.  This fix limits the use of
tail recursion to 150 elements.  This isn't externally observable to content
-- we're still completely correct, just not using tail recursion any more.
2017-06-29 22:56:38 +02:00
Nazım Can Altınova
5d0f7f10e0 stylo: Fix font-variant-alternates property 2017-06-29 13:33:38 -07:00
Gecko Backout
fb4e454df4 Backed out changeset 90036d4d378e (bug 17564) because gecko-side patch caused bustage on Windows. r=backout on a CLOSED TREE
Backs out https://github.com/servo/servo/pull/17564
2017-06-29 20:28:35 +00:00
bors-servo
8f37de05b2 Auto merge of #17564 - mbrubeck:inactive, r=emilio
Bug 1348489 - stylo: Implement :-moz-window-inactive.

https://bugzilla.mozilla.org/show_bug.cgi?id=1348489

<!-- 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/17564)
<!-- Reviewable:end -->
2017-06-29 11:25:40 -07:00
Matt Brubeck
9cef18f6b5 Bug 1348489 - stylo: Implement :-moz-window-inactive. 2017-06-29 11:21:16 -07:00
bors-servo
9a13cf6bda Auto merge of #17560 - servo:derive-all-the-things, r=<try>
Introduce ToAnimatedValue 🎥

<!-- 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/17560)
<!-- Reviewable:end -->
2017-06-29 06:49:39 -07:00
Anthony Ramine
9ab0b9b4ac Introduce ToAnimatedValue 🎥 2017-06-29 14:03:15 +02:00
bors-servo
2ff781d068 Auto merge of #17558 - ferjm:custompropmap.eq, r=emilio
Derive Eq and PartialEq for CustomPropertiesMap

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/17558)
<!-- Reviewable:end -->
2017-06-28 22:01:17 -07:00
Fernando Jiménez Moreno
0335c09810 Derive Eq and PartialEq for CustomPropertiesMap 2017-06-28 19:50:29 -07:00
bors-servo
6d7fdb484b Auto merge of #17554 - mbrubeck:oibit, r=ManishEarth
Stop using the unstable optin_builtin_traits feature

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix part of #5286.
- [x] These changes do not require tests because they are refactoring only.

<!-- 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/17554)
<!-- Reviewable:end -->
2017-06-28 19:11:08 -07:00
bors-servo
b3e2b26a23 Auto merge of #17551 - ferjm:bug1375555.stylevariables, r=emilio
stylo: implement indexed and count getters for custom properties

From https://bugzilla.mozilla.org/show_bug.cgi?id=1375555

<!-- 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/17551)
<!-- Reviewable:end -->
2017-06-28 18:04:58 -07:00
bors-servo
c3a202b17d Auto merge of #17550 - emilio:xbl-is-a-pain-in-the, r=heycam
Fix dynamic style changes in XBL.

From bug 1375969

<!-- 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/17550)
<!-- Reviewable:end -->
2017-06-28 17:02:17 -07:00
bors-servo
62f99de19f Auto merge of #17553 - BorisChiou:stylo/animation/interpolatematrix_none, r=birtles
stylo: Bug 1375812 - Build an identity matrix for InterpolateMatrix.

We have to build an identity matrix while add_weighted() between InterpolateMatrix and none transform in some cases, e.g. trigger a transition from a mid-point of another transition to none.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix [Bug 1375812](https://bugzilla.mozilla.org/show_bug.cgi?id=1375812).
- [X] These changes do not require tests because we have tests in Gecko already.

<!-- 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/17553)
<!-- Reviewable:end -->
2017-06-28 16:02:33 -07:00
Emilio Cobos Álvarez
9558d2d918
stylo: Fix MightHave{State,Attribute}Dependency for XBL.
Bug: 1375969
Reviewed-By: heycam
MozReview-Commit-ID: 8I29pMHq4uf
2017-06-28 16:02:11 -07:00
Emilio Cobos Álvarez
f8346e598e
style: Look at XBL stylists to collect dependencies too.
Bug: 1375969
Reviewed-By: heycam
MozReview-Commit-ID: 72wZj6o667V
2017-06-28 16:02:10 -07:00
Emilio Cobos Álvarez
215d14b37e
style: Factor out computation for a given InvalidationMap.
Bug: 1375969
Reviewed-By: heycam
MozReview-Commit-ID: 9qSr1LcsKK5
2017-06-28 16:02:09 -07:00
Emilio Cobos Álvarez
02b61ed1a1
style: Refactor XBL rule matching to add another API to iterate the Stylists.
This will allow us to query the relevant stylists for invalidation.

Bug: 1375969
Reviewed-By: TYLin
MozReview-Commit-ID: EIIzbr2pEqN
2017-06-28 16:02:08 -07:00
Matt Brubeck
f511a77ec5 Stop using the unstable optin_builtin_traits feature 2017-06-28 15:00:21 -07:00