@RJP43 @spadafour The solution to the question of how to sort wasn't too hard, but a little different from what we're used to. The <xsl:sort> does need to sit inside an apply-templates or an xsl:for-each, but if we stop and think about it, we can set up a for-each to loop through nothing else but the value of your list of eight variables for the various speaking voices in your collection. Using <xsl:for-each> here was the secret to reducing the total lines of code so you don't have to repeat so much. Inside it, I set a variable for stroke-color, too, and then I needed to only write one definition for an SVG element <line> and one for an SVG element <text>.
@RJP43 @spadafour The solution to the question of how to sort wasn't too hard, but a little different from what we're used to. The
<xsl:sort>
does need to sit inside an apply-templates or an xsl:for-each, but if we stop and think about it, we can set up a for-each to loop through nothing else but the value of your list of eight variables for the various speaking voices in your collection. Using<xsl:for-each>
here was the secret to reducing the total lines of code so you don't have to repeat so much. Inside it, I set a variable for stroke-color, too, and then I needed to only write one definition for an SVG element<line>
and one for an SVG element<text>
.Here's a direct link to the XSLT file.