Environment: Flash CS4, AS3, Windows XP (client), Windows Server 2003/IIS6 (server)
NOTE: using the tilelist because the clickable item is pushed to an image editor class.
I'm using the standard tilelist setup from the library and creating the tilelist from Actionscript. By default, the column width is 50, though I have set the height to 110 and the width to 640. When I set rowHeight to 85 to compensate for the scrollbar, my entire tilelist becomes 85 high (though tracing the height property says that it is still 110). This causes the text labels to be hidden (unless I use a textpadding of 15, which then obscures the tiles themselves.
I have a similar problem with the width, columnWidth, and columnCount properties, as I set width to 640, columnWidth to 100 and columnCount to 6. What I get is a control that is 300 wide (as presented by the trace(loadBackground_mc.width) command).
Is the only alternative to solve this problem a custom cell renderer?
Any suggestions would be appreciated.
I found what appears to be the answer. Unlike many other controls, Tilelist settings must occur in a very particular order. You must set RowHeight and ColumnWidth, RowCount, and ColumnCount before setting the size of the control. I converted all my tilelists to load, then used a "setSize" method instead of individually setting the height and width properties of the control. These were done after defining the row/column counts and the rowheight/columnwidth.
Now, the Tilelist appears to work just as I need it. I wish there was better documentation on this requirement. I would expect that the size of the outer container would be set first and the inner containers (like the cells) would follow, but that is not the case here.