Created on: Oct 5, 2016 Author: Alberto Nicoletti This XSLT document allows the conversion of any DOCX document into RASH. This template is in charge of starting the transformation. This template is in charge of creating the whole structure of the document in RASH. <!DOCTYPE html> This template is in charge of handling common paragraphs. This template handles all the inline textual elements that appear in the context of a paragraph, excluding links. This template handles all the inline external (i.e., to an external website) links that appear in the context of a paragraph, excluding links. This template is used for avoiding to process certain elements. This template creates all the references to dereferanceable objects in the document content (i.e., sections, figures with caption, formulas with caption, and tables).

This template creates new table boxes.
This template creates table rows. This template creates new table heading cells. This template handles all text nodes and, in case there is an inline quotation, it adds the appropriate element to the RASH document. This template is in charge of handling common paragraphs.

This template is in charge of handling a cited paragraph.

This named template is in charge of creating captions to figures or tables.
No caption has been provided.
This template is in charge of handling a sequence of paragraph that defines a block of code.

                
                    

                    
                
            
This template is in charge of creating the listing boxes.

                
                    
                        
                    
                    
                        
                        

                    
                
            
This named template is in charge of adding a captioned image to the document.

This named template is in charge of adding an inline image to the document. {if (string-length($alt) > 0) then $alt else 'No alternate description has been provided.'} This template is in charge of handling lists.
This template is in charge of handling lists.
This template handles the list items
  • doc-biblioentry

  • This template is in charge of handling references to footnotes. This named template is in charge of handling the head data of the document, i.e., authors, emails, affiliations, keywords, categories. This named template is in change of handling all the footnotes contained in the paper.
    This named template allow one to get all the content elements after the first one. Since this particular sequence of element is used by different templates (e.g., for headings), the call has been implemented as a named template. This named template is in change of handling all the inline textual elements that may appear within a paragraph. The links are handled in another appropriate template. <xsl:choose> <xsl:when test="normalize-space($title) != ''"> <xsl:value-of select="$title" /> <xsl:if test="normalize-space($subtitle) != ''"> <xsl:text> -- </xsl:text> <xsl:value-of select="$subtitle" /> </xsl:if> </xsl:when> <xsl:otherwise> <xsl:text>No title specified</xsl:text> </xsl:otherwise> </xsl:choose> This named template set the type of a section if any ('section' is the default). This named template creates the section according the particular heading in consideration.

    This named template creates a new section with no heading and containing the paragraph in consideration.

    No heading specified

    This named template set the id of a bookmarked object (i.e., section and references) if present. This named template set the id of a captioned object (i.e., a figure, a formula, a table) if present. This function says whether or not a given element is a Ref. This function says whether or not a given w:r is inside a Ref. This function says whether or not a given element is a code paragraph. This function returns the type (bullet or decimal) of a list given its ID. This function says whether or not a list element is bulleted. If it isn't bulleted then it's numbered. This function returns the elements contained in a given element. This function returns the following elements which are w:r or w:hyperlinks. This function returns the preceding elements which are w:r or w:hyperlinks. This function retrieves the level of a particular logic section of a paper starting from its header element. This function checks if a certain paragraph is an header or not. This function returns the localized (in the language of your Word installation) name of a given element. This function returns the style name of a given element. This function says whether or not a particular paragraph is marked as preformatted. This function says whether or not a paragraph is contained in a list. This function says whether or not a paragraph is contained in a list. This function says whether or not an element is a reference to a footnote. This function says whether or not a paragraph is a listing box. This function returns the elements of a list given its first element. Return whether or not an element is the first item of a list. This function says whether or not a paragraph is after a list item. Return whether or not a w:p element is a caption. Return whether an element contains an image. Return an image filename given its ID. Return whether or not an element contains w:t elements in its descendings. Return whether or not a node contains a number in its descending text nodes. This functions given a paragraph returns the nodes containing its caption. Should be used only by getCaptionText. This function given a paragraph returns its caption. This function returns a sequence of text nodes split by means of double quotations. Returns the string contained in the given nodes.