PDA

View Full Version : Help with TreeNode text style



Litre
15 Feb 2010, 10:26 PM
My TreePanel is working fine, but I wanted to change the style of the text.

I didn't find a style attribute in the TreeNode API, but it seems if I just use regular <font style="etc."> around the text it works fine.

e.g. TreeNode.text = '<font style="font-size: 12px">CategoryName</font>';

It's properly written in an AsyncTreeNode, don't worry that's not the problem.

BUT when I use it as a drag source and drag it into a drag target it breaks. Whereas my drag and drop works completely fine when I don't use a <font style> around the TreeNode.text

Any ideas? Is there an attribute I can change somewhere to set the TreeNode.text style?
It's hard to paste code since my JSON is returned by PHP.