Layout
This command is the root element in the Layout instructions.
Child elements
AddSearchpath, AttachFile, Compatibility, DefineColor, DefineColorprofile, DefineFontalias, DefineFontfamily, DefineGraphic, DefineMatter, DefineTextformat, Function, Hyphenation, LoadFontfile, Loop, Message, Options, PDFOptions, Pageformat, Pagetype, PlaceObject, Record, Section, SetGrid, SetVariable, StructureElement, Stylesheet, Switch, Trace, While
Parent elements
AtPageCreation, AtPageShipout, Case, Contents, ForAll, Loop, Otherwise, Record, SavePages, Until, While
Attributes
defaults(text, optional, since version 5.9.5)- Selects the behavior defaults of the given publisher version, in the format major.minor (for example
6.0) or the keywordlatestfor the current version. Behavior changes that become the standard in a later version can be switched on this way before upgrading, for example the interword space taken from the font (standard with version 6.0). Individual settings such as the attributes atCompatibilitytake precedence. Only the root element of the main layout file is taken into account. If the requested version is newer than the publisher, a warning is given. name(text, optional)- A name for the layout. Optional, without any influence on the layout itself.
require(text, optional, since version 4.15.10)- A comma separated list of required default features. The features
lxpathandharfbuzzare accepted for compatibility and have no effect, they are always active. The featuresluxorandfontforgehave been removed in version 6.0 and raise an error. version(number, optional)- Minimum publisher version required. If major or minor version differ, give a warning. Format: 1.6.12 (revision number can be left out).
Example
This is a complete example for a layout rule set. The first part is the data file (save as data.xml) and the second the layout instructions (layout.xml).
<root>
<elt greeting="Hello world!" />
</root>
<Layout xmlns="urn:speedata.de:2009/publisher/en"
xmlns:sd="urn:speedata:2009/publisher/functions/en">
<Options mainlanguage="English (USA)"/>
<Record element="root">
<ProcessNode select="elt"/>
</Record>
<Record element="elt">
<PlaceObject>
<Textblock>
<Paragraph>
<Value select="@greeting"></Value>
</Paragraph>
</Textblock>
</PlaceObject>
</Record>
</Layout>