servo/components/layout
bors-servo 3ab514302f Auto merge of #14979 - mrobinson:scroll-roots-when-necessary, r=emilio
Only create scrolling overflow regions when necessary

Only create scroll roots for overflow regions when the overflow region
is actually larger than the container size. This prevents creating
scrolling roots for elements that do not have overflow scroll as a
side-effect of the way their height and width is defined. For example,
tables should never respect overflow:scroll since their height and
width should always be large enough to prevent overflow. This also
decreases the size and complexity of the display list in many other
circumstances.

As part of this change, transformed overflow calculation is moved from
display list construction to layout. This should mean that overflow is
handled more accurately earlier.

Fixes #14574.

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

---
<!-- 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 #14574 (github issue number if applicable).

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- 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/14979)
<!-- Reviewable:end -->
2017-01-17 07:18:42 -08:00
..
animation.rs style: Document the animated_properties code. 2016-12-31 12:16:55 +01:00
block.rs Only create scrolling overflow regions when necessary 2017-01-17 09:47:43 -05:00
Cargo.toml Only create scrolling overflow regions when necessary 2017-01-17 09:47:43 -05:00
construct.rs Tidy up rust code with regard to new rule (no = in beginning of line) 2017-01-06 20:57:16 +01:00
context.rs Bug 1325734 - Pass the thread-local context into should_traverse_children. r=emilio 2017-01-09 11:51:37 -08:00
data.rs Bug 1325734 - Remove Servo Layout's dependency on the initial-ness of the style. r=emilio 2017-01-09 11:51:36 -08:00
display_list_builder.rs Auto merge of #14979 - mrobinson:scroll-roots-when-necessary, r=emilio 2017-01-17 07:18:42 -08:00
flex.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
floats.rs Migrated -Z trace-layout to serde_json 2016-11-07 15:54:07 +08:00
flow.rs Only create scrolling overflow regions when necessary 2017-01-17 09:47:43 -05:00
flow_list.rs Added a toolbar for going to previous and next node 2016-12-28 15:31:48 +08:00
flow_ref.rs Migrated -Z trace-layout to serde_json 2016-11-07 15:54:07 +08:00
fragment.rs Preserve the un-truncated version of fragments 2017-01-12 22:02:53 +00:00
generated_content.rs Make Restyle tracking more granular. 2016-12-09 14:46:40 -10:00
incremental.rs Make Restyle tracking more granular. 2016-12-09 14:46:40 -10:00
inline.rs Preserve the un-truncated version of fragments 2017-01-12 22:02:53 +00:00
layout_debug.rs Stop allowing unsafe code around thread_local. 2016-12-30 11:11:25 +01:00
lib.rs Only create scrolling overflow regions when necessary 2017-01-17 09:47:43 -05:00
linked_list.rs Move util::linked_list to layout 2016-06-29 17:23:04 +02:00
list_item.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
model.rs Activate flexbox layout tracing 2016-12-28 15:31:45 +08:00
multicol.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
opaque_node.rs Introduce LayoutJS<Node>::opaque() to replace OpaqueNodeMethods::from_jsmanaged(). 2016-06-20 19:08:02 +02:00
parallel.rs Introduce and use Scoped TLS. 2016-12-21 11:10:39 -08:00
persistent_list.rs Move util::persistent_list to layout 2016-02-20 19:20:38 +01:00
query.rs gfx: Don't mutate the same point multiple times while translating it to other stacking context space. 2017-01-16 14:39:55 +01:00
sequential.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_caption.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_cell.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_colgroup.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_row.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_rowgroup.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
table_wrapper.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
text.rs layout: Remove get_font_arc in favor of clone_font. 2016-12-31 04:53:36 +01:00
traversal.rs Rework the way scroll roots are collected 2017-01-10 13:33:08 +01:00
webrender_helpers.rs Replace gfx_traits::ScrollPolicy by webrender_traits::ScrollPolicy. 2017-01-10 09:45:53 +01:00
wrapper.rs Bug 1325734 - Simplify ElementData and eliminate the concept of consuming styles. r=emilio 2017-01-09 11:51:37 -08:00