### XLIFF 2.2 with ITS Annotations Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-extended-v2.2-csd02-part2.html This example demonstrates a basic XLIFF 2.2 file structure with ITS annotations for localization quality issues and provenance records. ```xml Check with terminology engineer Text Text in the domain domain1 Text text This is the content c'esle contenu Some text and a term Du texte et un terme Arizona This is a motherboard. Text with a term. Span of text en français. ``` -------------------------------- ### XLIFF 2.2 dataRefStart and dataRefEnd Attributes Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Illustrates the use of 'dataRefStart' and 'dataRefEnd' attributes to reference original data for the start and end markers of an inline element. ```xml <EM> </EM> Efficiency is the operative word here. Efficacité est le mot clé ici. ``` -------------------------------- ### XLIFF Rule: String Must Start With Specific Value Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-extended-v2.2-csd02-part2.html Use the `startsWith` attribute to enforce that the target text begins with a specific string. This example validates that the target starts with '*'. ```xml *Choose an option in the online store. *Escolha uma opção na loja online. ``` -------------------------------- ### Using Experimental Website Stylesheet Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/docbook/xsl/RELEASE-NOTES.html Demonstrates how to process Website documents using the experimental tabular.xsl driver file from the DocBook XSL package. ```text http://docbook.sourceforge.net/release/xsl/current/website/tabular.xsl ``` -------------------------------- ### XLIFF 2.2 Spanning Original Code Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Demonstrates the usage of the 'sc' element to mark the start of a spanning original code segment within an XLIFF unit. This example shows how 'sc' and 'ec' elements are used to enclose text that represents a formatted code element. ```xml First sentence. Second sentence. ``` -------------------------------- ### Example of pc element with dataRef Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Demonstrates the usage of the element for spanning original code, referencing data using dataRefStart and dataRefEnd attributes. ```xml <B> </B> Important text ``` -------------------------------- ### XLIFF 2.2 Isolated Attribute Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Demonstrates the use of the 'isolated' attribute on elements to indicate when start or end markers are not in the same as their corresponding codes. ```xml Warning: Attention : Warning: File not found. ``` -------------------------------- ### Importing and Including New Indexing Stylesheet Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/docbook/xsl/RELEASE-NOTES.txt This example shows how to import a base stylesheet and include the new indexing stylesheet in a customization layer to enable the alternative indexing mechanism with better internationalization support. ```XSLT ``` -------------------------------- ### Term Annotation Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Demonstrates how to use the 'term' annotation to mark a specific term within the source content and associate a reference to it. ```XML He is my doppelgänger. ``` -------------------------------- ### XLIFF 2.2 Unit with Source and Inline Codes Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Example demonstrating the use of (start code) and (end code) elements within a element to represent inline formatting like bold and italics. The 'dataRef' attribute links to the original data. ```xml \b \i \b0 \i0 Text in bold and italics. ``` -------------------------------- ### Orphan Start Marker of Spanning Code in XLIFF Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-extended-v2.2-csd02-part2.html Represents an orphaned start marker of a spanning code in XLIFF. This indicates that the start marker exists without a corresponding end marker within the same context. ```xml ``` -------------------------------- ### Inline Simplelist Output Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/docbook/xsl/RELEASE-NOTES.html Illustrates the expected output for an inline simplelist with a generated choice separator, as processed for English. ```text > Choose from ONE and only ONE of the following choices: A, B, or C. ``` -------------------------------- ### Example: Extracting Domain at Structural Levels Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-extended-v2.2-csd01-part2.html Demonstrates how the Domain data category can be extracted at structural levels in an HTML document and represented in an XLIFF extraction. ```html Data Category: Domain

Text in the domain domain1

``` -------------------------------- ### XLIFF 2.2 startRef Attribute Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html Illustrates the use of the 'startRef' attribute in elements to link them to their corresponding elements, defining text formatting. ```xml Bold, both , italics ``` -------------------------------- ### XLIFF 2.2 Document Example Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-core-v2.2-csd03-part1.html An example of an XLIFF 2.2 document containing a file with a unit, segment, source, and target. This structure is typical for localization workflows. ```xml note for file. data note for unit Hello World! Bonjour le Monde ! ``` -------------------------------- ### Running DocBook XSL with Saxon and Custom Options Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/docbook/xsl/RELEASE-NOTES.txt This command demonstrates how to run DocBook XSL using Saxon with specific Java system properties for encoding, XML parsers, and transformers. It's useful for complex transformations requiring custom configurations. ```bash java \ -Dencoding.windows-1252=com.nwalsh.saxon.Windows1252 \ -Djavax.xml.parsers.DocumentBuilderFactory=org.apache.xerces.jaxp.DocumentBuilderFactoryImpl \ -Djavax.xml.parsers.SAXParserFactory=org.apache.xerces.jaxp.SAXParserFactoryImpl \ -Djavax.xml.transform.TransformerFactory=com.icl.saxon.TransformerFactoryImpl \ com.icl.saxon.StyleSheet \ -x org.apache.xml.resolver.tools.ResolvingXMLReader \ -y org.apache.xml.resolver.tools.ResolvingXMLReader \ -r org.apache.xml.resolver.tools.CatalogResolver \ mydoc.xml mystylesheet.xsl ``` -------------------------------- ### Start Marker of Spanning Code in XLIFF Source: https://github.com/oasis-tcs/xliff-xliff-22/blob/master/xliff-22/xliff-extended-v2.2-csd02-part2.html Represents the start marker of a spanning code in XLIFF. This is used when a code begins within a segment but may end in another. ```xml ```