Skip to content

Commit

Permalink
check for element content
Browse files Browse the repository at this point in the history
in addition to the attributes `@count`, `@unit`, and `@sym`. This will then simply output the metre text as suggested in the MerMEId help text
  • Loading branch information
peterstadler committed Jun 21, 2023
1 parent b233208 commit 374045c
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions style/mei_to_html.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -749,9 +749,7 @@
</xsl:apply-templates>
<!-- meter, key, incipit – only relevant at this level in single movement works -->
<xsl:apply-templates select="m:tempo[text()]"/>
<xsl:if test="m:meter[normalize-space(concat(@count,@unit,@sym))]">
<xsl:apply-templates select="m:meter"/>
</xsl:if>
<xsl:apply-templates select="m:meter"/>
<xsl:apply-templates select="m:key[normalize-space(concat(@pname,@accid,@mode,string(.)))]"/>
<xsl:apply-templates select="m:extent"/>
<xsl:apply-templates select="m:incip"/>
Expand Down Expand Up @@ -849,9 +847,7 @@
</xsl:if>
</xsl:if>
<xsl:apply-templates select="m:tempo[text()]"/>
<xsl:if test="m:meter[normalize-space(concat(@count,@unit,@sym))]">
<xsl:apply-templates select="m:meter"/>
</xsl:if>
<xsl:apply-templates select="m:meter"/>
<xsl:apply-templates select="m:key[normalize-space(concat(@pname,@accid,@mode,string(.)))]"/>
<xsl:apply-templates select="m:extent"/>
<xsl:apply-templates select="m:incip"/>
Expand Down Expand Up @@ -1105,7 +1101,7 @@
</xsl:for-each>
</xsl:template>

<xsl:template match="m:meter">
<xsl:template match="m:meter[normalize-space(concat(@count,@unit,@sym,.))]">
<xsl:if test="position() = 1">
<span class="label">
<xsl:value-of select="$l/metre"/>: </span>
Expand Down

0 comments on commit 374045c

Please sign in to comment.