Skip to content
Permalink
Browse files

Floor to 0 when computing intrinsic sizes for box-sizing:border-box

  • Loading branch information
stshine committed Apr 18, 2017
1 parent 3011f76 commit 754d29c8998301b508b80ddf107467113e3421a7
@@ -937,7 +937,7 @@ impl Fragment {
}

if self.style.get_position().box_sizing == box_sizing::T::border_box {
specified -= border_padding
specified = max(Au(0), specified - border_padding);
}
}

@@ -3131,6 +3131,18 @@
{}
]
],
"css/intrinsic_border_box.html": [
[
"/_mozilla/css/intrinsic_border_box.html",
[
[
"/_mozilla/css/intrinsic_border_box_ref.html",
"=="
]
],
{}
]
],
"css/issue-1324.html": [
[
"/_mozilla/css/issue-1324.html",
@@ -8073,6 +8085,11 @@
{}
]
],
"css/intrinsic_border_box_ref.html": [
[
{}
]
],
"css/issue-1324-ref.html": [
[
{}
"c78c6c992e47adb47ba00b621210ae8564d46389",
"support"
],
"css/intrinsic_border_box.html": [
"261487f82f350ab020f49f362993b26711a89b5b",
"reftest"
],
"css/intrinsic_border_box_ref.html": [
"9a8f19331c748658b71c85b823b5b3db68e4b7a4",
"support"
],
"css/issue-1324-ref.html": [
"ef2253d5045622f54634dbfa6b6abdef6b6e00a7",
"support"
@@ -0,0 +1,19 @@
<!doctype html>
<meta charset="utf-8">
<title></title>
<link rel="match" href="intrinsic_border_box_ref.html">
<style>
.outer {
float: left;
box-sizing: border-box;
padding: 0 50px;
}
.inner {
float: left;
width: 100px;
height: 30px;
background: orange;
}
</style>
<div class="outer"><div class="inner"></div></div>
<div class="outer"><div class="inner"></div></div>
@@ -0,0 +1,17 @@
<!doctype html>
<meta charset="utf-8">
<title></title>
<style>
.outer {
float: left;
padding: 0 50px;
}
.inner {
float: left;
width: 100px;
height: 30px;
background: orange;
}
</style>
<div class="outer"><div class="inner"></div></div>
<div class="outer"><div class="inner"></div></div>

0 comments on commit 754d29c

Please sign in to comment.
You can’t perform that action at this time.