layout: Unify the block-size computation for blocks and floats.

The float code was old and did not support most of CSS 2.1. So unifying
the two paths both simplifies code and improves functionality.

Improves the Reddit sidebar.
This commit is contained in:
Patrick Walton 2014-09-24 10:07:39 -07:00
parent c2d6d8084c
commit 9f4c2de211
6 changed files with 86 additions and 140 deletions

View file

@ -685,9 +685,7 @@ pub struct BaseFlow {
/// The children of this flow.
pub children: FlowList,
/* layout computations */
// TODO: min/pref and position are used during disjoint phases of
// layout; maybe combine into a single enum to save space.
/// Intrinsic inline sizes for this flow.
pub intrinsic_inline_sizes: IntrinsicISizes,
/// The upper left corner of the box representing this flow, relative to the box representing