зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1740304: Apply the print fragmentation-fallback "additional offset" in one case where it was being missed. r=miko
We call MaybeApplyAdditionalOffset a few lines up when setting *aOffset, but it looks like we missed this particular codepath. This was causing content to render properly during print-preview (which takes the upper codepath) but not during actual printing (which takes the lower codepath, the one where I'm adding the new call). Differential Revision: https://phabricator.services.mozilla.com/D137199
This commit is contained in:
Родитель
5158f364d5
Коммит
93a7663777
|
@ -1552,6 +1552,7 @@ const nsIFrame* nsDisplayListBuilder::FindReferenceFrameFor(
|
|||
|
||||
if (aOffset) {
|
||||
*aOffset = aFrame->GetOffsetToCrossDoc(mReferenceFrame);
|
||||
MaybeApplyAdditionalOffset();
|
||||
}
|
||||
|
||||
return mReferenceFrame;
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
[block-002-wm-vlr-print.html]
|
||||
fuzzy:
|
||||
if (os == "mac"): maxDifference=0-74;totalPixels=0-383
|
||||
if (os != "mac"): maxDifference=0-74;totalPixels=0-388
|
||||
bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1752639
|
|
@ -0,0 +1,4 @@
|
|||
[block-002-wm-vrl-print.html]
|
||||
fuzzy:
|
||||
if (os != "mac"): maxDifference=0-74;totalPixels=0-302
|
||||
bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1752639
|
|
@ -1,3 +1,3 @@
|
|||
[mask-print.svg]
|
||||
expected:
|
||||
if (os == "mac") and not debug: [FAIL, PASS]
|
||||
expected: FAIL
|
||||
bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1752627
|
||||
|
|
|
@ -0,0 +1,33 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>test that inline-blocks are fragmented in print output</title>
|
||||
<link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1740304">
|
||||
<meta name="reftest-pages" content="10">
|
||||
<link rel="mismatch" href="/css/reference/blank.html">
|
||||
<style>
|
||||
.inline-block {
|
||||
display: inline-block;
|
||||
}
|
||||
li { height: 1in; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<!-- This test is expecting there to be content on page 10, as a
|
||||
regression-test for a bug where each page was progressively
|
||||
more-clipped, which caused later pages (e.g. page 10) to be fully-blank.
|
||||
In this testcase, we have 40 1-inch-tall numbered list-items, which
|
||||
collectively are 40 inches tall. This is tall enough to ensure that
|
||||
we'll have at least 10 pages, given that our pages are each 3 inches
|
||||
tall. -->
|
||||
<div class="inline-block">
|
||||
<ol>
|
||||
<li><li><li><li><li><li><li><li><li><li>
|
||||
<li><li><li><li><li><li><li><li><li><li>
|
||||
<li><li><li><li><li><li><li><li><li><li>
|
||||
<li><li><li><li><li><li><li><li><li><li>
|
||||
</ol>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,18 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Reference Case</title>
|
||||
<link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1740304">
|
||||
<style>
|
||||
.tall {
|
||||
height: 10in;
|
||||
width: 1in;
|
||||
border: 0.5in solid black;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="tall"></div>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,25 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>test that inline-blocks are fragmented in print output</title>
|
||||
<link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1740304">
|
||||
<link rel="match" href="fragmented-inline-block-002-print-ref.html">
|
||||
<style>
|
||||
.tall {
|
||||
/* The reference case has a block; we have an inline-block.
|
||||
Given that there's no other content on our line, we can expect our
|
||||
inline-block to end up rendering and fragmenting like the
|
||||
reference case's block. */
|
||||
display: inline-block;
|
||||
|
||||
height: 10in;
|
||||
width: 1in;
|
||||
border: 0.5in solid black;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="tall"></div>
|
||||
</body>
|
||||
</html>
|
Загрузка…
Ссылка в новой задаче