Fix `linear_gradients_lengths_a.html` and fix Servo's use of "background-clip" to actually make it work.
See the commit messages for details.
r? @mbrubeck
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9171)
<!-- Reviewable:end -->
Replace Rc<RefCell<Request>> with Rc<Request>
To make using Request easier, I've changed it from an `Rc<RefCell<T>>` to just `Rc<T>`, and updated individual fields to `RefCell<T>` or `Cell<T>` as needed. Git seems to be telling me there's a conflict with request.rs, which I resolved locally, but I'm not sure what to do (if anything) to make it easier to merge.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9172)
<!-- Reviewable:end -->
Correctly handle local sources for CSS3 fonts
Currently, servo panics for me when loading something like this:
```
@font-face {
font-family: "test family";
src: local(test font face);
}
```
That's due to a bug in `FontCacheTask`. `FontCacheTask` tries to get the value for the key
"test font face" from `self.web_families`, but previously initialized a value for the key "test family".
These two commits add an awkward test and fix the bug by not shadowing the variable `family_name`. Since the argument to `local()` should explicitly not be the name of a font family, the previous variable name was wrong and misleading anyways.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9149)
<!-- Reviewable:end -->
script_task.rs: Use self::MixedMessage in handle_msgs
handle_msgs contains many references to variants of MixedMessage.
The function should directly reference the variants instead of
prepending `MixedMessage::`.
Fixes#9169.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9179)
<!-- Reviewable:end -->
handle_msgs contains many references to variants of MixedMessage.
The function should directly reference the variants instead of
prepending `MixedMessage::`.
Fixes#9169.
Remove the fontgroup address cache.
It's not clear to me that it actually helps. Moreover, it's wrong and
results in fonts randomly changing e.g. on GitHub when mousing over
elements.
r? @mbrubeck
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9173)
<!-- Reviewable:end -->
I forgot to do this along with the parallel case. Ideally I'd merge this patch
into that one, but then I'd need to rebase it over the LayoutContext patch,
which would be a pain.
Implement EventSource and update test expectations
Partial #8925.
Most of the processing model for `EventSource` are unimplemented because we currently don't have a fetch implementation.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9029)
<!-- Reviewable:end -->
`linear_gradients_lengths_ref.html` use `background-clip: content-box`.
The tests clearly expect the background painting area to have width of
100px, but since the default value of `background-clip` is `border-box`
and the boxes in question have a 1-pixel border the background painting
areas are actually 102px. This commit fixes the tests so that the width
of the background painting area is actually 100px.
webgl: Make a general way to get data from a JS array buffer view
This fixes an invalid length being reported from
`float32_array_to_slice` (which used the byte length), and also to
generalize getting data from a JS array buffer view, to reduce code
duplication.
The pending type safety issues, like where we could send a `UInt16Array`
where we expect a `Float32` one, should be solved by IDL bindings in
some cases, like `uniform[n]fv` or `vertexAttrib[n]fv`, and with extra
checks in others, like in the pending `texImage2D(..., ArrayBufferView)`.
r? @jdm
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8970)
<!-- Reviewable:end -->
Partial implementation of HTTP-network Fetch step
I've been working on making a partial implementation of HTTP-network Fetch[1] so that I can begin testing the entire Fetch protocol as implemented in Servo. The empty steps are intentionally so, including the incomplete Step 5, which I started without realizing I don't need to do basic testing.
[1] https://fetch.spec.whatwg.org/#http-network-fetch
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9153)
<!-- Reviewable:end -->