vatsag 0 Newbie Poster

Hello Im very new to the XSLFO. I have a requirement to color a text entry with a suitable background color which i do using the snippet

<fo:inline color = "red" background-color = "yellow">
    <xsl:value-of select="."/>
</fo:inline>

With the above snippet i am able to set the forecolor of the text to RED but not the background color.


Though I can add background color using

<fo:inline color = "red">
   <fo:block background-color = "yellow">
    <xsl:value-of select="."/>
  </fo:block> 
 </fo:inline>

But this is making my entry come on a separate line which isnt my requirement

Although the xslfo documentation says there is a property available for to add the background color for a text.

<fo:inline background-color = "yellow">
 Hello,World
 </fo:inline>

The background color still doesnt get applied to the text.
Im using the xslfo version 1.0

Anyone out there to help me out what could be the cause?

Cheers

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.