mirror of
https://github.com/apache/xmlgraphics-fop.git
synced 2024-08-08 14:10:18 +02:00
test for images with errors
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@195106 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
5b83ed0542
commit
af6f615d12
BIN
test/resources/fop/image/corrupt.gif
Normal file
BIN
test/resources/fop/image/corrupt.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.1 KiB |
BIN
test/resources/fop/image/corrupt.jpg
Normal file
BIN
test/resources/fop/image/corrupt.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.2 KiB |
34
test/resources/fop/image/corrupt.svg
Normal file
34
test/resources/fop/image/corrupt.svg
Normal file
@ -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>
|
After Width: | Height: | Size: 1.6 KiB |
8
test/resources/fop/image/corrupt.xml
Normal file
8
test/resources/fop/image/corrupt.xml
Normal file
@ -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>
|
47
test/resources/fop/image/errors.fo
Normal file
47
test/resources/fop/image/errors.fo
Normal file
@ -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>
|
||||
|
Loading…
Reference in New Issue
Block a user