Managing the Settings of an Output Template

You can manage a number of settings that will apply to all documents generated from the current output template. To edit those settings, click the gear icon next to the template name in the Template Panel. 

Click the gear icon to open the template settings

Output template settings

PDF Standard

Set the PDF standard that your output documents will comply with. iText DITO supports these standards:

  • PDF: the regular PDF specification
  • PDF/UA: the Universal Accessibility specification for PDF documents. Documents that comply with this standard are "accessible" as defined by the PDF/UA standard. That means that they are set up to support assistive technology like screen readers. iText DITO has a PDF/UA Compliance Assistant that helps you comply with the standard. 

Title

The title will be written in the title tag of your output documents. Many PDF readers and browsers will display this title, typically at the top of the window. The title can be set as a static or a dynamic value:

  • Static Title - If you select this option the tile will be a constant value that is identical for all documents produced
  • Title from data - If you select this option the title is based on a field value from your data set, for instance the name of the customer. Click the ellipsis button to bind the title to a field from your data set.  

If the template is set up to comply with the PDF/UA standard, title is a required field.

Language

In the language field you can select the main language of the document. This setting is helpful for assistive technology like screen readers. The language can be set statically or dynamically:

  • Predefined language - select the main language of the resulting PDF documents from a list of languages
  • Language from data - you can bind the selection of the document language to the value of a field in the data set. A typical use case would be a template that contains conditional content in more than one language, the language that is displayed depends on a field that indicates the language of the intended recipient. Dynamic values should be formatted as a two-digit locale code or a locale code and a country code joined together with a hyphen (e.g. 'en' or 'en-US'). 

If the template is set up to comply with the PDF/UA standard, language is a required field.

Page Size and Orientation

The page size setting defines the dimensions of each pages in the resulting PDF documents. Page sizes can be defined by selecting a common page format from the drop-down, or by setting custom values for width and height (supported units).  

You can also define page orientation to be portrait or landscape.

Using custom CSS, you can set different page sizes for the first page, the left pages or the right pages of your template. The below example will set the height of the first page to 600 points and the width of the first page to 400 points.

@page:first {
size: 600pt 400pt;
}

Margin

Set the margins for the documents that will be created using the current template (supported units). Margins can be edited individually or collectively.

Managing the Settings of an Input Template

You can manage a number of settings for input templates. These settings will apply to html forms generated from the template. To open the template settings dialog, click the gear icon next to the input template name in the Templates panel. 

Click the gear icon to open the input template settings

input template settings

Title

The title will be the name of the html page that will hold the form. Browsers will typically display this title at the top of the window. The title can be set as a static or a dynamic value:

  • Static Title - If you select this option the tile will be a constant value that is identical for all HTML forms produced;
  • Title from data - If you select this option the title is based on a field value from your data set, for instance the name of the customer. Click the ellipsis button to bind the title to a field from your data set. 

Language

In the language field you can select the main language of html form. This setting is helpful for assistive technology like screen readers. The language can be set statically or dynamically:

  • Predefined language - select the main language of the web form from a predefined list of languages
  • Language from data - you can bind the selection of the document language to the value of a field in the data set. Dynamic values should be formatted as a two-digit locale code or a locale code and a country code joined together with a hyphen (e.g. 'en' or 'en-US').