Skip to content

Commit

Permalink
Added additional value 'dclp' to leiden-style parameter in global-par…
Browse files Browse the repository at this point in the history
…ameters.xml. Added 'dclp' to all leiden-style parameters with value ='ddbdp' and to supplied-parallel template. DCLP/dclpxsltbox#283
  • Loading branch information
wsalesky committed Aug 5, 2017
1 parent b28313a commit 1f98648
Show file tree
Hide file tree
Showing 34 changed files with 72 additions and 71 deletions.
1 change: 1 addition & 0 deletions global-parameters.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<parameter>
<name>leiden-style</name>
<value>ddbdp</value>
<value>dclp</value>
<value>dohnicht</value>
<value>edh-itx</value>
<value>edh-names</value>
Expand Down
4 changes: 2 additions & 2 deletions htm-teiab.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@
<xsl:text>-</xsl:text>
</xsl:if>
<!-- if final lb in ab is L2R or R2L, then print arrow here -->
<xsl:if test="not($parm-leiden-style=('ddbdp','sammelbuch'))
<xsl:if test="not($parm-leiden-style=('ddbdp','dclp','sammelbuch'))
and descendant::t:lb[last()][@rend='left-to-right']">
<xsl:text>&#xa0;&#xa0;→</xsl:text>
</xsl:if>
<xsl:if test="not($parm-leiden-style=('ddbdp','sammelbuch'))
<xsl:if test="not($parm-leiden-style=('ddbdp','dclp','sammelbuch'))
and descendant::t:lb[last()][@rend='right-to-left']">
<xsl:text>&#xa0;&#xa0;←</xsl:text>
</xsl:if>
Expand Down
2 changes: 1 addition & 1 deletion htm-teiaddanddel.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<xsl:template match="t:add">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and @place='interlinear'">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and @place='interlinear'">
<span style="font-size:smaller;">
<xsl:apply-imports/>
</span>
Expand Down
8 changes: 4 additions & 4 deletions htm-teiapp.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:param name="parm-hgv-gloss" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch') and ancestor::t:div[@type='translation']">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch') and ancestor::t:div[@type='translation']">
<xsl:variable name="wit-val" select="@resp"/>
<xsl:variable name="lang" select="ancestor::t:div[@type = 'translation']/@xml:lang"/>
<span class="term">
Expand Down Expand Up @@ -97,12 +97,12 @@
</span>
</span>
</xsl:when>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch') and ancestor::t:*[local-name()=('reg','corr','rdg')
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch') and ancestor::t:*[local-name()=('reg','corr','rdg')
or self::t:del[@rend='corrected']]">
<xsl:apply-templates/>
<xsl:if test="@resp">
<xsl:choose>
<xsl:when test="$parm-leiden-style='ddbdp'"><xsl:text> FNORD-SPLIT </xsl:text></xsl:when>
<xsl:when test="$parm-leiden-style=('ddbdp','dclp')"><xsl:text> FNORD-SPLIT </xsl:text></xsl:when>
<xsl:otherwise><xsl:text> </xsl:text></xsl:otherwise>
</xsl:choose>
<xsl:if test="parent::t:app[@type='BL']">
Expand All @@ -115,7 +115,7 @@
<xsl:text> (via PE)</xsl:text>
</xsl:if>
<xsl:choose>
<xsl:when test="$parm-leiden-style='ddbdp'"><xsl:text> FNORD-DELIM </xsl:text></xsl:when>
<xsl:when test="$parm-leiden-style=('ddbdp','dclp')"><xsl:text> FNORD-DELIM </xsl:text></xsl:when>
<xsl:otherwise><xsl:text> </xsl:text></xsl:otherwise>
</xsl:choose>
</xsl:if>
Expand Down
2 changes: 1 addition & 1 deletion htm-teidivedition.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<span class="textpartnumber" id="{$div-type}ab{$div-loc}{@n}">
<!-- add ancestor textparts -->
<xsl:if
test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and @subtype">
test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and @subtype">
<xsl:value-of select="@subtype"/>
<xsl:text> </xsl:text>
</xsl:if>
Expand Down
2 changes: 1 addition & 1 deletion htm-teifigure.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<xsl:apply-templates/>
</a>
</xsl:when>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch')">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch')">
<xsl:text>(</xsl:text>
<xsl:apply-templates/>
<xsl:text>)</xsl:text>
Expand Down
2 changes: 1 addition & 1 deletion htm-teig.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

<xsl:choose>
<xsl:when test="starts-with($parm-leiden-style, 'edh')"/>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<!-- Found in teig.xsl -->
<xsl:call-template name="g-ddbdp"/>
</xsl:when>
Expand Down
2 changes: 1 addition & 1 deletion htm-teigap.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<xsl:template match="t:gap[@reason = 'lost']">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:if test="@extent='unknown' and @reason='lost' and @unit='line' and ($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')
<xsl:if test="@extent='unknown' and @reason='lost' and @unit='line' and ($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))
and not(preceding-sibling::t:*[1][local-name() = 'lb'])">
<!-- adds a newline character before gap-extent-line in DDbDP unless <lb/> present -->
<br/>
Expand Down
2 changes: 1 addition & 1 deletion htm-teihead.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<xsl:template match="t:body/t:head">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when test="$parm-leiden-style='ddbdp'">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp')">
<xsl:element name="p">
<xsl:apply-templates/>
</xsl:element>
Expand Down
4 changes: 2 additions & 2 deletions htm-teihi.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<xsl:when test="@rend='subscript'">
<xsl:choose>
<xsl:when test="$parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch'">
<xsl:when test="$parm-leiden-style = ('ddbdp','dclp','sammelbuch')">
<span style="vertical-align:sub;">
<xsl:apply-imports/>
</span>
Expand All @@ -136,7 +136,7 @@
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<xsl:when test="@rend='superscript'">
<xsl:choose>
<xsl:when test="$parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch'">
<xsl:when test="$parm-leiden-style = ('ddbdp','dclp','sammelbuch')">
<span style="vertical-align:super;">
<xsl:apply-imports/>
</span>
Expand Down
20 changes: 10 additions & 10 deletions htm-teilb.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@
<xsl:when
test="generate-id(self::t:lb) = generate-id(ancestor::t:div[1]/t:*[child::t:lb][1]/t:lb[1])"/>
<xsl:when
test="$parm-leiden-style = 'ddbdp' and ((not(ancestor::*[name() = 'TEI'])) or $location = 'apparatus')"/>
test="$parm-leiden-style = ('ddbdp','dclp') and ((not(ancestor::*[name() = 'TEI'])) or $location = 'apparatus')"/>
<!-- *or unless* the second part of an app in ddbdp -->
<xsl:when
test="
($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and
($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and
(ancestor::t:corr or ancestor::t:reg or ancestor::t:rdg or ancestor::t:del[parent::t:subst])"/>
<!-- *unless* previous line ends with space / g / supplied[reason=lost] -->
<!-- in which case the hyphen will be inserted before the space/g r final ']' of supplied
Expand All @@ -72,14 +72,14 @@
<!-- arrows after final line handled in htm-teiab.xsl -->
<xsl:if
test="
not($parm-leiden-style = ('ddbdp', 'sammelbuch'))
not($parm-leiden-style = ('ddbdp','dclp', 'sammelbuch'))
and not(position() = 1)
and preceding::t:lb[1][@rend = 'left-to-right']">
<xsl:text>&#xa0;&#xa0;→</xsl:text>
</xsl:if>
<xsl:if
test="
not($parm-leiden-style = ('ddbdp', 'sammelbuch'))
not($parm-leiden-style = ('ddbdp', 'dclp','sammelbuch'))
and not(position() = 1)
and preceding::t:lb[1][@rend = 'right-to-left']">
<xsl:text>&#xa0;&#xa0;←</xsl:text>
Expand Down Expand Up @@ -111,7 +111,7 @@
</xsl:when>
-->
<xsl:when
test="$parm-leiden-style = 'ddbdp' and ((not(ancestor::*[name() = 'TEI'])) or $location = 'apparatus')">
test="$parm-leiden-style = ('ddbdp','dclp') and ((not(ancestor::*[name() = 'TEI'])) or $location = 'apparatus')">
<xsl:choose>
<xsl:when test="@break = 'no' or @type = 'inWord'">
<xsl:text>|</xsl:text>
Expand All @@ -137,26 +137,26 @@
<xsl:choose>
<xsl:when test="$location = 'apparatus'"/>
<xsl:when
test="not(number(@n)) and ($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
test="not(number(@n)) and ($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<!-- non-numerical line-nos always printed in DDbDP -->
<xsl:call-template name="margin-num"/>
</xsl:when>
<xsl:when
test="
number(@n) and @n mod number($parm-line-inc) = 0 and not(@n = 0) and
not(following::t:*[1][local-name() = 'gap' or local-name() = 'space'][@unit = 'line'] and
($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch'))">
($parm-leiden-style = ('ddbdp','dclp','sammelbuch')))">
<!-- prints line-nos divisible by stated increment, unless zero
and unless it is a gap line or vacat in DDbDP -->
<xsl:call-template name="margin-num"/>
</xsl:when>
<xsl:when
test="$parm-leiden-style = 'ddbdp' and preceding-sibling::t:*[1][local-name() = 'gap'][@unit = 'line']">
test="$parm-leiden-style = ('ddbdp','dclp') and preceding-sibling::t:*[1][local-name() = 'gap'][@unit = 'line']">
<!-- always print line-no after gap line in ddbdp -->
<xsl:call-template name="margin-num"/>
</xsl:when>
<xsl:when
test="$parm-leiden-style = 'ddbdp' and following::t:lb[1][ancestor::t:reg[following-sibling::t:orig[not(descendant::t:lb)]]]">
test="$parm-leiden-style = ('ddbdp','dclp') and following::t:lb[1][ancestor::t:reg[following-sibling::t:orig[not(descendant::t:lb)]]]">
<!-- always print line-no when broken orig in line, in ddbdp -->
<xsl:call-template name="margin-num"/>
</xsl:when>
Expand All @@ -170,7 +170,7 @@
<span>
<xsl:choose>
<xsl:when
test="$parm-leiden-style = 'ddbdp' and following::t:lb[1][ancestor::t:reg[following-sibling::t:orig[not(descendant::t:lb)]]]">
test="$parm-leiden-style = ('ddbdp','dclp') and following::t:lb[1][ancestor::t:reg[following-sibling::t:orig[not(descendant::t:lb)]]]">
<xsl:attribute name="class">
<xsl:text>linenumberbroken</xsl:text>
</xsl:attribute>
Expand Down
4 changes: 2 additions & 2 deletions htm-teimilestone.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<xsl:choose>
<xsl:when
test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and ancestor::t:div[@type = 'translation']">
test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and ancestor::t:div[@type = 'translation']">
<xsl:if test="@rend = 'break'">
<br/>
</xsl:if>
Expand All @@ -22,7 +22,7 @@
</sup>
<xsl:text> </xsl:text>
</xsl:when>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<xsl:choose>
<xsl:when test="@rend = 'wavy-line'">
<xsl:if test="not(parent::t:supplied)">
Expand Down
2 changes: 1 addition & 1 deletion htm-teinum.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when
test="$parm-leiden-style=('ddbdp','sammelbuch')
test="$parm-leiden-style=('ddbdp','dclp','sammelbuch')
and string(.)">
<span>
<xsl:attribute name="title">
Expand Down
2 changes: 1 addition & 1 deletion htm-teisupplied.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

<xsl:template name="supplied-parallel">
<xsl:choose>
<xsl:when test="$collection = 'dclp'">⎣<xsl:apply-templates/>⎦</xsl:when>
<xsl:when test="$leiden-style = 'dclp'">⎣<xsl:apply-templates/>⎦</xsl:when>
<xsl:otherwise><span class="underline"><xsl:apply-templates/></span></xsl:otherwise>
</xsl:choose>

Expand Down
2 changes: 1 addition & 1 deletion htm-teiterm.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<!-- Adds caption for hgv translations -->
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and ancestor::t:div[@type = 'translation'] and @target">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and ancestor::t:div[@type = 'translation'] and @target">
<xsl:variable name="lang" select="ancestor::t:div[@type = 'translation']/@xml:lang"/>
<xsl:variable name="term" select="@target"/>

Expand Down
2 changes: 1 addition & 1 deletion htm-tpl-struct-hgv.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<body>

<!-- Heading for a ddb style file -->
<xsl:if test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:if test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<h1>
<xsl:choose>
<xsl:when test="//t:sourceDesc//t:bibl/text()">
Expand Down
4 changes: 2 additions & 2 deletions htm-tpl-structure.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<head>
<title>
<xsl:choose>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<xsl:choose>
<xsl:when test="//t:sourceDesc//t:bibl/text()">
<xsl:value-of select="//t:sourceDesc//t:bibl"/>
Expand Down Expand Up @@ -59,7 +59,7 @@
<xsl:template name="default-body-structure">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<!-- Heading for a ddb style file -->
<xsl:if test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:if test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<h1>
<xsl:choose>
<xsl:when test="//t:sourceDesc//t:bibl/text()">
Expand Down
4 changes: 2 additions & 2 deletions teiabbrandexpan.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<xsl:apply-templates/>
<xsl:if test="not(ancestor::t:expan) and not($parm-edition-type='diplomatic')">
<xsl:text>(</xsl:text><xsl:choose>
<xsl:when test="$parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch'">
<xsl:when test="$parm-leiden-style = ('ddbdp','dclp','sammelbuch')">
<xsl:text>&#xa0;&#xa0;</xsl:text>
</xsl:when>
<xsl:when test="$parm-leiden-style = 'rib'">
Expand All @@ -26,7 +26,7 @@
<xsl:text>- - -</xsl:text>
</xsl:otherwise>
</xsl:choose><xsl:text>)</xsl:text>
<xsl:if test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch')">
<xsl:if test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch'))">
<!-- Found in tpl-certlow.xsl -->
<xsl:call-template name="cert-low"/>
</xsl:if>
Expand Down
8 changes: 4 additions & 4 deletions teiaddanddel.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<xsl:template match="t:add">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch')">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch')">
<xsl:choose>
<xsl:when test="parent::t:subst"/>
<xsl:when test="@place = 'above'">
Expand Down Expand Up @@ -57,7 +57,7 @@
<xsl:call-template name="cert-low"/>

<xsl:choose>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch')">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch')">
<xsl:choose>
<!-- if my parent is subst which in turn is in the appcrit-part of a further app-like element
(i.e. my ancestor is reg, corr, rdg, or del[corrected]), then include value of my sibling del in parens -->
Expand Down Expand Up @@ -122,10 +122,10 @@
<xsl:apply-templates/>
<xsl:text>]]</xsl:text>
</xsl:when>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and @rend='slashes'">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and @rend='slashes'">
<xsl:apply-templates/>
</xsl:when>
<xsl:when test="($parm-leiden-style = 'ddbdp' or $parm-leiden-style = 'sammelbuch') and @rend='cross-strokes'">
<xsl:when test="($parm-leiden-style = ('ddbdp','dclp','sammelbuch')) and @rend='cross-strokes'">
<xsl:apply-templates/>
</xsl:when>
<xsl:when test="$parm-leiden-style = 'rib'">
Expand Down
2 changes: 1 addition & 1 deletion teicertainty.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<xsl:template match="t:certainty">
<xsl:param name="parm-leiden-style" tunnel="yes" required="no"></xsl:param>
<xsl:choose>
<xsl:when test="$parm-leiden-style=('ddbdp','sammelbuch','iospe')">
<xsl:when test="$parm-leiden-style=('ddbdp','dclp','sammelbuch','iospe')">
<xsl:if test="@match='..'">
<xsl:text>(?)</xsl:text>
</xsl:if>
Expand Down
Loading

0 comments on commit 1f98648

Please sign in to comment.