A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: HTML in TreeComponent??

  1. #1
    anyone else hear that? flashpipe1's Avatar
    Join Date
    Jan 2003
    Location
    Upstate NY
    Posts
    1,929

    HTML in TreeComponent??

    I've got the following text in an xml doc that I'm loading into a Tree Component using addTreeNode:
    SubDir "test" text

    and it displays in the Tree Component as:
    SubDir 'test' text

    If I parse it and replace the &apos with /" like:
    SubDir /"test/" text
    it displays properly, but I'm wondering if there's a way to enable html in the Tree Component so I don't have to parse out every html character from the strings??

    Thanks!!
    Love like you've never been hurt, live like there's no tomorrow and dance like nobody's watching.

  2. #2
    Senior Member cancerinform's Avatar
    Join Date
    Mar 2002
    Location
    press the picture...
    Posts
    13,448
    I have attached a cellrenderer script, which converts text in the tree to html. Create a movieclip in the library, name it MultiLineCell, export for AS and fill out the class line: scripts.helper.MultiLineCell
    Then in your script you write:

    myTree.cellRenderer = "MultiCellLine";

    To express html in your tree component you have to use special characters in the attributes as shown here:
    PHP Code:
    label="<font color='#FF0000'>hello</font><p>this is a test.</p>" 
    Attached Files Attached Files
    - The right of the People to create Flash movies shall not be infringed. -

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center