diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 460ac965f..78217f0bb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,6 @@ -# Contributing to iText 7 Community +# Contributing to iText Community -We'd love for you to contribute to our source code and to make **iText 7 Community** even better than it is +We'd love for you to contribute to our source code and to make **iText Community** even better than it is today! Here are the guidelines we'd like you to follow: - [Question or Problem?](#question) @@ -15,7 +15,7 @@ today! Here are the guidelines we'd like you to follow: ## Got a Question or Problem? -If you have questions about how to use **iText 7 Community**, please direct these to [Stack Overflow][stackoverflow]. +If you have questions about how to use **iText Community**, please direct these to [Stack Overflow][stackoverflow]. If you are a customer with a [support agreement][support], you also have direct access to our JIRA and our developers. @@ -55,7 +55,7 @@ chances of your issue being dealt with quickly: * **Related Issues** - has a similar issue been reported before? * **Suggest a Fix** - if you can't fix the bug yourself, perhaps you can point to what might be causing the problem (line of code or commit) -* **Tag the question** - add the tag `itext7` to your question so we can find it. +* **Tag the question** - add the tag `itext` to your question so we can find it. **If you get help, help others. Good karma rulez!** @@ -79,7 +79,7 @@ Before you submit your pull request consider the following guidelines: * Build your changes locally to ensure all the tests pass. * Push your changes to your GitHub account. * Create a pull request in GitHub. -"Head fork" should be your repository, and the "base fork" should be the iText7 official repository. +"Head fork" should be your repository, and the "base fork" should be the iText official repository. * If we suggest changes then: * Make the required updates. * Fix up your commits if needed, with an interactive rebase. @@ -111,7 +111,7 @@ To ensure consistency throughout the source code, keep these rules in mind as yo We have guidelines on how our git commit messages should be formatted. This leads to **more readable messages** that are easy to follow when looking through the **project history**. But also, -we use the git commit messages to **generate the iText 7 Community change log**. +we use the git commit messages to **generate the iText Community change log**. These guidelines were taken from Chris Beams' blog post [How to Write a Git Commit Message][git-commit]. @@ -169,7 +169,7 @@ We use the [Stack Exchange][stackoverflow] network for free support and [GitHub] [javadocs]: https://itextpdf.com/api [pull]: https://github.com/itext/i7j-pdfhtml/pulls [sscce]: http://sscce.org/ -[stackoverflow]: https://stackoverflow.com/questions/tagged/itext7 +[stackoverflow]: https://stackoverflow.com/questions/tagged/itext [good-questions]: https://stackoverflow.com/help/how-to-ask [mcve]: https://stackoverflow.com/help/mcve [support]: https://itextpdf.com/support diff --git a/README.md b/README.md index 2a7095d96..b9bcd7947 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -**[pdfHtml][pdfHtml]** is an [iText 7][itext] add on. +**[pdfHtml][pdfHtml]** is an [iText][itext] add on. This add on will allow you to easily convert HTML to PDF or iText objects. @@ -35,4 +35,4 @@ Contact [sales] for more info. [latest]: https://github.com/itext/i7j-pdfhtml/releases/latest [sales]: http://itextpdf.com/sales [gratis]: https://en.wikipedia.org/wiki/Gratis_versus_libre -[pdfHtml]: http://itextpdf.com/itext7/pdfHtml \ No newline at end of file +[pdfHtml]: https://itextpdf.com/products/convert-html-css-to-pdf-pdfhtml \ No newline at end of file diff --git a/pom.xml b/pom.xml index 8f9aaa209..b8d83e4a2 100644 --- a/pom.xml +++ b/pom.xml @@ -5,20 +5,20 @@ com.itextpdf root - 8.0.1 + 8.0.2 html2pdf - 5.0.1 + 5.0.2 pdfHTML pdfHTML is an iText add-on that lets you to parse (X)HTML snippets and the associated CSS and converts them to PDF. - scm:git:ssh://git@git.itextsupport.com:7999/i7j/html2pdf.git - https://git.itextsupport.com/projects/I7J/repos/html2pdf + git@github.com:itext/i7j-pdfhtml.git + https://github.com/itext/i7j-pdfhtml diff --git a/src/main/java/com/itextpdf/html2pdf/ConverterProperties.java b/src/main/java/com/itextpdf/html2pdf/ConverterProperties.java index 62fe9c610..bfed9482e 100644 --- a/src/main/java/com/itextpdf/html2pdf/ConverterProperties.java +++ b/src/main/java/com/itextpdf/html2pdf/ConverterProperties.java @@ -22,10 +22,10 @@ This file is part of the iText (R) project. */ package com.itextpdf.html2pdf; +import com.itextpdf.commons.actions.contexts.IMetaInfo; import com.itextpdf.html2pdf.attach.ITagWorkerFactory; import com.itextpdf.html2pdf.attach.impl.OutlineHandler; import com.itextpdf.html2pdf.css.apply.ICssApplierFactory; -import com.itextpdf.commons.actions.contexts.IMetaInfo; import com.itextpdf.layout.font.FontProvider; import com.itextpdf.styledxmlparser.css.media.MediaDeviceDescription; import com.itextpdf.styledxmlparser.resolver.resource.IResourceRetriever; @@ -326,8 +326,11 @@ public boolean isCreateAcroForm() { * If createAcroForm is set, then when the form is encountered in HTML, AcroForm will be created, otherwise * a visually identical, but not functional element will be created. Please bare in mind that the created * Acroform may visually differ a bit from the HTML one. + *

+ * When enabling this acroform creation, it will disable the immediateFlushing property. * * @param createAcroForm true if an AcroForm needs to be created + * * @return the {@link ConverterProperties} instance */ public ConverterProperties setCreateAcroForm(boolean createAcroForm) { diff --git a/src/main/java/com/itextpdf/html2pdf/actions/data/PdfHtmlProductData.java b/src/main/java/com/itextpdf/html2pdf/actions/data/PdfHtmlProductData.java index e76548b29..db6ea5754 100644 --- a/src/main/java/com/itextpdf/html2pdf/actions/data/PdfHtmlProductData.java +++ b/src/main/java/com/itextpdf/html2pdf/actions/data/PdfHtmlProductData.java @@ -30,7 +30,7 @@ This file is part of the iText (R) project. */ public final class PdfHtmlProductData { private static final String PDF_HTML_PUBLIC_PRODUCT_NAME = "pdfHTML"; - private static final String PDF_HTML_VERSION = "5.0.1"; + private static final String PDF_HTML_VERSION = "5.0.2"; private static final int PDF_HTML_COPYRIGHT_SINCE = 2000; private static final int PDF_HTML_COPYRIGHT_TO = 2023; diff --git a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/HtmlTagWorker.java b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/HtmlTagWorker.java index da6038789..a44a9efde 100644 --- a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/HtmlTagWorker.java +++ b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/HtmlTagWorker.java @@ -31,6 +31,7 @@ This file is part of the iText (R) project. import com.itextpdf.html2pdf.attach.util.WaitingInlineElementsHelper; import com.itextpdf.html2pdf.css.CssConstants; import com.itextpdf.html2pdf.html.AttributeConstants; +import com.itextpdf.html2pdf.logs.Html2PdfLogMessageConstant; import com.itextpdf.io.font.PdfEncodings; import com.itextpdf.kernel.pdf.PdfDocument; import com.itextpdf.kernel.pdf.PdfString; @@ -45,15 +46,24 @@ This file is part of the iText (R) project. import com.itextpdf.styledxmlparser.node.IElementNode; import com.itextpdf.styledxmlparser.node.INode; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + /** * TagWorker class for the {@code html} element. */ public class HtmlTagWorker implements ITagWorker { - /** The iText document instance. */ + private static final Logger LOGGER = LoggerFactory.getLogger(HtmlTagWorker.class); + + /** + * The iText document instance. + */ private Document document; - /** Helper class for waiting inline elements. */ + /** + * Helper class for waiting inline elements. + */ private WaitingInlineElementsHelper inlineHelper; /** @@ -65,14 +75,19 @@ public class HtmlTagWorker implements ITagWorker { public HtmlTagWorker(IElementNode element, ProcessorContext context) { // TODO DEVSIX-4261 more precise check if a counter was actually added to the document boolean immediateFlush = - context.isImmediateFlush() && !context.getCssContext().isPagesCounterPresent(); + context.isImmediateFlush() && !context.getCssContext().isPagesCounterPresent() + && !context.isCreateAcroForm(); + if (context.isImmediateFlush() && context.isCreateAcroForm()) { + LOGGER.info(Html2PdfLogMessageConstant.IMMEDIATE_FLUSH_DISABLED); + } PdfDocument pdfDocument = context.getPdfDocument(); document = new HtmlDocument(pdfDocument, pdfDocument.getDefaultPageSize(), immediateFlush); document.setRenderer(new HtmlDocumentRenderer(document, immediateFlush)); DefaultHtmlProcessor.setConvertedRootElementProperties(element.getStyles(), context, document); - inlineHelper = new WaitingInlineElementsHelper(element.getStyles().get(CssConstants.WHITE_SPACE), element.getStyles().get(CssConstants.TEXT_TRANSFORM)); + inlineHelper = new WaitingInlineElementsHelper(element.getStyles().get(CssConstants.WHITE_SPACE), + element.getStyles().get(CssConstants.TEXT_TRANSFORM)); String lang = element.getAttribute(AttributeConstants.LANG); if (lang != null) { diff --git a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ImgTagWorker.java b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ImgTagWorker.java index 9699498b1..f141e0b6a 100644 --- a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ImgTagWorker.java +++ b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ImgTagWorker.java @@ -36,6 +36,8 @@ This file is part of the iText (R) project. import com.itextpdf.layout.element.Image; import com.itextpdf.layout.properties.ObjectFit; import com.itextpdf.styledxmlparser.node.IElementNode; +import com.itextpdf.svg.element.SvgImage; +import com.itextpdf.svg.xobject.SvgImageXObject; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -71,6 +73,8 @@ public ImgTagWorker(IElementNode element, ProcessorContext context) { if (imageXObject != null) { if (imageXObject instanceof PdfImageXObject) { image = new HtmlImage((PdfImageXObject) imageXObject); + } else if (imageXObject instanceof SvgImageXObject) { + image = new SvgImage((SvgImageXObject) imageXObject); } else if (imageXObject instanceof PdfFormXObject) { image = new HtmlImage((PdfFormXObject) imageXObject); } else { diff --git a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ObjectTagWorker.java b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ObjectTagWorker.java index 8719cb40c..296edccd9 100644 --- a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ObjectTagWorker.java +++ b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/ObjectTagWorker.java @@ -31,7 +31,6 @@ This file is part of the iText (R) project. import com.itextpdf.html2pdf.util.SvgProcessingUtil; import com.itextpdf.commons.utils.FileUtil; import com.itextpdf.commons.utils.MessageFormatUtil; -import com.itextpdf.kernel.pdf.PdfDocument; import com.itextpdf.layout.IPropertyContainer; import com.itextpdf.layout.element.Image; import com.itextpdf.styledxmlparser.node.IElementNode; @@ -117,17 +116,10 @@ private boolean isSvgImage(String typeAttribute) { @Override public void processEnd(IElementNode element, ProcessorContext context) { - if (context.getPdfDocument() != null) { - PdfDocument document = context.getPdfDocument(); - //Create Image object - - if (res != null) { - image = processUtil.createImageFromProcessingResult(res, document); - AccessiblePropHelper.trySetLangAttribute(image, element); - } - - } else { - LOGGER.error(Html2PdfLogMessageConstant.PDF_DOCUMENT_NOT_PRESENT); + // Create Image object + if (res != null) { + image = processUtil.createSvgImageFromProcessingResult(res); + AccessiblePropHelper.trySetLangAttribute(image, element); } } diff --git a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/SvgTagWorker.java b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/SvgTagWorker.java index f7107198a..139eaabb4 100644 --- a/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/SvgTagWorker.java +++ b/src/main/java/com/itextpdf/html2pdf/attach/impl/tags/SvgTagWorker.java @@ -68,9 +68,9 @@ public SvgTagWorker(IElementNode element, ProcessorContext context) { @Override public void processEnd(IElementNode element, ProcessorContext context) { - if (context.getPdfDocument() != null && processingResult != null) { + if (processingResult != null) { SvgProcessingUtil util = new SvgProcessingUtil(context.getResourceResolver()); - svgImage = util.createImageFromProcessingResult(processingResult, context.getPdfDocument()); + svgImage = util.createSvgImageFromProcessingResult(processingResult); AccessiblePropHelper.trySetLangAttribute(svgImage, element); context.endProcessingInlineSvg(); diff --git a/src/main/java/com/itextpdf/html2pdf/css/apply/util/BackgroundApplierUtil.java b/src/main/java/com/itextpdf/html2pdf/css/apply/util/BackgroundApplierUtil.java index ca7df748e..edc62e004 100644 --- a/src/main/java/com/itextpdf/html2pdf/css/apply/util/BackgroundApplierUtil.java +++ b/src/main/java/com/itextpdf/html2pdf/css/apply/util/BackgroundApplierUtil.java @@ -26,8 +26,6 @@ This file is part of the iText (R) project. import com.itextpdf.html2pdf.attach.ProcessorContext; import com.itextpdf.html2pdf.css.CssConstants; import com.itextpdf.commons.utils.MessageFormatUtil; -import com.itextpdf.kernel.colors.Color; -import com.itextpdf.kernel.colors.DeviceRgb; import com.itextpdf.kernel.colors.gradients.StrategyBasedLinearGradientBuilder; import com.itextpdf.kernel.pdf.xobject.PdfFormXObject; import com.itextpdf.kernel.pdf.xobject.PdfImageXObject; diff --git a/src/main/java/com/itextpdf/html2pdf/css/apply/util/ListStyleApplierUtil.java b/src/main/java/com/itextpdf/html2pdf/css/apply/util/ListStyleApplierUtil.java index 853008b6b..e7d0e3707 100644 --- a/src/main/java/com/itextpdf/html2pdf/css/apply/util/ListStyleApplierUtil.java +++ b/src/main/java/com/itextpdf/html2pdf/css/apply/util/ListStyleApplierUtil.java @@ -53,6 +53,8 @@ This file is part of the iText (R) project. import com.itextpdf.styledxmlparser.node.IElementNode; import com.itextpdf.styledxmlparser.node.IStylesContainer; +import com.itextpdf.svg.element.SvgImage; +import com.itextpdf.svg.xobject.SvgImageXObject; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -145,6 +147,8 @@ public static void applyListStyleImageProperty(Map cssProps, Pro Image image = null; if (imageXObject instanceof PdfImageXObject) { image = new Image((PdfImageXObject) imageXObject); + } else if (imageXObject instanceof SvgImageXObject) { + image = new SvgImage((SvgImageXObject) imageXObject); } else if (imageXObject instanceof PdfFormXObject) { image = new Image((PdfFormXObject) imageXObject); } else { diff --git a/src/main/java/com/itextpdf/html2pdf/css/apply/util/VerticalAlignmentApplierUtil.java b/src/main/java/com/itextpdf/html2pdf/css/apply/util/VerticalAlignmentApplierUtil.java index 31757d9f2..eb96078d6 100644 --- a/src/main/java/com/itextpdf/html2pdf/css/apply/util/VerticalAlignmentApplierUtil.java +++ b/src/main/java/com/itextpdf/html2pdf/css/apply/util/VerticalAlignmentApplierUtil.java @@ -141,7 +141,7 @@ public static void applyVerticalAlignmentForInlines(Map cssProps String vAlignVal = cssProps.get(CssConstants.VERTICAL_ALIGN); if (vAlignVal != null) { - // TODO DEVSIX-1750 for inline images and tables (inline-blocks) v-align is not supported + // TODO DEVSIX-1961 for inline images and tables (inline-blocks) v-align is not supported float textRise = 0; diff --git a/src/main/java/com/itextpdf/html2pdf/logs/Html2PdfLogMessageConstant.java b/src/main/java/com/itextpdf/html2pdf/logs/Html2PdfLogMessageConstant.java index e27e0c4f9..34dad6edf 100644 --- a/src/main/java/com/itextpdf/html2pdf/logs/Html2PdfLogMessageConstant.java +++ b/src/main/java/com/itextpdf/html2pdf/logs/Html2PdfLogMessageConstant.java @@ -119,6 +119,7 @@ public final class Html2PdfLogMessageConstant { public static final String PAGE_SIZE_VALUE_IS_INVALID = "Page size value {0} is invalid."; /** The Constant PDF_DOCUMENT_NOT_PRESENT. */ + @Deprecated public static final String PDF_DOCUMENT_NOT_PRESENT = "PdfDocument is not present"; /** The Constant QUOTES_PROPERTY_INVALID. */ @@ -171,6 +172,7 @@ public final class Html2PdfLogMessageConstant { public static final String ELEMENT_DOES_NOT_FIT_CURRENT_AREA = "Element does not fit current area"; public static final String OPTGROUP_NOT_SUPPORTED_IN_INTERACTIVE_SELECT = "Option groups are not supported in " + "interactive mode"; + public static final String IMMEDIATE_FLUSH_DISABLED = "Setting createAcroForm disables immediateFlush property"; private Html2PdfLogMessageConstant() { //Private constructor will prevent the instantiation of this class directly diff --git a/src/main/java/com/itextpdf/html2pdf/resolver/font/DefaultFontProvider.java b/src/main/java/com/itextpdf/html2pdf/resolver/font/DefaultFontProvider.java index a2626c82a..328ed6e84 100644 --- a/src/main/java/com/itextpdf/html2pdf/resolver/font/DefaultFontProvider.java +++ b/src/main/java/com/itextpdf/html2pdf/resolver/font/DefaultFontProvider.java @@ -38,7 +38,7 @@ This file is part of the iText (R) project. /** * The default {@link BasicFontProvider} for pdfHTML, that, as opposed to - * the font provider in iText 7's styled-xml-parser, also includes a + * the font provider in iText's styled-xml-parser, also includes a * series of fonts that are shipped with the add-on. */ public class DefaultFontProvider extends BasicFontProvider { diff --git a/src/main/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolver.java b/src/main/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolver.java index 880e8e82d..5c27d36ef 100644 --- a/src/main/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolver.java +++ b/src/main/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolver.java @@ -32,6 +32,7 @@ This file is part of the iText (R) project. import com.itextpdf.styledxmlparser.resolver.resource.IResourceRetriever; import com.itextpdf.styledxmlparser.resolver.resource.ResourceResolver; import com.itextpdf.svg.converter.SvgConverter; +import com.itextpdf.svg.element.SvgImage; import com.itextpdf.svg.processors.ISvgProcessorResult; import com.itextpdf.svg.processors.impl.SvgConverterProperties; @@ -49,7 +50,7 @@ public class HtmlResourceResolver extends ResourceResolver { private static final String SVG_PREFIX = "data:image/svg+xml"; private static final Pattern SVG_IDENTIFIER_PATTERN = Pattern.compile(",[\\s]*(getProperty(Property.FONT)); + Assert.assertArrayEquals(new String[]{"monospace"}, anonymousParagraph.getProperty(Property.FONT)); IElement normalParagraph = elements.get(1); - Assert.assertArrayEquals(new String[] {"monospace"}, normalParagraph.getProperty(Property.FONT)); + Assert.assertArrayEquals(new String[]{"monospace"}, normalParagraph.getProperty(Property.FONT)); } @Test @@ -274,7 +270,7 @@ public void eventGenerationTest() { Assert.assertEquals(1, handler.getEvents().size()); Assert.assertTrue(handler.getEvents().get(0) instanceof PdfHtmlProductEvent); - SequenceId expectedSequenceId = ((PdfHtmlProductEvent)handler.getEvents().get(0)).getSequenceId(); + SequenceId expectedSequenceId = ((PdfHtmlProductEvent) handler.getEvents().get(0)).getSequenceId(); int validationsCount = validateSequenceIds(expectedSequenceId, elements); // Table 1 // Cell -> Paragraph -> Text [123] 3 @@ -290,13 +286,13 @@ public void eventGenerationTest() { } @Test - public void convertToElementsAndCreateTwoDocumentsTest() throws FileNotFoundException { + public void convertToElementsAndCreateTwoDocumentsTest() { String html = "This text is directly in body. It should have the same default LEADING property as everything else.\n" + "

This text is in paragraph.

"; - List iElementList = HtmlConverter.convertToElements(html); + List iElementList = HtmlConverter.convertToElements(html); try (PdfDocument pdfDocument = new PdfDocument(new PdfWriter(new ByteArrayOutputStream())); - Document document = new Document(pdfDocument)) { + Document document = new Document(pdfDocument)) { addElementsToDocument(document, iElementList); } @@ -310,16 +306,79 @@ public void convertToElementsAndCreateTwoDocumentsTest() throws FileNotFoundExce } @Test - //TODO: DEVSIX-3891 change the Assert after supporting the svg tag - @LogMessages(messages = { - @LogMessage(messageTemplate = Html2PdfLogMessageConstant.WORKER_UNABLE_TO_PROCESS_OTHER_WORKER, logLevel = LogLevelConstants.ERROR) - }) - public void htmlToElementsSvgTest() { + public void htmlToElementsSvgTest() throws IOException, InterruptedException { String html = "" + "" + ""; + String cmpPdf = sourceFolder + "cmp_htmlToElementsSvg.pdf"; + String outPdf = destinationFolder + "htmlToElementsSvg.pdf"; List lst = HtmlConverter.convertToElements(html); - Assert.assertEquals(0, lst.size()); + Assert.assertEquals(1, lst.size()); + try (Document document = new Document(new PdfDocument(new PdfWriter(outPdf)))) { + for (IElement element : lst) { + document.add((Image) element); + } + } + Assert.assertNull(new CompareTool().compareByContent(outPdf, cmpPdf, destinationFolder)); + } + + @Test + public void htmlToElementsSvgInTheTableTest() throws IOException, InterruptedException { + String html = + "\n" + + " \n" + + " \n" + + " \n" + + " \n" + + "
\n" + + " \n" + + " \n" + + " \n" + + " \n" + + " test\n" + + "
"; + String cmpPdf = sourceFolder + "cmp_htmlToElementsSvgInTheTable.pdf"; + String outPdf = destinationFolder + "htmlToElementsSvgInTheTable.pdf"; + + List elements = HtmlConverter.convertToElements(html); + try (Document document = new Document(new PdfDocument(new PdfWriter(outPdf)))) { + for (IElement element : elements) { + document.add((IBlockElement) element); + } + } + Assert.assertNull(new CompareTool().compareByContent(outPdf, cmpPdf, destinationFolder)); + } + + @Test + public void htmlToElementsSvgImgTest() throws IOException, InterruptedException { + String html = ""; + String cmpPdf = sourceFolder + "cmp_htmlToElementsSvgImg.pdf"; + String outPdf = destinationFolder + "htmlToElementsSvgImg.pdf"; + + List elements = HtmlConverter.convertToElements(html, + new ConverterProperties().setBaseUri(sourceFolder)); + try (Document document = new Document(new PdfDocument(new PdfWriter(outPdf)))) { + for (IElement element : elements) { + document.add((IBlockElement) element); + } + } + Assert.assertNull(new CompareTool().compareByContent(outPdf, cmpPdf, destinationFolder)); + } + + @Test + public void htmlToElementsSvgObjectTest() throws IOException, InterruptedException { + String html = ""; + String cmpPdf = sourceFolder + "cmp_htmlToElementsSvgObject.pdf"; + String outPdf = destinationFolder + "htmlToElementsSvgObject.pdf"; + + List elements = HtmlConverter.convertToElements(html, + new ConverterProperties().setBaseUri(sourceFolder)); + try (Document document = new Document(new PdfDocument(new PdfWriter(outPdf)))) { + for (IElement element : elements) { + document.add((Image) element); + } + } + Assert.assertNull(new CompareTool().compareByContent(outPdf, cmpPdf, destinationFolder)); } private static void addElementsToDocument(Document document, List elements) { @@ -339,7 +398,7 @@ private static void addElementsToDocument(Document document, List elem private static int validateSequenceIds(SequenceId expectedSequenceId, List elements) { int validationCount = 0; - for (IElement element: elements) { + for (IElement element : elements) { Assert.assertTrue(element instanceof AbstractIdentifiableElement); Assert.assertTrue(element instanceof IAbstractElement); Assert.assertEquals(expectedSequenceId, SequenceIdManager.getSequenceId((AbstractIdentifiableElement) element)); diff --git a/src/test/java/com/itextpdf/html2pdf/css/FlexPagingTest.java b/src/test/java/com/itextpdf/html2pdf/css/FlexPagingTest.java index cf329bea0..286fce6ac 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/FlexPagingTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/FlexPagingTest.java @@ -23,6 +23,9 @@ This file is part of the iText (R) project. package com.itextpdf.html2pdf.css; import com.itextpdf.html2pdf.ExtendedHtmlConversionITextTest; +import com.itextpdf.io.logs.IoLogMessageConstant; +import com.itextpdf.test.annotations.LogMessage; +import com.itextpdf.test.annotations.LogMessages; import com.itextpdf.test.annotations.type.IntegrationTest; import java.io.IOException; @@ -54,13 +57,11 @@ public void columnNonPagingTest() throws IOException, InterruptedException { } @Test - //TODO DEVSIX-7622 change files after paging is introduced public void columnPagingTest() throws IOException, InterruptedException { convertToPdfAndCompare("column-paging", sourceFolder, destinationFolder); } @Test - //TODO DEVSIX-7622 change files after paging is introduced public void columnPagingMultiColumnTest() throws IOException, InterruptedException { convertToPdfAndCompare("column-paging-multi-column", sourceFolder, destinationFolder); } @@ -72,19 +73,73 @@ public void columnReverseNonPagingTest() throws IOException, InterruptedExceptio } @Test - //TODO DEVSIX-7622 change files after paging is introduced public void columnReversePagingTest() throws IOException, InterruptedException { convertToPdfAndCompare("column-reverse-paging", sourceFolder, destinationFolder); } @Test - //TODO DEVSIX-7622 change files after paging is introduced public void columnReversePagingMultiColumnTest() throws IOException, InterruptedException { convertToPdfAndCompare("column-reverse-paging-multi-column", sourceFolder, destinationFolder); } + @Test + public void columnPagingLargeElementTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-large-element", sourceFolder, destinationFolder); + } + + @Test + public void columnPagingLargeElementFlexEndJustificationTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-large-element-flex-end-justification", sourceFolder, destinationFolder); + } + + @Test + public void columnPagingLargeElementCenterJustificationTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-large-element-center-justification", sourceFolder, destinationFolder); + } + + @Test + public void columnPagingLargeElementFixedHeightTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-large-element-fixed-height", sourceFolder, destinationFolder); + } + + @Test + public void columnReversePagingLargeElementTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-reverse-paging-large-element", sourceFolder, destinationFolder); + } + @Test public void columnWrapReverseNonPagingTest() throws IOException, InterruptedException { convertToPdfAndCompare("column-wrap-reverse-non-paging", sourceFolder, destinationFolder); } + + @Test + @LogMessages(messages = @LogMessage(messageTemplate = IoLogMessageConstant.CLIP_ELEMENT)) + public void columnPagingInDivTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-in-div", sourceFolder, destinationFolder); + } + + @Test + public void columnPagingFixedHeightTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-paging-fixed-height", sourceFolder, destinationFolder); + } + + @Test + public void columnNoWrapPagingTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-nowrap-paging", sourceFolder, destinationFolder); + } + + @Test + public void columnFlexShrinkPagingTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-flex-shrink-paging", sourceFolder, destinationFolder); + } + + @Test + public void columnFlexGrowPagingTest() throws IOException, InterruptedException { + convertToPdfAndCompare("column-flex-grow-paging", sourceFolder, destinationFolder); + } + + @Test + public void columnFlexGrowPaging2Test() throws IOException, InterruptedException { + convertToPdfAndCompare("column-flex-grow-paging-2", sourceFolder, destinationFolder); + } } diff --git a/src/test/java/com/itextpdf/html2pdf/css/VerticalAlignmentTest.java b/src/test/java/com/itextpdf/html2pdf/css/VerticalAlignmentTest.java index 336dfc3f0..c69412656 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/VerticalAlignmentTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/VerticalAlignmentTest.java @@ -105,19 +105,16 @@ public void verticalAlignmentTest12() throws IOException, InterruptedException { } @Test - @Ignore("DEVSIX-1750") public void verticalAlignmentTest13() throws IOException, InterruptedException { convertToPdfAndCompare("verticalAlignmentTest13", sourceFolder, destinationFolder); } @Test - @Ignore("DEVSIX-1750") public void verticalAlignmentTest14() throws IOException, InterruptedException { convertToPdfAndCompare("verticalAlignmentTest14", sourceFolder, destinationFolder); } @Test - @Ignore("DEVSIX-1750") public void verticalAlignmentTest15() throws IOException, InterruptedException { convertToPdfAndCompare("verticalAlignmentTest15", sourceFolder, destinationFolder); } diff --git a/src/test/java/com/itextpdf/html2pdf/css/apply/util/TextDecorationApplierUtilTest.java b/src/test/java/com/itextpdf/html2pdf/css/apply/util/TextDecorationApplierUtilTest.java index 4be3cfab2..1c34e83c4 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/apply/util/TextDecorationApplierUtilTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/apply/util/TextDecorationApplierUtilTest.java @@ -27,6 +27,7 @@ This file is part of the iText (R) project. import com.itextpdf.styledxmlparser.node.IElementNode; import com.itextpdf.styledxmlparser.node.INode; import com.itextpdf.test.ExtendedITextTest; +import com.itextpdf.test.annotations.type.UnitTest; import java.util.ArrayList; import java.util.HashMap; @@ -34,7 +35,9 @@ This file is part of the iText (R) project. import java.util.Map; import org.junit.Assert; import org.junit.Test; +import org.junit.experimental.categories.Category; +@Category(UnitTest.class) public class TextDecorationApplierUtilTest extends ExtendedITextTest { private static IElementNode createNewNode(IElementNode parent, String color, String line, String decorationStyle) { diff --git a/src/test/java/com/itextpdf/html2pdf/css/multicol/BreakTest.java b/src/test/java/com/itextpdf/html2pdf/css/multicol/BreakTest.java index 5454c3710..d8e3fcaea 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/multicol/BreakTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/multicol/BreakTest.java @@ -24,6 +24,9 @@ This file is part of the iText (R) project. import com.itextpdf.html2pdf.ConverterProperties; import com.itextpdf.html2pdf.ExtendedHtmlConversionITextTest; +import com.itextpdf.html2pdf.logs.Html2PdfLogMessageConstant; +import com.itextpdf.test.annotations.LogMessage; +import com.itextpdf.test.annotations.LogMessages; import com.itextpdf.test.annotations.type.IntegrationTest; import java.io.IOException; @@ -70,6 +73,19 @@ public void convertPageBreakBeforeAlwaysTest() throws IOException, InterruptedEx runTest("pageBreakBeforeAlwaysTest"); } + //TODO: DEVSIX-7740 Support page-break inside multicol container + @Test + public void convertPageBreakBeforeInnerElementAlwaysTest() throws IOException, InterruptedException { + runTest("pageBreakBeforeInnerElementAlwaysTest"); + } + + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.ELEMENT_DOES_NOT_FIT_CURRENT_AREA)}) + public void convertPageBreakBeforeInnerElementDivAlwaysTest() throws IOException, InterruptedException { + runTest("pageBreakBeforeInnerElementDivAlwaysTest"); + } + @Test // TODO DEVSIX-3819 support break-after, break-before, break-inside CSS properties public void convertBreakBeforeAvoidTest() throws IOException, InterruptedException { @@ -127,11 +143,17 @@ public void convertBreakBeforePageInsideColumnTest() throws IOException, Interru } @Test - @Ignore("TODO DEVSIX-7552 Column-count: support break-inside, break-after and break-before properties") + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.ELEMENT_DOES_NOT_FIT_CURRENT_AREA)}) public void convertPageBreakBeforePageInsideColumnTest() throws IOException, InterruptedException { runTest("pageBreakBeforePageInsideColumnTest"); } + @Test + public void convertPageBreakBeforePageColumnTest() throws IOException, InterruptedException { + runTest("pageBreakBeforePageColumnTest"); + } + @Test // TODO DEVSIX-3819 support break-after, break-before, break-inside CSS properties public void convertBreakBeforeLeftTest() throws IOException, InterruptedException { @@ -194,6 +216,19 @@ public void convertPageBreakAfterAlwaysTest() throws IOException, InterruptedExc runTest("pageBreakAfterAlwaysTest"); } + //TODO: DEVSIX-7740 Support page-break inside multicol container + @Test + public void convertPageBreakAfterInnerElementAlwaysTest() throws IOException, InterruptedException { + runTest("pageBreakAfterInnerElementAlwaysTest"); + } + + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.ELEMENT_DOES_NOT_FIT_CURRENT_AREA)}) + public void convertPageBreakAfterInnerElementDivAlwaysTest() throws IOException, InterruptedException { + runTest("pageBreakAfterInnerElementDivAlwaysTest"); + } + @Test // TODO DEVSIX-3819 support break-after, break-before, break-inside CSS properties public void convertBreakAfterAvoidTest() throws IOException, InterruptedException { @@ -201,7 +236,6 @@ public void convertBreakAfterAvoidTest() throws IOException, InterruptedExceptio } @Test - // TODO DEVSIX-7552 Column-count: support break-inside, break-after and break-before properties public void convertPageBreakAfterAvoidTest() throws IOException, InterruptedException { runTest("pageBreakAfterAvoidTest"); } @@ -253,10 +287,16 @@ public void convertBreakAfterPageInsideColumnTest() throws IOException, Interrup } @Test - @Ignore("TODO DEVSIX-7552 Column-count: support break-inside, break-after and break-before properties") + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.ELEMENT_DOES_NOT_FIT_CURRENT_AREA)}) public void convertPageBreakAfterPageInsideColumnTest() throws IOException, InterruptedException { runTest("pageBreakAfterPageInsideColumnTest"); } + + @Test + public void convertPageBreakAfterPageColumnTest() throws IOException, InterruptedException { + runTest("pageBreakAfterPageColumnTest"); + } @Test // TODO DEVSIX-3819 support break-after, break-before, break-inside CSS properties @@ -310,8 +350,8 @@ public void convertBreakInsideAvoidTest() throws IOException, InterruptedExcepti runTest("breakInsideAvoidTest"); } + //TODO: DEVSIX-7740 Support page-break inside multicol container @Test - // TODO DEVSIX-7552 Column-count: support break-inside, break-after and break-before properties public void convertPageBreakInsideAvoidTest() throws IOException, InterruptedException { runTest("pageBreakInsideAvoidTest"); } diff --git a/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnCountTest.java b/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnCountTest.java index dbbb13a11..836a7678f 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnCountTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnCountTest.java @@ -137,7 +137,7 @@ public void convertBasicDisplayPropertyWithNestedColumnsTest() throws IOExceptio runTest("basicDisplayPropertyWithNestedColumnsTest"); } - //TODO: DEVSIX-7556 + //TODO: DEVSIX-7556 Support multicol+float elements on basic level @Test @LogMessages(messages = {@LogMessage(messageTemplate = LayoutLogMessageConstant.ELEMENT_DOES_NOT_FIT_AREA)}) public void convertBasicFloatPropertyTest() throws IOException, InterruptedException { @@ -225,11 +225,29 @@ public void nestingBetweenPagesTest() throws IOException, InterruptedException { } @Test - // TODO DEVSIX-7628 Investigate problem with border near to end of the page in multicol layouting + // TODO DEVSIX-7628 During calculating occupied area of multicol container take into account children border\padding\margin public void tripleNestingBetweenPagesTest() throws IOException, InterruptedException { runTest("tripleNestingBetweenPagesTest"); } + @Test + // TODO DEVSIX-7628 During calculating occupied area of multicol container take into account children border\padding\margin + public void childBorderTest() throws IOException, InterruptedException { + runTest("childBorderTest"); + } + + @Test + // TODO DEVSIX-7628 During calculating occupied area of multicol container take into account children border\padding\margin + public void childMarginTest() throws IOException, InterruptedException { + runTest("childMarginTest"); + } + + @Test + // TODO DEVSIX-7628 During calculating occupied area of multicol container take into account children border\padding\margin + public void childPaddingTest() throws IOException, InterruptedException { + runTest("childPaddingTest"); + } + @Test public void basicDlTest() throws IOException, InterruptedException { runTest("basicDlTest"); @@ -341,6 +359,7 @@ public void maxWidthToBigWrapped() throws IOException, InterruptedException { } @Test + // TODO DEVSIX-7702 Support content overflowing for multicol layouting in case of limited available area public void multiColLimitedArea() throws IOException, InterruptedException { runTest("multicolLimitedArea"); } @@ -357,11 +376,13 @@ public void multiColLimitedArea3() throws IOException, InterruptedException { } @Test + // TODO DEVSIX-7702 Support content overflowing for multicol layouting in case of limited available area public void multiColLimitedArea4() throws IOException, InterruptedException { runTest("multicolLimitedArea4"); } @Test + // TODO DEVSIX-7702 Support content overflowing for multicol layouting in case of limited available area public void multipleAttributes() throws IOException, InterruptedException { runTest("multiple_attributes"); } diff --git a/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnGapTest.java b/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnGapTest.java index 771ed1946..4a6f37f25 100644 --- a/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnGapTest.java +++ b/src/test/java/com/itextpdf/html2pdf/css/multicol/ColumnGapTest.java @@ -62,11 +62,13 @@ public void convertNegativeColumnGapValueTest() throws IOException, InterruptedE } @Test + // TODO DEVSIX-7631 Provide advanced support of percentage values for column-gap\width public void convertSmallColumnGapValueTest() throws IOException, InterruptedException { runTest("smallColumnGapValueTest"); } @Test + // TODO DEVSIX-7631 Provide advanced support of percentage values for column-gap\width public void convertFloatColumnGapValueTest() throws IOException, InterruptedException { runTest("floatColumnGapValueTest"); } diff --git a/src/test/java/com/itextpdf/html2pdf/element/FormTest.java b/src/test/java/com/itextpdf/html2pdf/element/FormTest.java index 05ff4ab3e..746546e87 100644 --- a/src/test/java/com/itextpdf/html2pdf/element/FormTest.java +++ b/src/test/java/com/itextpdf/html2pdf/element/FormTest.java @@ -27,7 +27,9 @@ This file is part of the iText (R) project. import com.itextpdf.forms.logs.FormsLogMessageConstants; import com.itextpdf.html2pdf.ConverterProperties; import com.itextpdf.html2pdf.HtmlConverter; +import com.itextpdf.html2pdf.logs.Html2PdfLogMessageConstant; import com.itextpdf.io.logs.IoLogMessageConstant; +import com.itextpdf.io.source.ByteArrayOutputStream; import com.itextpdf.io.util.UrlUtil; import com.itextpdf.kernel.pdf.PdfDocument; import com.itextpdf.kernel.pdf.PdfReader; @@ -35,11 +37,13 @@ This file is part of the iText (R) project. import com.itextpdf.kernel.utils.CompareTool; import com.itextpdf.layout.logs.LayoutLogMessageConstant; import com.itextpdf.test.ExtendedITextTest; +import com.itextpdf.test.LogLevelConstants; import com.itextpdf.test.annotations.LogMessage; import com.itextpdf.test.annotations.LogMessages; import com.itextpdf.test.annotations.type.IntegrationTest; import java.io.File; +import java.io.FileInputStream; import java.io.IOException; import org.junit.Assert; import org.junit.BeforeClass; @@ -62,6 +66,48 @@ public void simpleTextFieldTest() throws IOException, InterruptedException { runTest("simpleTextField"); } + @Test + public void textFieldWithPlaceholderTest() throws IOException, InterruptedException { + runTest("textFieldWithPlaceholder"); + } + + @Test + public void textFieldHeadersFootersTest() throws IOException, InterruptedException { + runTest("textFieldHeadersFooters"); + } + + @Test + public void textFieldHeadersFootersWithValueTest() throws IOException, InterruptedException { + runTest("textFieldHeadersFootersWithValue"); + } + + @Test + public void textAreaHeadersFootersWithValueTest() throws IOException, InterruptedException { + runTest("textAreaHeadersFooters"); + } + + @Test + public void checkBoxHeadersFootersWithValueTest() throws IOException, InterruptedException { + runTest("checkBoxHeadersFooters"); + } + + @Test + public void runningFormFieldsInHeader() throws IOException, InterruptedException { + runTest("runningFormFieldsInHeader"); + } + + @Test + public void radioHeadersFootersWithValueTest() throws IOException, InterruptedException { + runTest("radioHeadersFooters"); + } + + + @Test + public void dropDownHeadersFootersWithValueTest() throws IOException, InterruptedException { + runTest("dropDownHeadersFooters"); + } + + @Test public void splitTextFieldTest() throws IOException, InterruptedException { runTest("splitTextField"); @@ -180,6 +226,7 @@ public void radiobox1Test() throws IOException, InterruptedException { public void radiobox2Test() throws IOException, InterruptedException { runTest("radiobox2"); } + @Test @LogMessages(messages = { @LogMessage(messageTemplate = IoLogMessageConstant.MULTIPLE_VALUES_ON_A_NON_MULTISELECT_FIELD)}) @@ -233,6 +280,57 @@ public void radioButtonNoPageCounterTest() throws IOException, InterruptedExcept pdf, sourceFolder + "cmp_radioButtonNoPageCounter.pdf", destinationFolder)); } + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.IMMEDIATE_FLUSH_DISABLED, logLevel = + LogLevelConstants.INFO)}) + public void checkLogInfo() throws IOException { + String html = sourceFolder + "radiobox1.html"; + try (FileInputStream fileInputStream = new FileInputStream(html); + ByteArrayOutputStream baos = new ByteArrayOutputStream()) { + HtmlConverter.convertToPdf(fileInputStream, baos, + new ConverterProperties().setCreateAcroForm(true)); + } + } + + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.IMMEDIATE_FLUSH_DISABLED, logLevel = + LogLevelConstants.INFO, count = 0)}) + public void checkLogInfoNoAcroForm() throws IOException { + String html = sourceFolder + "radiobox1.html"; + try (FileInputStream fileInputStream = new FileInputStream(html); + ByteArrayOutputStream baos = new ByteArrayOutputStream()) { + HtmlConverter.convertToPdf(fileInputStream, baos, + new ConverterProperties().setCreateAcroForm(false)); + } + } + + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.IMMEDIATE_FLUSH_DISABLED, logLevel = + LogLevelConstants.INFO, count = 0)}) + public void checkLogInfoAcroFormFlushDisabled() throws IOException { + String html = sourceFolder + "radiobox1.html"; + try (FileInputStream fileInputStream = new FileInputStream(html); + ByteArrayOutputStream baos = new ByteArrayOutputStream()) { + HtmlConverter.convertToPdf(fileInputStream, baos, + new ConverterProperties().setCreateAcroForm(true).setImmediateFlush(false)); + } + } + + @Test + @LogMessages(messages = { + @LogMessage(messageTemplate = Html2PdfLogMessageConstant.IMMEDIATE_FLUSH_DISABLED, logLevel = + LogLevelConstants.INFO, count = 0)}) + public void checkLogInfoDefault() throws IOException { + String html = sourceFolder + "radiobox1.html"; + try (FileInputStream fileInputStream = new FileInputStream(html); + ByteArrayOutputStream baos = new ByteArrayOutputStream()) { + HtmlConverter.convertToPdf(fileInputStream, baos); + } + } + private void runTest(String name) throws IOException, InterruptedException { runTest(name, true); } @@ -248,7 +346,8 @@ private void runTest(String name, boolean flattenPdfAcroFormFields) throws IOExc String diff = "diff_" + name + "_"; HtmlConverter.convertToPdf(new File(htmlPath), new File(outPdfPath)); - HtmlConverter.convertToPdf(new File(htmlPath), new File(outAcroPdfPath), new ConverterProperties().setCreateAcroForm(true)); + HtmlConverter.convertToPdf(new File(htmlPath), new File(outAcroPdfPath), + new ConverterProperties().setCreateAcroForm(true)); if (flattenPdfAcroFormFields) { PdfDocument document = new PdfDocument(new PdfReader(outAcroPdfPath), new PdfWriter(outAcroFlattenPdfPath)); PdfAcroForm acroForm = PdfFormCreator.getAcroForm(document, false); @@ -259,7 +358,9 @@ private void runTest(String name, boolean flattenPdfAcroFormFields) throws IOExc Assert.assertNull(new CompareTool().compareByContent(outPdfPath, cmpPdfPath, destinationFolder, diff)); Assert.assertNull(new CompareTool().compareByContent(outAcroPdfPath, cmpAcroPdfPath, destinationFolder, diff)); if (flattenPdfAcroFormFields) { - Assert.assertNull(new CompareTool().compareByContent(outAcroFlattenPdfPath, cmpAcroFlattenPdfPath, destinationFolder, diff)); + Assert.assertNull( + new CompareTool().compareByContent(outAcroFlattenPdfPath, cmpAcroFlattenPdfPath, destinationFolder, + diff)); } } } diff --git a/src/test/java/com/itextpdf/html2pdf/element/TableBodyTest.java b/src/test/java/com/itextpdf/html2pdf/element/TableBodyTest.java index 114811b2b..1bc657191 100644 --- a/src/test/java/com/itextpdf/html2pdf/element/TableBodyTest.java +++ b/src/test/java/com/itextpdf/html2pdf/element/TableBodyTest.java @@ -53,4 +53,23 @@ public void transparentBackgroundOfTableBodyTest() throws IOException, Interrupt convertToPdfAndCompare("transparentBackgroundOfTableBody", SOURCE_FOLDER, DESTINATION_FOLDER); } + @Test + public void bigRowspanWithRowsSplitBetweenPages1Test() throws IOException, InterruptedException { + convertToPdfAndCompare("bigRowspanWithRowsSplitBetweenPages1", SOURCE_FOLDER, DESTINATION_FOLDER); + } + + @Test + public void bigRowspanWithRowsSplitBetweenPages2Test() throws IOException, InterruptedException { + convertToPdfAndCompare("bigRowspanWithRowsSplitBetweenPages2", SOURCE_FOLDER, DESTINATION_FOLDER); + } + + @Test + public void bigRowspanWithRowsSplitBetweenPages3Test() throws IOException, InterruptedException { + convertToPdfAndCompare("bigRowspanWithRowsSplitBetweenPages3", SOURCE_FOLDER, DESTINATION_FOLDER); + } + + @Test + public void bigRowspanWithRowsSplitBetweenPages4Test() throws IOException, InterruptedException { + convertToPdfAndCompare("bigRowspanWithRowsSplitBetweenPages4", SOURCE_FOLDER, DESTINATION_FOLDER); + } } diff --git a/src/test/java/com/itextpdf/html2pdf/element/TaggedPdfFormTest.java b/src/test/java/com/itextpdf/html2pdf/element/TaggedPdfFormTest.java index 562100cfd..e235663f8 100644 --- a/src/test/java/com/itextpdf/html2pdf/element/TaggedPdfFormTest.java +++ b/src/test/java/com/itextpdf/html2pdf/element/TaggedPdfFormTest.java @@ -126,8 +126,7 @@ public void fieldSetFormTagged() } @Test - // TODO DEVSIX-4601 - // exception is thrown on "convert tagged PDF with acroform" stage + @Ignore("DEVSIX-4601 exception is thrown on \"convert tagged PDF with acroform\" stage") public void inputFormPrematureFlush() throws IOException, InterruptedException, ParserConfigurationException, SAXException { junitExpectedException.expect(PdfException.class); diff --git a/src/test/java/com/itextpdf/html2pdf/element/TagsInsideButtonTest.java b/src/test/java/com/itextpdf/html2pdf/element/TagsInsideButtonTest.java index 24b759e24..d504d0163 100644 --- a/src/test/java/com/itextpdf/html2pdf/element/TagsInsideButtonTest.java +++ b/src/test/java/com/itextpdf/html2pdf/element/TagsInsideButtonTest.java @@ -23,8 +23,10 @@ This file is part of the iText (R) project. package com.itextpdf.html2pdf.element; import com.itextpdf.html2pdf.ExtendedHtmlConversionITextTest; -import com.itextpdf.kernel.exceptions.PdfException; import com.itextpdf.test.annotations.type.IntegrationTest; + +import java.io.IOException; +import javax.xml.parsers.ParserConfigurationException; import org.junit.BeforeClass; import org.junit.Rule; import org.junit.Test; @@ -32,9 +34,6 @@ This file is part of the iText (R) project. import org.junit.rules.ExpectedException; import org.xml.sax.SAXException; -import javax.xml.parsers.ParserConfigurationException; -import java.io.IOException; - @Category(IntegrationTest.class) public class TagsInsideButtonTest extends ExtendedHtmlConversionITextTest { @@ -87,7 +86,6 @@ public void buttonWithPInsideTagged() @Test public void buttonInsideMoreThanTwoAreas() throws IOException, InterruptedException, ParserConfigurationException, SAXException { - junitExpectedException.expect(PdfException.class); convertToPdfAcroformFlattenAndCompare("buttonInsideMoreThanTwoAreas", sourceFolder, destinationFolder, true); } diff --git a/src/test/java/com/itextpdf/html2pdf/resolver/resource/ExternalResourcesTest.java b/src/test/java/com/itextpdf/html2pdf/resolver/resource/ExternalResourcesTest.java index 489a7fe51..c7947f278 100644 --- a/src/test/java/com/itextpdf/html2pdf/resolver/resource/ExternalResourcesTest.java +++ b/src/test/java/com/itextpdf/html2pdf/resolver/resource/ExternalResourcesTest.java @@ -38,7 +38,7 @@ public void externalStylesheetTest() { ResourceResolver resourceResolver = new ResourceResolver(""); byte[] exByteArray = resourceResolver.retrieveBytesFromResource( - "https://git.itextsupport.com/projects/I7J/repos/html2pdf/browse/src/test/resources/com/itextpdf/html2pdf/styles.css"); + "https://raw.githubusercontent.com/itext/i7j-pdfhtml/develop/src/test/resources/com/itextpdf/html2pdf/styles.css"); Assert.assertNotNull(exByteArray); } diff --git a/src/test/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest.java b/src/test/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest.java index 3f6f1ec53..d51d0236d 100644 --- a/src/test/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest.java +++ b/src/test/java/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest.java @@ -36,9 +36,11 @@ This file is part of the iText (R) project. import com.itextpdf.kernel.pdf.PdfWriter; import com.itextpdf.kernel.pdf.xobject.PdfFormXObject; import com.itextpdf.kernel.utils.CompareTool; +import com.itextpdf.layout.Document; import com.itextpdf.styledxmlparser.logs.StyledXmlParserLogMessageConstant; import com.itextpdf.svg.SvgConstants; import com.itextpdf.svg.converter.SvgConverter; +import com.itextpdf.svg.element.SvgImage; import com.itextpdf.svg.exceptions.SvgExceptionMessageConstant; import com.itextpdf.svg.processors.ISvgConverterProperties; import com.itextpdf.svg.processors.ISvgProcessorResult; @@ -226,9 +228,6 @@ public void resourceResolverHtmlWithSvgDifferentLevels() throws IOException, Int } @Test - @LogMessages(messages = { - @LogMessage(messageTemplate = StyledXmlParserLogMessageConstant.UNABLE_TO_RETRIEVE_IMAGE_WITH_GIVEN_BASE_URI) - }) public void attemptToProcessBySvgProcessingUtilSvgWithImageTest() { // TODO review this test in the scope of DEVSIX-4107 String fileName = "svgWithImage.svg"; @@ -238,22 +237,19 @@ public void attemptToProcessBySvgProcessingUtilSvgWithImageTest() { ISvgConverterProperties svgConverterProperties = ContextMappingHelper.mapToSvgConverterProperties(context); ISvgProcessorResult res = SvgConverter.parseAndProcess(resourceResolver.retrieveResourceAsInputStream(fileName), svgConverterProperties); ISvgNodeRenderer imageRenderer = ((SvgTagSvgNodeRenderer) res.getRootRenderer()).getChildren().get(0); - // Remove the previous result of the resource resolving in order to demonstrate that the resource will not be - // resolved due to not setting of baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method. - imageRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "doggo.jpg"); + // Remove the previous result of the resource resolving in order to demonstrate that the resource will be + // resolved due to setting of baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method. + imageRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "res/itextpdf.com/doggo.jpg"); SvgProcessingUtil processingUtil = new SvgProcessingUtil(resourceResolver); - PdfDocument pdfDocument = new PdfDocument(new PdfWriter(new ByteArrayOutputStream())); - PdfFormXObject pdfFormXObject = processingUtil.createXObjectFromProcessingResult(res, pdfDocument); + PdfDocument document = new PdfDocument(new PdfWriter(new ByteArrayOutputStream())); + PdfFormXObject pdfFormXObject = processingUtil.createXObjectFromProcessingResult(res, document); PdfDictionary resources = (PdfDictionary) pdfFormXObject.getResources().getPdfObject().get(PdfName.XObject); PdfDictionary fm1Dict = (PdfDictionary) resources.get(new PdfName("Fm1")); - Assert.assertFalse(((PdfDictionary) fm1Dict.get(PdfName.Resources)).containsKey(PdfName.XObject)); + Assert.assertTrue(((PdfDictionary) fm1Dict.get(PdfName.Resources)).containsKey(PdfName.XObject)); } @Test - @LogMessages(messages = { - @LogMessage(messageTemplate = StyledXmlParserLogMessageConstant.UNABLE_TO_RETRIEVE_IMAGE_WITH_GIVEN_BASE_URI) - }) public void attemptToProcessBySvgProcessingUtilSvgWithSvgTest() { // TODO review this test in the scope of DEVSIX-4107 String fileName = "svgWithSvg.svg"; @@ -264,24 +260,47 @@ public void attemptToProcessBySvgProcessingUtilSvgWithSvgTest() { ISvgProcessorResult res = SvgConverter .parseAndProcess(resourceResolver.retrieveResourceAsInputStream(fileName), svgConverterProperties); ISvgNodeRenderer imageRenderer = ((SvgTagSvgNodeRenderer) res.getRootRenderer()).getChildren().get(1); - // Remove the previous result of the resource resolving in order to demonstrate that the resource will not be - // resolved due to not setting of baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method. - // But even if set baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method, the SVG will not - // be processed, because in the createXObjectFromProcessingResult method we create ResourceResolver, not HtmlResourceResolver. - imageRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "res\\itextpdf.com\\lines.svg"); + // Remove the previous result of the resource resolving in order to demonstrate that the resource will be + // resolved due to setting of baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method. + imageRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "res/itextpdf.com/lines.svg"); SvgProcessingUtil processingUtil = new SvgProcessingUtil(resourceResolver); - PdfDocument pdfDocument = new PdfDocument(new PdfWriter(new ByteArrayOutputStream())); - PdfFormXObject pdfFormXObject = processingUtil.createXObjectFromProcessingResult(res, pdfDocument); + PdfDocument document = new PdfDocument(new PdfWriter(new ByteArrayOutputStream())); + PdfFormXObject pdfFormXObject = processingUtil.createXObjectFromProcessingResult(res, document); PdfDictionary resources = (PdfDictionary) pdfFormXObject.getResources().getPdfObject().get(PdfName.XObject); PdfDictionary fm1Dict = (PdfDictionary) resources.get(new PdfName("Fm1")); - Assert.assertFalse(((PdfDictionary) fm1Dict.get(PdfName.Resources)).containsKey(PdfName.XObject)); + Assert.assertTrue(((PdfDictionary) fm1Dict.get(PdfName.Resources)).containsKey(PdfName.XObject)); + } + + @Test + public void svgInsideSvgTest() throws IOException, InterruptedException { + String svgFileName = "svgInsideSvg.svg"; + String cmpFileName = SOURCE_FOLDER + "cmp_svgInsideSvg.pdf"; + String outFileName = DESTINATION_FOLDER + "svgInsideSvg.pdf"; + + try (Document document = new Document(new PdfDocument(new PdfWriter(outFileName)))) { + ProcessorContext context = new ProcessorContext(new ConverterProperties()); + HtmlResourceResolver resourceResolver = new HtmlResourceResolver(SOURCE_FOLDER, context); + ISvgConverterProperties svgConverterProperties = ContextMappingHelper.mapToSvgConverterProperties(context); + ISvgProcessorResult result = SvgConverter.parseAndProcess( + resourceResolver.retrieveResourceAsInputStream(svgFileName), svgConverterProperties); + + ISvgNodeRenderer imageRenderer = ((SvgTagSvgNodeRenderer) result.getRootRenderer()).getChildren().get(0); + ISvgNodeRenderer svgRenderer = ((SvgTagSvgNodeRenderer) result.getRootRenderer()).getChildren().get(2); + // Remove the previous result of the resource resolving in order to demonstrate that the resource will be + // resolved due to setting of baseUri in the SvgProcessingUtil#createXObjectFromProcessingResult method. + // TODO DEVSIX-4107 However the SVG will not be displayed since it is expected to be drawn during + // HtmlResourceResolver#processAsSvg call, but document is null, so SvgProcessingUtil# + // createSvgImageFromProcessingResult method is called instead of createXObjectFromProcessingResult. + imageRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "res/itextpdf.com/doggo.jpg"); + svgRenderer.setAttribute(SvgConstants.Attributes.XLINK_HREF, "res/itextpdf.com/lines.svg"); + + document.add(new SvgProcessingUtil(resourceResolver).createSvgImageFromProcessingResult(result)); + } + Assert.assertNull(new CompareTool().compareByContent(outFileName, cmpFileName, DESTINATION_FOLDER, "diff")); } @Test - @LogMessages(messages = { - @LogMessage(messageTemplate = StyledXmlParserLogMessageConstant.UNABLE_TO_RETRIEVE_IMAGE_WITH_GIVEN_BASE_URI) - }) public void resourceResolverSvgEmbeddedSvg() throws IOException, InterruptedException { // TODO review this test in the scope of DEVSIX-4107 String outPdf = DESTINATION_FOLDER + "resourceResolverSvgEmbeddedSvg.pdf"; @@ -291,9 +310,6 @@ public void resourceResolverSvgEmbeddedSvg() throws IOException, InterruptedExce } @Test - @LogMessages(messages = { - @LogMessage(messageTemplate = StyledXmlParserLogMessageConstant.UNABLE_TO_RETRIEVE_IMAGE_WITH_GIVEN_BASE_URI) - }) public void resourceResolverObjectWithSvgEmbeddedSvg() throws IOException, InterruptedException { // TODO review this test in the scope of DEVSIX-4107 String outPdf = DESTINATION_FOLDER + "resourceResolverObjectWithSvgEmbeddedSvg.pdf"; diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Black.ttf b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Black.ttf new file mode 100644 index 000000000..6848db0d1 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Black.ttf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Hairline.ttf b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Hairline.ttf new file mode 100644 index 000000000..288be2955 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Hairline.ttf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Italic.ttf b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Italic.ttf new file mode 100644 index 000000000..3d3b7a298 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Italic.ttf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Regular.ttf b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Regular.ttf new file mode 100644 index 000000000..04ea8efb1 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/Lato-Regular.ttf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/OFL.txt b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/OFL.txt new file mode 100644 index 000000000..9f9a07e22 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/OFL.txt @@ -0,0 +1,93 @@ +Copyright (c) 2011, TypeTogether (www.type-together.com), +with Reserved Font Names "Abril" and "Abril Fatface" +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/SIL.txt b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/SIL.txt new file mode 100644 index 000000000..61ae04335 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/Lato_fonts/SIL.txt @@ -0,0 +1,40 @@ + +The Puritan font was downloaded from: +http://openfontlibrary.fontly.org/files/benweiner/3 + +This font is distrubuted under the SIL OPEN FONT LICENSE +http://scripts.sil.org/OFL + +PERMISSION & CONDITIONS + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_convertStandardFonts b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_convertStandardFonts.pdf similarity index 100% rename from src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_convertStandardFonts rename to src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_convertStandardFonts.pdf diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_differentFontFamilies.pdf b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_differentFontFamilies.pdf new file mode 100644 index 000000000..6fc8ca8ae Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/cmp_differentFontFamilies.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/differentFontFamilies.html b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/differentFontFamilies.html new file mode 100644 index 000000000..5abf5bfce --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/FontProviderTest/differentFontFamilies.html @@ -0,0 +1,20 @@ + + + + + +
+ +

This sentence should be in font Lato Black

+ +

This sentence should be in font Lato Regular

+ +

This sentence should be in font Lato Italic

+ +

This sentence should be in font Lato Hairline

+ +
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvg.pdf b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvg.pdf new file mode 100644 index 000000000..81ec0aa0c Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvg.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgImg.pdf b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgImg.pdf new file mode 100644 index 000000000..e4f476178 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgImg.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgInTheTable.pdf b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgInTheTable.pdf new file mode 100644 index 000000000..809701b8a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgInTheTable.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgObject.pdf b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgObject.pdf new file mode 100644 index 000000000..fcfd51f7a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/cmp_htmlToElementsSvgObject.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/lines.svg b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/lines.svg new file mode 100644 index 000000000..bc4ccb897 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/Html2ElementsTest/lines.svg @@ -0,0 +1,11 @@ + + + + + + + + + + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging-2.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging-2.pdf new file mode 100644 index 000000000..8c421196d Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging-2.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging.pdf new file mode 100644 index 000000000..627d46636 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-grow-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-shrink-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-shrink-paging.pdf new file mode 100644 index 000000000..6d779a295 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-flex-shrink-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-non-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-non-paging.pdf index eaad0351d..2b90c1950 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-non-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-non-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-nowrap-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-nowrap-paging.pdf new file mode 100644 index 000000000..01c16a376 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-nowrap-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-fixed-height.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-fixed-height.pdf new file mode 100644 index 000000000..09dd2ef8e Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-fixed-height.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-in-div.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-in-div.pdf new file mode 100644 index 000000000..0d8dfc0eb Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-in-div.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-center-justification.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-center-justification.pdf new file mode 100644 index 000000000..ede57f2b0 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-center-justification.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-fixed-height.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-fixed-height.pdf new file mode 100644 index 000000000..89d9def25 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-fixed-height.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-flex-end-justification.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-flex-end-justification.pdf new file mode 100644 index 000000000..04f821b33 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element-flex-end-justification.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element.pdf new file mode 100644 index 000000000..585f696da Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-large-element.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-multi-column.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-multi-column.pdf index 74ee536b0..1b34e53ff 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-multi-column.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging-multi-column.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging.pdf index a00a6f5ec..8b6e2c6c7 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-non-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-non-paging.pdf index 1d17acb6e..ce8009c89 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-non-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-non-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-large-element.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-large-element.pdf new file mode 100644 index 000000000..e6d57306e Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-large-element.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-multi-column.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-multi-column.pdf index 7c5cf14bc..98d1e6970 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-multi-column.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging-multi-column.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging.pdf index 58183979e..048c66032 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-reverse-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-wrap-reverse-non-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-wrap-reverse-non-paging.pdf index ada0470ca..ee4bfb87b 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-wrap-reverse-non-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_column-wrap-reverse-non-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_row-non-paging.pdf b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_row-non-paging.pdf index 16967bb3c..1d6f50e03 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_row-non-paging.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/cmp_row-non-paging.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging-2.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging-2.html new file mode 100644 index 000000000..1c669ac0b --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging-2.html @@ -0,0 +1,40 @@ + + + + + + +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging.html new file mode 100644 index 000000000..9c8734524 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-grow-paging.html @@ -0,0 +1,42 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-shrink-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-shrink-paging.html new file mode 100644 index 000000000..90288cd05 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-flex-shrink-paging.html @@ -0,0 +1,65 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-non-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-non-paging.html index 8bcf0de6e..fc7304605 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-non-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-non-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; max-height: 400px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-nowrap-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-nowrap-paging.html new file mode 100644 index 000000000..f071388cb --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-nowrap-paging.html @@ -0,0 +1,73 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-fixed-height.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-fixed-height.html new file mode 100644 index 000000000..06220cde5 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-fixed-height.html @@ -0,0 +1,74 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-in-div.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-in-div.html new file mode 100644 index 000000000..984deeac7 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-in-div.html @@ -0,0 +1,72 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+
+
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-center-justification.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-center-justification.html new file mode 100644 index 000000000..901d1547a --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-center-justification.html @@ -0,0 +1,43 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-fixed-height.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-fixed-height.html new file mode 100644 index 000000000..48b2a9c82 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-fixed-height.html @@ -0,0 +1,66 @@ + + + + + + +

justify-content: flex-start

+
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
+

justify-content: center

+
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
+

justify-content: flex-end

+
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-flex-end-justification.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-flex-end-justification.html new file mode 100644 index 000000000..983881f0a --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element-flex-end-justification.html @@ -0,0 +1,74 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element.html new file mode 100644 index 000000000..bac878c44 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-large-element.html @@ -0,0 +1,73 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-multi-column.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-multi-column.html index fb09e6402..945a005c9 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-multi-column.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging-multi-column.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; max-height: 2600px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging.html index 29ca9abd6..d8abbf0eb 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; } .flex-container > div { diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-non-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-non-paging.html index c287d617d..e244c0b2e 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-non-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-non-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column-reverse; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; max-height: 400px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-large-element.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-large-element.html new file mode 100644 index 000000000..645395c09 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-large-element.html @@ -0,0 +1,73 @@ + + + + + + +

Flexible Boxes Multiple pages single column layout

+ +
+
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
+
21
+
22
+
23
+
24
+
25
+
26
+
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-multi-column.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-multi-column.html index a65cdef4e..b9ef63a15 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-multi-column.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging-multi-column.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column-reverse; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; max-height: 2600px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging.html index 4614d49e4..8df22d155 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-reverse-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: column-reverse; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; } .flex-container > div { diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-wrap-reverse-non-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-wrap-reverse-non-paging.html index 3042d5a9a..c0d929ca7 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-wrap-reverse-non-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/column-wrap-reverse-non-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap-reverse; flex-direction: column; background-color: DodgerBlue; - marging: 10 px; + margin: 10px; max-height: 400px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/row-non-paging.html b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/row-non-paging.html index 8fe859d8c..69e01248c 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/row-non-paging.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/FlexPagingTest/row-non-paging.html @@ -7,7 +7,7 @@ flex-wrap: wrap; flex-direction: row; background-color: DodgerBlue; - margin: 10 px; + margin: 10px; min-height: 500px; } diff --git a/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/cmp_overflowVisibleContentShouldBeSplitBetweenPages.pdf b/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/cmp_overflowVisibleContentShouldBeSplitBetweenPages.pdf index fb255b8e0..0c08a2b87 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/cmp_overflowVisibleContentShouldBeSplitBetweenPages.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/cmp_overflowVisibleContentShouldBeSplitBetweenPages.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/overflowVisibleContentShouldBeSplitBetweenPages.html b/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/overflowVisibleContentShouldBeSplitBetweenPages.html index e95d7e04e..a193e1273 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/overflowVisibleContentShouldBeSplitBetweenPages.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/OverflowTest/overflowVisibleContentShouldBeSplitBetweenPages.html @@ -18,25 +18,25 @@ iText is a global leader in innovative award-winning PDF software. It is used by millions of users - both open source and commercial - around the world to create digital documents for a variety of purposes: invoices, credit card statements, mobile boarding passes, legal archiving and more. iText works and works well. Our customers choose iText because of our world-class quality of software, - and our reliable mature, proven technology in the iText code library iText 7 Suite. We are recognized as a global thought leader + and our reliable mature, proven technology in the iText code library iText Suite. We are recognized as a global thought leader and innovator in PDF solutions and functionalities. As an open source code library, iText PDF can be embedded into the document solution workflows of various industries and their applications. iText is a global leader in innovative award-winning PDF software. It is used by millions of users - both open source and commercial - around the world to create digital documents for a variety of purposes: invoices, credit card statements, mobile boarding passes, legal archiving and more. iText works and works well. Our customers choose iText because of our world-class quality of software, - and our reliable mature, proven technology in the iText code library iText 7 Suite. We are recognized as a global thought leader + and our reliable mature, proven technology in the iText code library iText Suite. We are recognized as a global thought leader and innovator in PDF solutions and functionalities. iText is a global leader in innovative award-winning PDF software. It is used by millions of users - both open source and commercial - around the world to create digital documents for a variety of purposes: invoices, credit card statements, mobile boarding passes, legal archiving and more. iText works and works well. Our customers choose iText because of our world-class quality of software, - and our reliable mature, proven technology in the iText code library iText 7 Suite. We are recognized as a global thought leader + and our reliable mature, proven technology in the iText code library iText Suite. We are recognized as a global thought leader and innovator in PDF solutions and functionalities. As an open source code library, iText PDF can be embedded into the document solution workflows of various industries and their applications. iText is a global leader in innovative award-winning PDF software. It is used by millions of users - both open source and commercial - around the world to create digital documents for a variety of purposes: invoices, credit card statements, mobile boarding passes, legal archiving and more. iText works and works well. Our customers choose iText because of our world-class quality of software, - and our reliable mature, proven technology in the iText code library iText 7 Suite. We are recognized as a global thought leader + and our reliable mature, proven technology in the iText code library iText Suite. We are recognized as a global thought leader and innovator in PDF solutions and functionalities. diff --git a/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest14.pdf b/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest14.pdf index b9987dd28..729bf6595 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest14.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest14.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest15.pdf b/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest15.pdf index 7233f2790..9c6c07747 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest15.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/VerticalAlignmentTest/cmp_verticalAlignmentTest15.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementAlwaysTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementAlwaysTest.pdf new file mode 100644 index 000000000..1ab11e162 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementAlwaysTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementDivAlwaysTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementDivAlwaysTest.pdf new file mode 100644 index 000000000..473e80935 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterInnerElementDivAlwaysTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageColumnTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageColumnTest.pdf new file mode 100644 index 000000000..77b584d4f Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageColumnTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageInsideColumnTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageInsideColumnTest.pdf index d5676e2ba..9e3330791 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageInsideColumnTest.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakAfterPageInsideColumnTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeAvoidTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeAvoidTest.pdf index e481640f1..748f6f48d 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeAvoidTest.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeAvoidTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementAlwaysTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementAlwaysTest.pdf new file mode 100644 index 000000000..27dd5efa0 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementAlwaysTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementDivAlwaysTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementDivAlwaysTest.pdf new file mode 100644 index 000000000..d3410dd3f Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforeInnerElementDivAlwaysTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageColumnTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageColumnTest.pdf new file mode 100644 index 000000000..8c5988922 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageColumnTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageInsideColumnTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageInsideColumnTest.pdf index 871407326..c492f1be4 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageInsideColumnTest.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakBeforePageInsideColumnTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakInsideAvoidTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakInsideAvoidTest.pdf index 7ed7ae6a2..9dbad6e62 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakInsideAvoidTest.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/cmp_pageBreakInsideAvoidTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementAlwaysTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementAlwaysTest.html new file mode 100644 index 000000000..741f5cf47 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementAlwaysTest.html @@ -0,0 +1,31 @@ + + + + +

+ Test paragraph +

+

+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus nec + lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque lacus. + Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id neque + dapibus, eu lacinia lectus dictum. +

+

+

+ Praesent condimentum dui dui, sit amet rutrum diam tincidunt eu. Cras + suscipit porta leo sit amet rutrum. Sed vehicula ornare tincidunt. + Curabitur a ipsum ac diam mattis volutpat ac ut elit. Nullam luctus justo + non vestibulum gravida. Morbi metus libero, pharetra non porttitor a, + molestie nec nisi. +

+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementDivAlwaysTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementDivAlwaysTest.html new file mode 100644 index 000000000..ccde11203 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterInnerElementDivAlwaysTest.html @@ -0,0 +1,31 @@ + + + + +

+ Test paragraph +

+
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus nec + lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque lacus. + Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id neque + dapibus, eu lacinia lectus dictum. +

+
+

+ Praesent condimentum dui dui, sit amet rutrum diam tincidunt eu. Cras + suscipit porta leo sit amet rutrum. Sed vehicula ornare tincidunt. + Curabitur a ipsum ac diam mattis volutpat ac ut elit. Nullam luctus justo + non vestibulum gravida. Morbi metus libero, pharetra non porttitor a, + molestie nec nisi. +

+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageColumnTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageColumnTest.html new file mode 100644 index 000000000..476db81f6 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageColumnTest.html @@ -0,0 +1,24 @@ + + + + +
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus + nec lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque + lacus. Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id + neque dapibus, eu lacinia lectus dictum. +

+
+
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus + nec lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque + lacus. Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id + neque dapibus, eu lacinia lectus dictum. +

+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageInsideColumnTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageInsideColumnTest.html index d4cb41599..801f9ec64 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageInsideColumnTest.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakAfterPageInsideColumnTest.html @@ -2,7 +2,7 @@ -
+

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeAvoidTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeAvoidTest.html index 23d4b1c5d..b08c859cd 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeAvoidTest.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeAvoidTest.html @@ -3,7 +3,7 @@

test block
diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementAlwaysTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementAlwaysTest.html new file mode 100644 index 000000000..53d280455 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementAlwaysTest.html @@ -0,0 +1,25 @@ + + + + +

+ Test paragraph +

+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus nec + lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque lacus. + Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id neque + dapibus, eu lacinia lectus dictum. +

+

+

+ Praesent condimentum dui dui, sit amet rutrum diam tincidunt eu. Cras + suscipit porta leo sit amet rutrum. Sed vehicula ornare tincidunt. + Curabitur a ipsum ac diam mattis volutpat ac ut elit. Nullam luctus justo + non vestibulum gravida. Morbi metus libero, pharetra non porttitor a, + molestie nec nisi. +

+

+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementDivAlwaysTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementDivAlwaysTest.html new file mode 100644 index 000000000..6e4d36000 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforeInnerElementDivAlwaysTest.html @@ -0,0 +1,25 @@ + + + + +

+ Test paragraph +

+
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus nec + lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque lacus. + Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id neque + dapibus, eu lacinia lectus dictum. +
+
+

+ Praesent condimentum dui dui, sit amet rutrum diam tincidunt eu. Cras + suscipit porta leo sit amet rutrum. Sed vehicula ornare tincidunt. + Curabitur a ipsum ac diam mattis volutpat ac ut elit. Nullam luctus justo + non vestibulum gravida. Morbi metus libero, pharetra non porttitor a, + molestie nec nisi. +

+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforePageColumnTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforePageColumnTest.html new file mode 100644 index 000000000..c92b513d8 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakBeforePageColumnTest.html @@ -0,0 +1,24 @@ + + + + +
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus + nec lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque + lacus. Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id + neque dapibus, eu lacinia lectus dictum. +

+
+
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae + fringilla mauris. Quisque commodo eget nisi sed pretium. Mauris luctus + nec lacus in ultricies. Mauris vitae hendrerit arcu, ac scelerisque + lacus. Aliquam lobortis in lacus sit amet posuere. Fusce iaculis urna id + neque dapibus, eu lacinia lectus dictum. +

+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakInsideAvoidTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakInsideAvoidTest.html index 620c022f9..f79da951b 100644 --- a/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakInsideAvoidTest.html +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/BreakTest/pageBreakInsideAvoidTest.html @@ -3,7 +3,7 @@
-

+

Test paragraph

+ + +

+
+

This is the second paragraph of the columnized div.

+

This is the third paragraph of the columnized div.

+
+
+

This is the fourth paragraph of the columnized div. This is the fourth paragraph of the columnized div.

+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childMarginTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childMarginTest.html new file mode 100644 index 000000000..d997783e9 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childMarginTest.html @@ -0,0 +1,14 @@ + + + +
+
+
+

This is the second paragraph of the columnized div.

+

This is the third paragraph of the columnized div.

+

This is the fourth paragraph of the columnized div.

+

This is the fifth paragraph of the columnized div.

+
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childPaddingTest.html b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childPaddingTest.html new file mode 100644 index 000000000..99c854b04 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/childPaddingTest.html @@ -0,0 +1,14 @@ + + + +
+
+
+

This is the second paragraph of the columnized div.

+

This is the third paragraph of the columnized div.

+

This is the fourth paragraph of the columnized div.

+

This is the fifth paragraph of the columnized div.

+
+
+ + diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childBorderTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childBorderTest.pdf new file mode 100644 index 000000000..0941f52ec Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childBorderTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childMarginTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childMarginTest.pdf new file mode 100644 index 000000000..0081c3ca3 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childMarginTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childPaddingTest.pdf b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childPaddingTest.pdf new file mode 100644 index 000000000..21688415a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/css/multicol/ColumnCountTest/cmp_childPaddingTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-block-vert-001.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-block-vert-001.pdf index 2ad6d91b9..fce1df047 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-block-vert-001.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-block-vert-001.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-fieldset-vert-001.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-fieldset-vert-001.pdf index 0d0d1a087..315878549 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-fieldset-vert-001.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-basic-fieldset-vert-001.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-definite-sizes-005.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-definite-sizes-005.pdf index d8bb9e26d..154e87067 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-definite-sizes-005.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-definite-sizes-005.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001a.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001a.pdf index 3f01a89c6..f83f6670d 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001a.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001a.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001b.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001b.pdf index 25d0dcb5c..cce5428ce 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001b.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-001b.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-002.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-002.pdf index 9e0041c01..b00d79417 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-002.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-002.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-003.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-003.pdf index a41a0cc62..559f73540 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-003.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-003.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-004.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-004.pdf index 0e1bb51f5..9e594a303 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-004.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-004.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-005.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-005.pdf index 53e7ada7a..a05f5db43 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-005.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-005.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-006.pdf b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-006.pdf index fe1af6bb3..2b23c1d49 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-006.pdf and b/src/test/resources/com/itextpdf/html2pdf/css/w3c/css_flexbox/flexbox-justify-content-vert-006.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/checkBoxHeadersFooters.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/checkBoxHeadersFooters.html new file mode 100644 index 000000000..6d4d2fab2 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/checkBoxHeadersFooters.html @@ -0,0 +1,825 @@ + + + + + + + + + + + + + + + +
+
+ + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02.pdf index 1bcb5e4e7..9fec1d6c9 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro.pdf index b359f914d..3335c2b72 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro_flatten.pdf index f54262422..9657ae7ac 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro_flatten.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit02_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03.pdf index 0451c2761..f7a1a2589 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro.pdf index 439fb3fd5..45217f860 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro_flatten.pdf index 51a646e92..7426bfbe5 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro_flatten.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_buttonSplit03_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters.pdf new file mode 100644 index 000000000..9ee7a4f1d Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro.pdf new file mode 100644 index 000000000..9f23f92c5 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro_flatten.pdf new file mode 100644 index 000000000..675365b94 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_checkBoxHeadersFooters_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters.pdf new file mode 100644 index 000000000..03716d081 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro.pdf new file mode 100644 index 000000000..224094ce8 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro_flatten.pdf new file mode 100644 index 000000000..5267622fa Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_dropDownHeadersFooters_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox.pdf new file mode 100644 index 000000000..8a84374cc Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro.pdf new file mode 100644 index 000000000..07a5d8f01 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro_flatten.pdf new file mode 100644 index 000000000..19b5f6b61 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_multiCheckBox_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonNoPageCounter.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonNoPageCounter.pdf index 3779425b9..3128e17c4 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonNoPageCounter.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonNoPageCounter.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterAtBotton.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterAtBotton.pdf index 8dd4396f0..09ff33227 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterAtBotton.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterAtBotton.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterOnTop.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterOnTop.pdf index 62e68d2e9..95b3a0e4b 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterOnTop.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioButtonWithPageCounterOnTop.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters.pdf new file mode 100644 index 000000000..f43fd7ce7 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro.pdf new file mode 100644 index 000000000..1db664bc8 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro_flatten.pdf new file mode 100644 index 000000000..beb0c7ead Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_radioHeadersFooters_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader.pdf new file mode 100644 index 000000000..9bc173d83 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro.pdf new file mode 100644 index 000000000..917fa7cb5 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro_flatten.pdf new file mode 100644 index 000000000..f3df605a7 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_runningFormFieldsInHeader_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters.pdf new file mode 100644 index 000000000..e894e7729 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro.pdf new file mode 100644 index 000000000..790a24b28 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro_flatten.pdf new file mode 100644 index 000000000..e8ec97a43 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textAreaHeadersFooters_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters.pdf new file mode 100644 index 000000000..ac96577d7 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue.pdf new file mode 100644 index 000000000..a381c9b0d Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro.pdf new file mode 100644 index 000000000..48c4981a0 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro_flatten.pdf new file mode 100644 index 000000000..03b736549 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFootersWithValue_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro.pdf new file mode 100644 index 000000000..8f5899d1e Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro_flatten.pdf new file mode 100644 index 000000000..62dcac5b2 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldHeadersFooters_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder.pdf new file mode 100644 index 000000000..6d54a8d77 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro.pdf new file mode 100644 index 000000000..733d5d51a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro_flatten.pdf new file mode 100644 index 000000000..5614a83f0 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/cmp_textFieldWithPlaceholder_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/dropDownHeadersFooters.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/dropDownHeadersFooters.html new file mode 100644 index 000000000..6036f4651 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/dropDownHeadersFooters.html @@ -0,0 +1,829 @@ + + + + + + + + + + + + + + + +
+
+ + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/radioHeadersFooters.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/radioHeadersFooters.html new file mode 100644 index 000000000..c3e19b1ba --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/radioHeadersFooters.html @@ -0,0 +1,827 @@ + + + + + + + + + + + + + + + +
+
+ + + + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/runningFormFieldsInHeader.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/runningFormFieldsInHeader.html new file mode 100644 index 000000000..44b1748f4 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/runningFormFieldsInHeader.html @@ -0,0 +1,190 @@ + + + + + + + +
+
+ + + + + + + + + + +
+
+ +

Test

+

Test

+ +

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+

Test

+ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textAreaHeadersFooters.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textAreaHeadersFooters.html new file mode 100644 index 000000000..5b9beee89 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textAreaHeadersFooters.html @@ -0,0 +1,827 @@ + + + + + + + + + + + + + + + +
+
+ + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFooters.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFooters.html new file mode 100644 index 000000000..5ca714912 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFooters.html @@ -0,0 +1,3825 @@ + + + + + + + + + + + + + + + +
+
+ + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFootersWithValue.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFootersWithValue.html new file mode 100644 index 000000000..2be639bb7 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldHeadersFootersWithValue.html @@ -0,0 +1,825 @@ + + + + + + + + + + + + + + + +
+
+ + +
+
+ +
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+
+
+
Text
+
+
+ + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldWithPlaceholder.html b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldWithPlaceholder.html new file mode 100644 index 000000000..332cdee20 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/FormTest/textFieldWithPlaceholder.html @@ -0,0 +1,9 @@ + + + +
+ + +
+ + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/ImageTest/externalUrlImage.html b/src/test/resources/com/itextpdf/html2pdf/element/ImageTest/externalUrlImage.html index b0389dafe..b7d65f325 100644 --- a/src/test/resources/com/itextpdf/html2pdf/element/ImageTest/externalUrlImage.html +++ b/src/test/resources/com/itextpdf/html2pdf/element/ImageTest/externalUrlImage.html @@ -1,6 +1,6 @@ - \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages1.html b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages1.html new file mode 100644 index 000000000..c1f039239 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages1.html @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + +
+ Overflowing cell 1.1 + + Portable Docurun in an interpreter to generate anment Format (PDF), standardized as ISO 32000, is a file format developed by Adobe in 1992 to present documents, including text formatting and images, in a manner independent of application software, hardware, and operating systems. Based on the PostScript language, each PDF file encapsulates a complete description of a fixed-layout flat document, including the text, fonts, vector graphics, raster images and other information needed to display it. PDF has its roots in "The Camelot Project" initiated by Adobe co-founder John Warnock in 1991. PDF was standardized as ISO 32000 in 2008. The last edition as ISO 32000-2:2020 was published in December 2020. PDF files may contain a variety of content besides flat text and graphics including logical structuring elements, interactive elements such as annotations and form-fields, layers, rich media (including video content), three-dimensional objects using U3D or PRC, and various other data formats. The PDF specification also provides for encryption and digital signatures, file attachments, and metadata to enable workflows requiring these features. History Main article: History of PDF Adobe Systems made the PDF specification available free of charge in 1993. In the early years PDF was popular mainly in desktop publishing workflows, and competed with a variety of formats such as DjVu, Envoy, Common Ground Digital Paper, Farallon Replica and even Adobe's own PostScript format. PDF was a proprietary format controlled by Adobe until it was released as an open standard on July 1, 2008, and published by the International Organization for Standardization as ISO 32000-1:2008, at which time control of the specification passed to an ISO Committee of volunteer industry experts. In 2008, Adobe published a Public Patent License to ISO 32000-1 granting royalty-free rights for all patents owned by Adobe that are necessary to make, use, sell, and distribute PDF-compliant implementations. PDF 1.7, the sixth edition of the PDF specification that became ISO 32000-1, includes some proprietary technologies defined only by Adobe, such as Adobe XML Forms Architecture (XFA) and JavaScript extension for Acrobat, which are referenced by ISO 32000-1 as normative and indispensable for the full implementation of the ISO 32000-1 specification. These proprietary technologies are not standardized and their specification is published only on Adobe's website. Many of them are also not supported by popular third-party implementations of PDF. In December 2020, the second edition of PDF 2.0, ISO 32000-2:2020, was published, including clarifications, corrections, and critical updates to normative references. ISO 32000-2 does not include any proprietary technologies as normative references. ISO's publication of ISO 32000-2 in 2017 ended the 24-year tradition of the latest PDF specification being freely available from Adobe. Starting in April, 2023, to provide PDF developers and stakeholders with their accustomed level of access, the PDF Association and its sponsors made ISO 32000-2 available for download at no cost. Technical details A PDF file is often a combination of vector graphics, text, and bitmap graphics. The basic types of content in a PDF are: Typeset text stored as content streams (i.e., not encoded in plain text); Vector graphics for illustrations and designs that consist of shapes and lines; Raster graphics for photographs and other types of images Multimedia objects in the document. In later PDF revisions, a PDF document can also support links (inside document or web page), forms, JavaScript (initially available as a plugin for Acrobat 3.0), or any other types of embedded contents that can be handled using plug-ins. PDF combines three technologies: An equivalent subset of the PostScript page description programming language but in declarative form, for generating the layout and graphics. A font-embedding/replacement system to allow fonts to travel with the documents. A structured storage system to bundle these elements and any associated content into a single file, with data compression where appropriate. PostScript language PostScript is a page +
+ cell 2.2 +
+ + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages2.html b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages2.html new file mode 100644 index 000000000..66f4a7c29 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages2.html @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + +
+ Overflowing cell 1.1 + + cell 1.2 +
+ cell 2.2 +
+ cell 3.2 +
+ + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages3.html b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages3.html new file mode 100644 index 000000000..08b07bd43 --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages3.html @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + +
+ Overflowing cell 1.1 + + cell 1.2 +
+ cell 2.2 +
+ cell 3.2 +
+ + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages4.html b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages4.html new file mode 100644 index 000000000..5639b3f0c --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/bigRowspanWithRowsSplitBetweenPages4.html @@ -0,0 +1,39 @@ + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + +
WorldHello
Hello
Hello
Hello
Hello
Hello
Hello
+ + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages1.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages1.pdf new file mode 100644 index 000000000..5f4f1d89c Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages1.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages2.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages2.pdf new file mode 100644 index 000000000..84b4310dc Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages2.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages3.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages3.pdf new file mode 100644 index 000000000..1502baf6b Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages3.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages4.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages4.pdf new file mode 100644 index 000000000..5f5b66cc9 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TableBodyTest/cmp_bigRowspanWithRowsSplitBetweenPages4.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TaggedPdfFormTest/cmp_inputFormPrematureFlushTagged.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TaggedPdfFormTest/cmp_inputFormPrematureFlushTagged.pdf new file mode 100644 index 000000000..f5c05f5c5 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TaggedPdfFormTest/cmp_inputFormPrematureFlushTagged.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged.pdf new file mode 100644 index 000000000..042b6b53a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro.pdf new file mode 100644 index 000000000..fa9d7eb63 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro_flatten.pdf new file mode 100644 index 000000000..2252f8d99 Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonInsideMoreThanTwoAreasTagged_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged.pdf index 568e35015..a2fd20e16 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro.pdf index 6e48755d7..c4679542c 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro_flatten.pdf index f990adf72..32a3b51a2 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro_flatten.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithImageInsideTagged_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged.pdf index c51ff2b55..462c31a38 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro.pdf index f93c9d9ec..c943c3bf2 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro_flatten.pdf b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro_flatten.pdf index 9e718d9de..e2e8ac0f3 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro_flatten.pdf and b/src/test/resources/com/itextpdf/html2pdf/element/TagsInsideButtonTest/cmp_buttonWithPInsideTagged_acro_flatten.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/events/PdfHtmlAcroformDocumentEventTest/cmp_endPageEventWithFieldTest.pdf b/src/test/resources/com/itextpdf/html2pdf/events/PdfHtmlAcroformDocumentEventTest/cmp_endPageEventWithFieldTest.pdf index bdf2f7f54..34370a3d7 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/events/PdfHtmlAcroformDocumentEventTest/cmp_endPageEventWithFieldTest.pdf and b/src/test/resources/com/itextpdf/html2pdf/events/PdfHtmlAcroformDocumentEventTest/cmp_endPageEventWithFieldTest.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverObjectWithSvgEmbeddedSvg.pdf b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverObjectWithSvgEmbeddedSvg.pdf index c5995b91a..251d9fd8e 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverObjectWithSvgEmbeddedSvg.pdf and b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverObjectWithSvgEmbeddedSvg.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverSvgEmbeddedSvg.pdf b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverSvgEmbeddedSvg.pdf index 1907dbcc9..fcecff1ae 100644 Binary files a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverSvgEmbeddedSvg.pdf and b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_resourceResolverSvgEmbeddedSvg.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_svgInsideSvg.pdf b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_svgInsideSvg.pdf new file mode 100644 index 000000000..67ba6866a Binary files /dev/null and b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/cmp_svgInsideSvg.pdf differ diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/resourceResolverSvgEmbeddedImage.html b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/resourceResolverSvgEmbeddedImage.html index 1f740cab0..da1170249 100644 --- a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/resourceResolverSvgEmbeddedImage.html +++ b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/resourceResolverSvgEmbeddedImage.html @@ -2,12 +2,12 @@
- doggo + doggo
- + diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgInsideSvg.svg b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgInsideSvg.svg new file mode 100644 index 000000000..52e60b6df --- /dev/null +++ b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgInsideSvg.svg @@ -0,0 +1,6 @@ + + + + + diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithImage.svg b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithImage.svg index 78fa83bff..6a5568261 100644 --- a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithImage.svg +++ b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithImage.svg @@ -1,4 +1,4 @@ - + \ No newline at end of file diff --git a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithSvg.svg b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithSvg.svg index 7950758a9..59b0ad2fc 100644 --- a/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithSvg.svg +++ b/src/test/resources/com/itextpdf/html2pdf/resolver/resource/HtmlResourceResolverTest/svgWithSvg.svg @@ -1,4 +1,4 @@ - + \ No newline at end of file