<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0"
      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      xmlns:fo="http://www.w3.org/1999/XSL/Format">

<xsl:template match="//treatment-info//br/text()">
<fo:block>  
<xsl:if test="treatment-info/br">
       <xsl:attribute name="fo">:block</xsl:attribute>
 
 </xsl:if>    <xsl:value-of select="."/></fo:block>  
</xsl:template>  

 <xsl:template match="//treatment-info//b/text() | //treatment-info//font/text()">
<fo:block>  
<xsl:if test="ancestor::treatment-info/b/text()"> 
      <xsl:attribute name="font-weight">bold</xsl:attribute>
    </xsl:if> 

 <xsl:template match="//treatment-info//font/text()">
  <xsl:if test="ancestor::treatment-info/font"> 
       <xsl:attribute name="color">#FF0000</xsl:attribute>
    </xsl:if>

    <xsl:value-of select="."/>   </xsl:template> 
    </fo:block>
   </xsl:template>
</xsl:stylesheet>
             
