Skip to content

Commit 1848565

Browse files
committed
spectool: remove backticks from enum comments
1 parent 4571a41 commit 1848565

File tree

3 files changed

+30
-0
lines changed

3 files changed

+30
-0
lines changed

spectool/schema_2_kaxsemantic_h.xsl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,11 @@ namespace libmatroska {
508508
<xsl:with-param name="label" select="concat(substring-before($label, ' [@?'), ' ', substring-before(substring-after($label, ' [@?'), ']'), '', substring-after(substring-after($label, ' [@?'), ']'))"/>
509509
</xsl:call-template>
510510
</xsl:when>
511+
<xsl:when test="contains($label,' `')">
512+
<xsl:call-template name="cleanEnumDoc">
513+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
514+
</xsl:call-template>
515+
</xsl:when>
511516
<xsl:otherwise>
512517
<xsl:value-of select="$label"/>
513518
</xsl:otherwise>
@@ -527,6 +532,11 @@ namespace libmatroska {
527532
<xsl:with-param name="label" select="concat(substring-before($label, ' [@?'), ' (', substring-before(substring-after($label, ' [@?'), ']'), ')', substring-after(substring-after($label, ' [@?'), ']'))"/>
528533
</xsl:call-template>
529534
</xsl:when>
535+
<xsl:when test="contains($label,' `')">
536+
<xsl:call-template name="cleanEnumDoc">
537+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
538+
</xsl:call-template>
539+
</xsl:when>
530540
<xsl:when test="contains($label,'; see usage notes')">
531541
<xsl:call-template name="cleanEnumDoc">
532542
<xsl:with-param name="label" select="concat(substring-before($label, '; see usage notes'), substring-after($label, '; see usage notes'))"/>

spectool/schema_2_kaxsemantic_h_1x.xsl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,11 @@ namespace libmatroska {
522522
<xsl:with-param name="label" select="concat(substring-before($label, ' [@?'), ' (', substring-before(substring-after($label, ' [@?'), ']'), ')', substring-after(substring-after($label, ' [@?'), ']'))"/>
523523
</xsl:call-template>
524524
</xsl:when>
525+
<xsl:when test="contains($label,' `')">
526+
<xsl:call-template name="cleanEnumDoc">
527+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
528+
</xsl:call-template>
529+
</xsl:when>
525530
<xsl:when test="contains($label,'; see usage notes')">
526531
<xsl:call-template name="cleanEnumDoc">
527532
<xsl:with-param name="label" select="concat(substring-before($label, '; see usage notes'), substring-after($label, '; see usage notes'))"/>
@@ -546,6 +551,11 @@ namespace libmatroska {
546551
<xsl:with-param name="label" select="concat(substring-before($label, ' [@?'), ' ', substring-before(substring-after($label, ' [@?'), ']'), '', substring-after(substring-after($label, ' [@?'), ']'))"/>
547552
</xsl:call-template>
548553
</xsl:when>
554+
<xsl:when test="contains($label,' `')">
555+
<xsl:call-template name="cleanEnumDoc">
556+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
557+
</xsl:call-template>
558+
</xsl:when>
549559
<xsl:otherwise>
550560
<xsl:value-of select="$label"/>
551561
</xsl:otherwise>

spectool/schema_2_matroska_sem_h.xsl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,11 @@ void MATROSKA_InitSemantic(void);
419419
<xsl:with-param name="label" select="concat(substring-before($label, '; see usage notes'), substring-after($label, '; see usage notes'))"/>
420420
</xsl:call-template>
421421
</xsl:when>
422+
<xsl:when test="contains($label,' `')">
423+
<xsl:call-template name="cleanEnumDoc">
424+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
425+
</xsl:call-template>
426+
</xsl:when>
422427
<xsl:otherwise>
423428
<xsl:value-of select="translate($label, '&#10;', ' ')"/>
424429
</xsl:otherwise>
@@ -438,6 +443,11 @@ void MATROSKA_InitSemantic(void);
438443
<xsl:with-param name="label" select="concat(substring-before($label, ' [@?'), ' ', substring-before(substring-after($label, ' [@?'), ']'), '', substring-after(substring-after($label, ' [@?'), ']'))"/>
439444
</xsl:call-template>
440445
</xsl:when>
446+
<xsl:when test="contains($label,' `')">
447+
<xsl:call-template name="cleanEnumDoc">
448+
<xsl:with-param name="label" select="concat(substring-before($label, ' `'), ' ', substring-before(substring-after($label, ' `'), '`'), '', substring-after(substring-after($label, ' `'), '`'))"/>
449+
</xsl:call-template>
450+
</xsl:when>
441451
<xsl:otherwise>
442452
<xsl:value-of select="$label"/>
443453
</xsl:otherwise>

0 commit comments

Comments
 (0)