servo/components/layout
bors-servo 6ee8e6a168 Auto merge of #19554 - pyfisch:tiled-gradients1, r=mbrubeck
layout: support tiled gradients

Use background-size, background-position properties to render
CSS gradients.

Some cleanup in display_list_builder.rs related to gradient
calculations.

Adds two wpt tests for tiled gradients.

Note: For now even gradients with background-repeat: no-repeat
are repeated. Sometimes the gradient is not repeated everywhere.

Resolves partially #19482. (See the mentioned website for example gradients with these features)
See also: #16657 and #10412

Some glitches can be seen in the attached file. I am unsure what the exact intended semantics of [`push_gradient`](https://doc.servo.org/webrender_api/struct.DisplayListBuilder.html#method.push_gradient) are and want to ask the webrender team before building in "workarounds" for the missing gradients.
![half-rhombes](https://user-images.githubusercontent.com/2781017/33958051-b16f964a-e043-11e7-8218-b28388e2cf8d.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/19554)
<!-- Reviewable:end -->
2017-12-14 13:20:34 -06:00
..
animation.rs stylo: Remove a lot of the restyle damage related complexity. 2017-08-20 13:59:46 +02:00
block.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
Cargo.toml Make layout depend on style/servo feature 2017-12-14 10:34:43 -06:00
construct.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
context.rs Replace all uses of the heapsize crate with malloc_size_of. 2017-10-18 22:20:37 +11:00
data.rs Bump bitflags to 1.0 in every servo crate 2017-10-30 23:36:06 +01:00
display_list_builder.rs Auto merge of #19554 - pyfisch:tiled-gradients1, r=mbrubeck 2017-12-14 13:20:34 -06:00
flex.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
floats.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
flow.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
flow_list.rs Remove usage of unstable feature conservative_impl_trait in layout 2017-10-13 11:11:06 +02:00
flow_ref.rs order derivable traits lists 2017-08-23 21:38:44 +02:00
fragment.rs style: Use the ? operator for Option 2017-12-09 08:29:53 -08:00
generated_content.rs style: Use more Box<[]> and Box<str> for quotes. 2017-12-14 04:05:25 +01:00
incremental.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
inline.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
layout_debug.rs Remove usage of unstable box syntax, except in the script crate 2017-10-12 12:10:56 +02:00
lib.rs Replace all uses of the heapsize crate with malloc_size_of. 2017-10-18 22:20:37 +11:00
linked_list.rs Move util::linked_list to layout 2016-06-29 17:23:04 +02:00
list_item.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
model.rs Update WR to use the new sticky positioning API 2017-10-30 10:15:30 +01:00
multicol.rs Introduce an unsafe HasBaseFlow trait for base()/base_mut() casts. 2017-10-14 00:03:57 +02:00
opaque_node.rs Introduce LayoutJS<Node>::opaque() to replace OpaqueNodeMethods::from_jsmanaged(). 2016-06-20 19:08:02 +02:00
parallel.rs Use raw pointers instead of transmute for UnsafeFlow 2017-10-04 20:00:31 -07:00
persistent_list.rs Use try syntax for Option where appropriate 2017-10-20 08:25:35 -07:00
query.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
sequential.rs Bump bitflags to 1.0 in every servo crate 2017-10-30 23:36:06 +01:00
table.rs Remove border_collapse field in InternalTable 2017-12-08 04:51:58 -08:00
table_caption.rs Introduce an unsafe HasBaseFlow trait for base()/base_mut() casts. 2017-10-14 00:03:57 +02:00
table_cell.rs Remove border_collapse field in InternalTable 2017-12-08 04:51:58 -08:00
table_colgroup.rs Wait as late as possible to assign ClipIds 2017-10-24 16:28:07 +02:00
table_row.rs Remove border_collapse field in InternalTable 2017-12-08 04:51:58 -08:00
table_rowgroup.rs Remove border_collapse field in InternalTable 2017-12-08 04:51:58 -08:00
table_wrapper.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
text.rs style: Make all keywords CamelCase for consistency. 2017-12-06 02:35:10 +01:00
traversal.rs style: Remove unused argument in element_needs_traversal. 2017-11-17 16:56:26 +01:00
webrender_helpers.rs layout: support tiled gradients 2017-12-14 09:25:30 +01:00
wrapper.rs layout: Fixup indentation of ThreadSafeLayoutNodeHelpers::flags. 2017-11-10 13:13:19 +01:00