FO is an XML format that describes paged documents. An FO processor, such as the Apache XML Project's FOP, takes an FO file as input and generates PDF as output. The production of a PDF document from an XML document is, therefore, a two-step process.
|1.||The XML document is transformed to an FO document using an XSLT stylesheet.|
|2.||The FO document is processed by an FO processor to generate PDF (or some alternative output).|
The XSL/XQuery | XSL:FO Transformation command transforms an XML document or an FO document to PDF.
•If the XSL:FO Transformation command is executed on a source XML document, then both of the steps listed above are executed, in sequence, one after the other. If the XSLT stylesheet required to transform to FO is not referenced in the XML document, you are prompted to assign one for the transformation. Note that you can also select a file via a global resource or a URL (click the Browse button) or a file in one of the open windows in Authentic Desktop (click the Window button). The transformation from XML to XSL-FO is carried out by the XSLT processor specified in the XSL section of the Options dialog (Tools | Options). By default the selected XSLT processor is Authentic Desktop's built-in XSLT processor. The resultant FO document is directly processed with the FO processor specified in the XSL section of the Options dialog (Tools | Options).
•If the XSL:FO Transformation command is executed on an FO document, then the document is processed with the FO processor specified in the XSL section of the Options dialog (Tools | Options).
XSL:FO Transformation output
The XSL:FO Transformation command pops up the Choose XSL:FO Output dialog (screenshot below). (If the active document is an XML document without an XSLT assignment, you are first prompted for an XSLT file.)
You can view the output of the FO processor directly on screen using FOP viewer or you can generate an output file in any one of the following formats: PDF, text, an XML area tree, MIF PCL, or PostScript. You can also switch on messages from the FO processor to show (i) the processor's standard output message in the Messages window; and (ii) the processor's error messages in the Messages window. To switch on either these two options, check the appropriate check box at the bottom of the dialog.
•Unless you deselected the option to install the FOP processor of the Apache XML Project, it will have been installed in the folder C:\ProgramData\Altova\SharedBetweenVersions. If installed, the path to it wil automatically have been entered in the XSL section of the Options dialog (Tools | Options) as the FO processor to use. You can set the path to any FO processor you wish to use.
•The XSL:FO Transformation command can not only be used on the active file in the Main Window but also on any file or folder you select in the active project. To do this, right-click and select XSL:FO Transformation. The XSLT stylesheet assigned to the selected project folder is used.