Presentation The  XML  Forms  Architecture


In PDF, there are interactive forms and there are interactive forms. There are many tools that support the AcroForm technology to create templates with form fields that can be filled in manually or programmatically. The coordinates of these fields are fixed: all the data needs to fit into predefined rectangles on predefined pages. With the XML Forms Architecture (XFA), you can define fields in a more dynamic way. You can create repeatable subforms that allow the document to adapt to the amount of data that is entered. In this talk, we'll focus on using XFA forms as a template.
Published on: 2012-05-07T12:44:58.000Z
Channel: iText Summit 2012 (all)
Tags: forms Acroform xml itext
Speakers:

Bruno Lowagie


Bruno is the original developer and current maintainer of iText. He's also the author of the two "iText in Action" books, and the CEO/CTO of the iText companies.

PDF: slides.pdf

Slides:

iText Summit 2012 The  XML  Forms  Architecture


The XML Forms Architecture Bruno Lowagie

XML Forms Architecture


XML Forms Architecture Document defined in XML Template: appearance of the form Datasets: data and data description Rendered on-the-fly in the viewer The Portable Document Format is used: as the container of the XML stream for the backgrounds of the form -

PDF versus XFA


PDF versus XFA Pro XML based You can use your own schema Easy to extract/exchange data Contra XML based Slow rendering for large docs XML manipulation Dynamic document Data shapes document Variable number of pages Slow adoption by viewers Adobe Reader Preview Functionality (vs AcroForm) More flexibility More feature rich Not many tools available Adobe LiveCycle Merging, splitting,... Problem: continuity?

Let's start with XML


Extensible Markup Language (XML) is a set of rules for encoding documents in machine-readable form. Hundreds of XML-based languages have been developed, including RSS, Atom, SOAP, SVG, XHTML,...

iText before XML Worker


iText before XML Worker XmlParser with a custom iText DTD. Why invent a new standard? XmlPeer classes for custom tags. Good idea, but nobody understood how it works Writing your own DocumentHandler. Not for the faint of heart Using HTMLWorker. Organically grown functionality; dito frustration These are things of the past!

Understanding XML Worker


Understanding XML Worker Different pipelines In the case of XHTML: CSS HTML pipeline pipeline In the case of custom XML: Custom pipeline PDF pipeline PDF pipeline

Live Demo: parsing XML with iText


Live Demo PARSING XML WITH ITEXT

Live Demo: combining XML worker with Acroform Technology


Live Demo COMBINING XML WORKER WITH ACROFORM TECHNOLOGY

Creating an XFA form


Creating an XFA form

Importing an XSD


Importing an XSD

Reorganizing the fields


Reorganizing the fields

Importing an XSD


Importing an XSD

An empty form


An empty form

A filled out form


A filled out form

Live Demo: filling out XFA forms


Live Demo FILLING OUT XFA FORMS

Try it yourself!


Try it yourself! Useful links: http://demo.itextsupport.com/ xfademo/ http://www.youtube.com/ watch?v=qxtAy2Czsh0

On our roadmap


On our roadmap Development based on customer feedback Support for field formatting Support for JavaScript Make a first official release