aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/resources/fop/image/corrupt.gifbin0 -> 2153 bytes
-rw-r--r--test/resources/fop/image/corrupt.jpgbin0 -> 2212 bytes
-rw-r--r--test/resources/fop/image/corrupt.svg34
-rw-r--r--test/resources/fop/image/corrupt.xml8
-rw-r--r--test/resources/fop/image/errors.fo47
5 files changed, 89 insertions, 0 deletions
diff --git a/test/resources/fop/image/corrupt.gif b/test/resources/fop/image/corrupt.gif
new file mode 100644
index 000000000..930b5fe38
--- /dev/null
+++ b/test/resources/fop/image/corrupt.gif
Binary files differ
diff --git a/test/resources/fop/image/corrupt.jpg b/test/resources/fop/image/corrupt.jpg
new file mode 100644
index 000000000..3c8a4e4a8
--- /dev/null
+++ b/test/resources/fop/image/corrupt.jpg
Binary files differ
diff --git a/test/resources/fop/image/corrupt.svg b/test/resources/fop/image/corrupt.svg
new file mode 100644
index 000000000..05d840997
--- /dev/null
+++ b/test/resources/fop/image/corrupt.svg
@@ -0,0 +1,34 @@
+
+<svg contentScriptType="text/ecmascript" width="350.0" zoomAndPan="magnify"
+ style="font-size:12.0;font-family:sansserif" contentStyleType="text/css"
+ height="150.0" preserveAspectRatio="xMidYMid meet"
+ xmlns="http://www.w3.org/2000/svg" version="1.0">
+ <g transform="translate(339.5,0)">
+ <rect width="10.0" x="0.0" height="10.0" y="0.0"
+ style="stroke:black;fill:rgb(0,0,255)"/>
+ <rect width="10.0" x="0.0" height="10.0" y="16.3"
+ style="stroke:black;fill:rgb(255,255,0)"/>
+ </g>
+ <g style="font-size:12.0;font-family:sansserif">
+ <text x="80.0" y="18.0">
+ </text>
+ <ellipse rx="129.0" ry="36.986267"
+ style="stroke:black;fill:rgb(0,0,255)" cx="169.0"
+ cy="57.986267"/>
+ <path style="stroke:black;fill:rgb(0,0,255)"
+ d="M 169.0 21.0L 169 57.986265578290165L 169.0 21.0z"/>
+ <path style="stroke:black;fill:rgb(0,0,128)"
+ d="M 298.0 57.986265578290165l 0 25.0A 129.0 36.986265578290165 0 0 1 40.0 82.98626557829017l 0 -25.0A 129.0 36.986265578290165 0 0 0 298.0 57.986265578290165z"/>
+ <path style="stroke:black;fill:rgb(255,255,0)"
+ d="M 168.99999999999997 21.0L 169 57.986265578290165L 168.99999999999997 21.0z"/>
+ <text x="141.86719" y="139.97253"
+ style="font-size:12.0;font-family:sansserif">
+ 100,0%
+ <text x="150.76562" y="13.798828"
+ style="font-size:12.0;font-family:sansserif">
+ 0,0%
+ </text>
+ <line y2="21.0" style="stroke:black" x1="164.4414" x2="169.0"
+ y1="14.798828"/>
+ </g>
+</svg>
diff --git a/test/resources/fop/image/corrupt.xml b/test/resources/fop/image/corrupt.xml
new file mode 100644
index 000000000..8a03f2c34
--- /dev/null
+++ b/test/resources/fop/image/corrupt.xml
@@ -0,0 +1,8 @@
+
+<blah width="350.0"
+ height="150.0"
+ xmlns="http://www.blah.org/" version="1.0">
+ <b>
+ <t x="80.0" y="18.0">
+ </b>
+</blah>
diff --git a/test/resources/fop/image/errors.fo b/test/resources/fop/image/errors.fo
new file mode 100644
index 000000000..6ee931e90
--- /dev/null
+++ b/test/resources/fop/image/errors.fo
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<fo:root font-family="Times Roman" font-size="12pt" text-align="center" xmlns:fo="http://www.w3.org/1999/XSL/Format">
+
+<fo:layout-master-set>
+ <fo:simple-page-master
+ margin-right="1.5cm"
+ margin-left="1.5cm"
+ margin-bottom="2cm"
+ margin-top="1cm"
+ page-width="21cm"
+ page-height="29.7cm"
+ master-name="left">
+ <fo:region-before extent="1cm"/>
+ <fo:region-body margin-top="1cm"/>
+ <fo:region-after extent="1.5cm"/>
+ </fo:simple-page-master>
+
+</fo:layout-master-set>
+
+<fo:page-sequence id="N2528" master-reference="left">
+
+<fo:static-content flow-name="xsl-region-after">
+ <fo:block text-align-last="center" font-size="10pt">
+ <fo:page-number/>
+ </fo:block>
+</fo:static-content>
+
+<fo:flow flow-name="xsl-region-body">
+<fo:block font-size="18pt" font-weight="bold">Images with errors</fo:block>
+<fo:block>
+Various corrupt images in FOP:
+A (<fo:external-graphic src="file:corrupt.gif"/>),
+B (<fo:external-graphic src="file:corrupt.jpg"/>),
+C (<fo:external-graphic src="file:corrupt.svg"/>),
+D (<fo:external-graphic src="file:corrupt.xml"/>).
+</fo:block>
+
+<fo:block>
+ <fo:block font-size="16pt" font-weight="bold" space-before.minimum="1em" space-before.optimum="1.5em" space-before.maximum="2em"/>
+ This section is only required to show that the layout still works.
+</fo:block>
+</fo:flow>
+</fo:page-sequence>
+
+</fo:root>
+