diff options
author | Simon Sapin <simon.sapin@exyr.org> | 2014-07-18 19:33:05 +0100 |
---|---|---|
committer | Simon Sapin <simon.sapin@exyr.org> | 2014-07-18 19:41:35 +0100 |
commit | 1807c29f3ecfbf816a41f7a8d738c5ab28ad1220 (patch) | |
tree | 4441e37d5c47ddc7501a8b7b6d50ce78314e4725 /src/components/layout/construct.rs | |
parent | 94b630e2ed66673d8ae8f044d6bd4067114647ff (diff) | |
download | servo-1807c29f3ecfbf816a41f7a8d738c5ab28ad1220.tar.gz servo-1807c29f3ecfbf816a41f7a8d738c5ab28ad1220.zip |
Convert layout code to use logical directions.
Diffstat (limited to 'src/components/layout/construct.rs')
-rw-r--r-- | src/components/layout/construct.rs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/components/layout/construct.rs b/src/components/layout/construct.rs index ffce4986baa..113e4a28b60 100644 --- a/src/components/layout/construct.rs +++ b/src/components/layout/construct.rs @@ -294,7 +294,7 @@ impl<'a> FlowConstructor<'a> { let mut inline_flow = box InlineFlow::from_fragments((*node).clone(), fragments); let (ascent, descent) = inline_flow.compute_minimum_ascent_and_descent(self.font_context(), &**node.style()); - inline_flow.minimum_height_above_baseline = ascent; + inline_flow.minimum_block_size_above_baseline = ascent; inline_flow.minimum_depth_below_baseline = descent; let mut inline_flow = inline_flow as Box<Flow>; TextRunScanner::new().scan_for_runs(self.font_context(), inline_flow); @@ -1037,10 +1037,10 @@ pub trait FlowConstructionUtils { fn add_new_child(&mut self, new_child: FlowRef); /// Finishes a flow. Once a flow is finished, no more child flows or boxes may be added to it. - /// This will normally run the bubble-widths (minimum and preferred -- i.e. intrinsic -- width) - /// calculation, unless the global `bubble_widths_separately` flag is on. + /// This will normally run the bubble-inline-sizes (minimum and preferred -- i.e. intrinsic -- inline-size) + /// calculation, unless the global `bubble_inline-sizes_separately` flag is on. /// - /// All flows must be finished at some point, or they will not have their intrinsic widths + /// All flows must be finished at some point, or they will not have their intrinsic inline-sizes /// properly computed. (This is not, however, a memory safety problem.) fn finish(&mut self, context: &mut LayoutContext); } @@ -1062,16 +1062,16 @@ impl FlowConstructionUtils for FlowRef { } /// Finishes a flow. Once a flow is finished, no more child flows or fragments may be added to - /// it. This will normally run the bubble-widths (minimum and preferred -- i.e. intrinsic -- - /// width) calculation, unless the global `bubble_widths_separately` flag is on. + /// it. This will normally run the bubble-inline-sizes (minimum and preferred -- i.e. intrinsic -- + /// inline-size) calculation, unless the global `bubble_inline-sizes_separately` flag is on. /// - /// All flows must be finished at some point, or they will not have their intrinsic widths + /// All flows must be finished at some point, or they will not have their intrinsic inline-sizes /// properly computed. (This is not, however, a memory safety problem.) /// /// This must not be public because only the layout constructor can do this. fn finish(&mut self, context: &mut LayoutContext) { - if !context.opts.bubble_widths_separately { - self.get_mut().bubble_widths(context) + if !context.opts.bubble_inline_sizes_separately { + self.get_mut().bubble_inline_sizes(context) } } } |