Commit graph

32232 commits

Author SHA1 Message Date
Anthony Ramine
247bcbbbd6 Derive ToCss for all vector longhands that cannot be empty
We don't need to check for emptiness and write `none` for them.
2018-03-05 12:02:31 +01:00
Anthony Ramine
31036d6510 Derive ToCss for MediaList
This uncovered the fancy snowflake `use fmt::Write` in the impl of ToCss
for NonTSPseudoClass.
2018-03-05 12:02:31 +01:00
Anthony Ramine
fb8b6fc0a5 Derive ToCss for CounterBound 2018-03-05 12:02:30 +01:00
Anthony Ramine
0b3a5b42ba Introduce enum CounterBound for the bounds in counter_style::Ranges 2018-03-05 12:02:25 +01:00
bors-servo
e3f69668ae
Auto merge of #20195 - sanxiyn:no-freeglut, r=jdm
Remove FreeGLUT

Current Servo does not require FreeGLUT. Update accordingly.

<!-- 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/20195)
<!-- Reviewable:end -->
2018-03-04 14:25:06 -05:00
bors-servo
fbeb5a81a8
Auto merge of #20194 - emilio:ascii-ext-stuff, r=nox
style: remove unused AsciiExt imports.

eq_ignore_ascii_case is not in AsciiExt since rustc 1.23.

<!-- 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/20194)
<!-- Reviewable:end -->
2018-03-04 13:35:04 -05:00
bors-servo
ec3aa8bd7a
Auto merge of #20182 - paulrouget:ctrl_l, r=jdm
Prompt URL on Cmd/Ctrl-L

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

The `sanitize_url` code is very naive. I'm sure we can do better.
This ServoShell issue describes the problem: https://github.com/paulrouget/servoshell/issues/59

I can fix that now if someone can help me figure out how to tell if a string is a valid url which is just missing a scheme. Or we can do that in a follow up.

---
<!-- 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 #20165

<!-- 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/20182)
<!-- Reviewable:end -->
2018-03-04 12:48:30 -05:00
bors-servo
1783e41f34
Auto merge of #20191 - jfkthame:font-shorthand-resets-variation-settings, r=emilio
style: Make 'font' shorthand reset 'font-variation-settings' property

As required by the spec: https://drafts.csswg.org/css-fonts-4/#font-prop

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

Basically, make font-variation-settings work in the same way as font-feature-settings
already does.

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

- [ ] There are tests for these changes OR
- [X] These changes do not require tests because font-variation-settings isn't supported in servo; it is implemented here for gecko/stylo, and will be tested by mozilla-central mochitests.

<!-- 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/20191)
<!-- Reviewable:end -->
2018-03-04 11:50:56 -05:00
Seo Sanghyeon
5121258bc5 Remove FreeGLUT 2018-03-05 01:18:12 +09:00
bors-servo
d09ea8476e
Auto merge of #20193 - emilio:needless-stuff-is-needless, r=nox
style: Remove more rustc_has_pr45225 stuff.

Also cleans up references to a fixed issue.

<!-- 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/20193)
<!-- Reviewable:end -->
2018-03-04 10:41:54 -05:00
Emilio Cobos Álvarez
39a3d93b4f
style: remove unused AsciiExt imports.
eq_ignore_ascii_case is not in AsciiExt since rustc 1.23.
2018-03-04 15:31:06 +01:00
bors-servo
a716dfd40b
Auto merge of #20192 - servo:derive-all-the-things, r=emilio
Derive ToCss for DeclaredValue

<!-- 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/20192)
<!-- Reviewable:end -->
2018-03-04 09:29:01 -05:00
Emilio Cobos Álvarez
b486c89149
style: Remove more rustc_has_pr45225 stuff.
Also cleans up references to a fixed issue.
2018-03-04 15:23:54 +01:00
Anthony Ramine
886554dba5 Derive ToCss for DeclaredValue 2018-03-04 15:21:11 +01:00
Anthony Ramine
1937f594ac Implement ToCss for UnparsedValue 2018-03-04 15:16:09 +01:00
Jonathan Kew
188687d6a3 style: update stack size of SourcePropertyDeclaration 2018-03-04 13:48:11 +00:00
Jonathan Kew
33ead015b1 style: Make 'font' shorthand reset the 'font-variation-settings' property.
As required by the spec: https://drafts.csswg.org/css-fonts-4/#font-prop

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

Basically, make font-variation-settings work in the same way as font-feature-settings
already does.
2018-03-04 12:26:32 +00:00
Paul Rouget
bb04b95a79 Prompt URL on Cmd/Ctrl-L 2018-03-04 10:55:10 +01:00
bors-servo
86a7010082
Auto merge of #20189 - servo:squared-distance-for-real, r=emilio
Never store a squared root in SquaredDistance

<!-- 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/20189)
<!-- Reviewable:end -->
2018-03-03 20:11:41 -05:00
Anthony Ramine
6ce5e9a869 Never store a squared root in SquaredDistance 2018-03-04 02:10:44 +01:00
bors-servo
b59a8afd0f
Auto merge of #20190 - emilio:context-opacity, r=upsuper
style: Don't guard the context opacity keywords with the svg in opentype pref.

This is effectively the stylo version of the second patch for bug 1365926, and should fix bug 1442867.

<!-- 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/20190)
<!-- Reviewable:end -->
2018-03-03 19:12:18 -05:00
Emilio Cobos Álvarez
9ace0e43ce
style: Cleanup indentation in a couple places. 2018-03-04 01:07:29 +01:00
Emilio Cobos Álvarez
50a299f82c
style: Don't guard the context opacity keywords with the svg in opentype pref.
This is effectively the stylo version of the second patch for bug 1365926, and
should fix bug 1442867.
2018-03-04 01:07:20 +01:00
bors-servo
ce562a2cc6
Auto merge of #20188 - emilio:moar-traits, r=nox
style: Add bindings for ShadowRoot

This adds TShadowRoot to the `dom` module.

Right now it barely adds uses of it, but this is a prerequisite to fix a bunch
of Shadow DOM bugs and separate it from the XBL mess.

<!-- 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/20188)
<!-- Reviewable:end -->
2018-03-03 17:53:08 -05:00
Emilio Cobos Álvarez
f422c7dca4
style: Assert sanity in GeckoNode::as_document. 2018-03-03 23:52:52 +01:00
Emilio Cobos Álvarez
56fc1a6649
style: Account for a few more cases in the node's debug-formatting code. 2018-03-03 23:52:51 +01:00
Emilio Cobos Álvarez
a19219ec79
style: Add also a containing_shadow API. 2018-03-03 23:52:50 +01:00
Emilio Cobos Álvarez
2f0df1b421
style: Add bindings for ShadowRoot.
This adds TShadowRoot to the `dom` module.

Right now it barely adds uses of it, but this is a prerequisite to fix a bunch
of Shadow DOM bugs and separate it from the XBL mess.
2018-03-03 23:52:49 +01:00
bors-servo
df079286c2
Auto merge of #20187 - emilio:font-optical-sizing, r=emilio
style: Add font-optical-sizing property.

Patch by Jonathan Kew <jkew@mozilla.com>.

Bug: 1435692
Reviewed-by: emilio

<!-- 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/20187)
<!-- Reviewable:end -->
2018-03-03 15:10:30 -05:00
Emilio Cobos Álvarez
865a14cf0f
style: Update bindings. 2018-03-03 20:42:41 +01:00
Jonathan Kew
93b7d01324
style: Add font-optical-sizing property.
Bug: 1435692
Reviewed-by: emilio
2018-03-03 20:42:40 +01:00
bors-servo
95f81d0c39
Auto merge of #20183 - servo:computed-as-clone, r=emilio
Unconditionally derive ToComputedValue as Clone for non-generic types

We assume that types such as `<Self as ToComputedValue>::ToComputedValue == Self`
just construct a new value that is just a clone of the original one without any
additional code.

<!-- 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/20183)
<!-- Reviewable:end -->
2018-03-03 14:15:17 -05:00
bors-servo
5bfd74e42d
Auto merge of #20180 - emilio:moar-refcount-hackery, r=jdm
style: Copy less urls for stylo.

Bug: 1442246
Reviewed-by: jdm
MozReview-Commit-ID: NmHue1mGDq

<!-- 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/20180)
<!-- Reviewable:end -->
2018-03-03 13:25:15 -05:00
Anthony Ramine
b517bcd42b Unconditionally derive ToComputedValue as Clone for non-generics
We assume that types such as `<Self as ToComputedValue>::ToComputedValue == Self`
just construct a new value that is just a clone of the original one without any
additional code.
2018-03-03 18:41:50 +01:00
bors-servo
2425939f9f
Auto merge of #20186 - emilio:fixup-fill, r=nox
style: Fix text-emphasis-style conversion.

Was accidentally broken in #20178 and is causing orange.

<!-- 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/20186)
<!-- Reviewable:end -->
2018-03-03 12:23:52 -05:00
Emilio Cobos Álvarez
569dde72d0
style: Fix text-emphasis-style conversion.
Was accidentally broken in #20178 and is causing orange.
2018-03-03 18:22:27 +01:00
Emilio Cobos Álvarez
98e4c08c64
style: Update bindings. 2018-03-03 18:18:22 +01:00
Emilio Cobos Álvarez
da94feb11a
style: Copy less URLs on stylo.
Bug: 1442246
Reviewed-by: jdm
MozReview-Commit-ID: NmHue1mGDq
2018-03-03 18:18:22 +01:00
bors-servo
0c9be9f776
Auto merge of #20178 - servo:derive-all-the-things, r=emilio
Derive ToCss for some more stuff

<!-- 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/20178)
<!-- Reviewable:end -->
2018-03-03 10:17:42 -05:00
Anthony Ramine
15dcd8a8ea Derive ToCss for ViewportLength 2018-03-03 16:15:24 +01:00
Anthony Ramine
6e19fe6a8f Derive ToCss for KeyframeSelector 2018-03-03 16:15:23 +01:00
Anthony Ramine
be820092ad Derive ToCss for VectorValues 2018-03-03 16:15:23 +01:00
Anthony Ramine
51a54e1a60 Derive ToCss for PairValues 2018-03-03 16:15:22 +01:00
Anthony Ramine
71c0c3a5d3 Derive ToCss for DocumentCondition 2018-03-03 16:15:21 +01:00
Anthony Ramine
7e1c23cb74 Replace a boolean with a new FillMode enum for text-emphasis-style
This allows us to derive some ToCss and Parse code.
2018-03-03 16:15:20 +01:00
Anthony Ramine
13c40f4fb8 Derive ToCss for TransitionProperty 2018-03-03 16:15:20 +01:00
Anthony Ramine
83a2312867 Derive ToCss for Symbol 2018-03-03 16:15:19 +01:00
Anthony Ramine
ad7adee882 Use CustomIdent in Symbol::Ident
The former code was not following the spec.
2018-03-03 16:15:13 +01:00
Paul Rouget
76552b3e1e update tinyfiledialogs 2018-03-03 08:35:44 +01:00
Anthony Ramine
a71b5d5e16 Derive ToCss for Symbols 2018-03-03 01:01:59 +01:00