servo/components/gfx
bors-servo 691bff86b6 Auto merge of #19651 - pyfisch:background-placement, r=emilio
Unify background placement code

Merges the implementations for background-image placement
from gradients and images. Add missing parts and fix bugs.

Now supported are the CSS properties:

* background-attachment (except for local value, see #19650)
* background-clip
* background-origin
* background-position-x/y
* background-repeat
* background-size

It should be noted that backgrounds are not clipped to
rounded border corners.
(This was done before but worked only in simple cases)
See: #19649

This solves the following issues:
closes #19626
closes #16657
closes #19482 (examples from http://lea.verou.me/css3patterns/ are rendered perfectly but the round border is completely ignored now)
closes #19577

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

I enabled a few tests with the first commit but I have written about a dozen manual tests I will try to turn into ref tests either before or after this patch lands.

@bors-servo try

The relationship between the different inputs is visualized in this flowchart:
![flowchart-background](https://user-images.githubusercontent.com/2781017/34394430-5a06c72c-eb59-11e7-9d51-3d23e2215f07.png)

<!-- 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/19651)
<!-- Reviewable:end -->
2018-01-02 08:47:24 -06:00
..
display_list Auto merge of #19651 - pyfisch:background-placement, r=emilio 2018-01-02 08:47:24 -06:00
platform cleanup no need cfg target_os 2017-12-25 17:13:48 +08:00
text gfx: Use ? on Option more often. 2017-12-09 20:27:16 +01:00
Cargo.toml Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
font.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
font_cache_thread.rs style: Move font-family outside of mako 2017-11-26 00:36:00 +08:00
font_context.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
font_template.rs order derivable traits lists 2017-08-23 21:38:44 +02:00
lib.rs Stop relying on linking details of std’s default allocator 2017-10-19 09:52:50 +02:00