mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Various fixes
Fix the behavior of block-direction margins of replaced element both as block level or inline level, and no longer query fragment info when building display list for canvas.
This commit is contained in:
parent
b1b17f1869
commit
b0de105bb0
3 changed files with 54 additions and 52 deletions
|
@ -1990,10 +1990,10 @@ impl Fragment {
|
|||
SpecificFragmentInfo::Canvas(_) | SpecificFragmentInfo::Iframe(_) |
|
||||
SpecificFragmentInfo::Image(_) | SpecificFragmentInfo::Svg(_) |
|
||||
SpecificFragmentInfo::Generic | SpecificFragmentInfo::GeneratedContent(_) => {
|
||||
let ascent = self.border_box.size.block + self.margin.block_start;
|
||||
let ascent = self.border_box.size.block + self.margin.block_end;
|
||||
InlineMetrics {
|
||||
space_above_baseline: ascent,
|
||||
space_below_baseline: self.margin.block_end,
|
||||
space_above_baseline: ascent + self.margin.block_start,
|
||||
space_below_baseline: Au(0),
|
||||
ascent: ascent,
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue