Tree2 just renders what you tell it. You can put HTML in your node
description if you want using escape = false on a output text (just
watch for security problems with this).

<f:facet name="node">
<t:outputText value="#{node.description}" escape="false" />
</f:facet>

Unless you have escape = false, you will see the HTML escaped (&gt;
for > for example). You can also put a bound component in the node if
you want (Build a UIComponent in your node and then bind a tag to that
in the view). That way you would have full programatic control of the
HTML output for your node.

-Andrew

On 5/24/06, Christopher J. Bowerman <[EMAIL PROTECTED]> wrote:




Hi,



I am using the MyFaces tree2 component for application where the tree node
descriptions are a series of three numbers.  I'd like to color code the
numbers to match with other parts of the application.  I've tried to include
various html tags that I thought might do it, but it didn't seem to work.
In fact it just included the html tags in the description.  Is there any way
to do this?



I'm also like to preserve some whitespace, but it appears that the tree also
trims whitespace.  Again, anyway to do this?



Thanks,



Chris.



==================================

Christopher J. Bowerman

Internet Applications Developer

SAIC-Frederick

phone: 301.846.5275

email: [EMAIL PROTECTED]






Reply via email to