No, you can't override a template in xsl, and that's why you have this error.
You will need another mechanism, like setting a xsl:variable that specify if a theme should be used, and use an xsl:choose construction to do a call template.
Code:
<xsl:variable name="Theme">1</xsl:variable>
...
<xsl:choose>
<xsl:when test="$Theme=1">
<xsl:call-template name="theme_panel"/>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="default_panel"/>
</xsl:otherwise>
</xsl:choose>
But doing this, you loose the flexibility of apply-templates.
Another solution, that I retained when I did this: http://www.quixml.org, is to have separate folder with a set of xsl style sheets, and having a theme variable that switch the source folder of the xsl stylesheets.
It's what I've called "rendering sets", in my quixml class.
Bookmarks