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.
This commit is contained in:
Martin Robinson 2017-01-10 09:49:06 +01:00
parent 14aa666a5a
commit 44b24de60f
10 changed files with 139 additions and 63 deletions

View file

@ -50,6 +50,7 @@ extern crate serde_derive;
extern crate serde_json;
#[macro_use] extern crate servo_atoms;
extern crate servo_config;
extern crate servo_geometry;
extern crate servo_url;
extern crate smallvec;
extern crate style;