Revision control

1
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2
<html>
3
<head>
4
<script src="../resources/js-test-pre.js"></script>
5
<script src="resources/paged-media-test-utils.js"></script>
6
</head>
7
<body>
8
<p id="description"></p>
9
<div id="console"></div>
10
<div id="sandbox"></div>
11
<script>
12
description("Test for page-break with 'display:none'");
13
14
function test()
15
{
16
createBlockWithRatioToPageHeight("page1-1", 0.1).style.pageBreakBefore = "always";
17
18
// if 'display' is 'none', page break property should not have any effect.
19
var block = createBlockWithRatioToPageHeight("displaynone", 0.1);
20
block.style.pageBreakBefore = "always";
21
block.style.display = "none";
22
23
createBlockWithRatioToPageHeight("page1-2", 0.1);
24
25
pageNumberForElementShouldBe("page1-1", 1);
26
pageNumberForElementShouldBe("displaynone", -1);
27
pageNumberForElementShouldBe("page1-2", 1);
28
29
document.body.removeChild(document.getElementById("sandbox"));
30
}
31
32
var successfullyParsed = true;
33
</script>
34
<script>runPrintingTest(test);</script>
35
<script src="../resources/js-test-post.js"></script>
36
</body>
37
</html>