servo/components
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
..
allocator FreeType: don’t use usable_size() as deallocation size 2017-10-30 18:22:30 +01:00
atoms Bump string_cache, html5ever and xml5ever 2017-12-07 20:37:38 +01:00
bluetooth Bump bitflags to 1.0 in every servo crate 2017-10-30 23:36:06 +01:00
bluetooth_traits Update WR (details below): 2017-10-16 16:33:24 +10:00
canvas remove unsued IpcReceiver 2017-12-20 22:19:25 +08:00
canvas_traits Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
compositing using local variable instead of a function call. 2017-12-21 21:20:12 +08:00
config Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
constellation Revert "Send IPC receiver for canvas as part of CreateCanvasPaintThread message" 2017-12-18 10:51:00 -05:00
debugger
deny_public_fields
devtools Update cookie to 0.10 2017-11-24 10:49:14 +01:00
devtools_traits Update cookie to 0.10 2017-11-24 10:49:14 +01:00
dom_struct Upgrade to rustc 1.24.0-nightly (5a2465e2b 2017-12-06) 2017-12-07 13:50:09 +01:00
domobject_derive
fallible Update smallvec to 0.6 2017-12-05 12:03:20 +01:00
geometry Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
gfx Auto merge of #19651 - pyfisch:background-placement, r=emilio 2018-01-02 08:47:24 -06:00
gfx_traits pretty print tree 2017-12-23 14:40:06 +08:00
hashglobe Dump the requested aligment if out of memory while allocating a table. 2018-01-02 11:31:03 +08:00
jstraceable_derive
layout Auto merge of #19651 - pyfisch:background-placement, r=emilio 2018-01-02 08:47:24 -06:00
layout_thread Revert #19666 since we do create NAC elements and expect them to be inline. 2017-12-31 17:00:26 +01:00
layout_traits Update WR (details below): 2017-10-16 16:33:24 +10:00
malloc_size_of Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
malloc_size_of_derive
metrics Print url of recorded PWM 2017-12-07 20:58:31 +01:00
msg Bump bitflags to 1.0 in every servo crate 2017-10-30 23:36:06 +01:00
net net: Use ? on Option more often. 2017-12-09 20:46:20 +01:00
net_traits Update lazy_static to 1.0 2017-12-04 22:51:13 +01:00
nonzero Replace NonZeroU32 and NonZeroUsize with a generic NonZero 2017-10-16 20:19:19 +02:00
profile added time to interactive metrics, refactored metrics to use traits 2017-10-24 21:02:56 +01:00
profile_traits added time to interactive metrics, refactored metrics to use traits 2017-10-24 21:02:56 +01:00
rand Update lazy_static to 1.0 2017-12-04 22:51:13 +01:00
range Replace all uses of the heapsize crate with malloc_size_of. 2017-10-18 22:20:37 +11:00
remutex Update lazy_static to 1.0 2017-12-04 22:51:13 +01:00
script Paint worklets: Implement timeout for worklet painter threads 2017-12-22 10:47:23 +01:00
script_layout_interface Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
script_plugins Make the unrooted_must_root conditional on a default Cargo feature. 2017-11-02 15:08:04 +01:00
script_traits Paint worklets: Implement timeout for worklet painter threads 2017-12-22 10:47:23 +01:00
selectors style: Don't support a list of selectors in ::slotted yet. 2017-12-20 15:55:09 +01:00
servo Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
servo_arc servo_arc: Add some #[inline] and repr(C) annotations. 2017-12-01 14:34:38 +01:00
size_of_test
style style: Move display outside of mako 2018-01-01 23:51:08 +08:00
style_derive style_derive: Support parse-time aliases. 2017-12-31 09:53:17 +01:00
style_traits Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
url Replace all uses of the heapsize crate with malloc_size_of. 2017-10-18 22:20:37 +11:00
webdriver_server Update to webdriver 0.33 2017-12-08 08:27:45 -08:00
webvr Update euclid, azure, skia, offscreen_gl_context, plane-split, webrender 2017-12-08 14:32:28 +01:00
webvr_traits Update WR (details below): 2017-10-16 16:33:24 +10:00