> On 11/18/06, Rachel Maxim <[EMAIL PROTECTED]> wrote:
thanks for the pixel width push rachel, i'm a bit closer now: <mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" toolTip="{data.name}" width="100%" horizontalScrollPolicy="auto" verticalGap="0" verticalAlign="top" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0" horizontalGap="0" autoLayout="true" clipContent="false" creationComplete="doInit();"> <mx:Script> <![CDATA[ import flash.events.Event; private function doInit():void { addEventListener("dataChange",adjust); } private function adjust(event:Event):void { if (data.imgSource=="") { legendDetails.height=0; } } ]]> </mx:Script> <mx:Text text="{data.name}" width="150" fontSize="10" fontStyle="normal" fontWeight="bold" textAlign="left" textDecoration="none" selectable="false" id="layerName" color="#0000A0" themeColor="#000080"/> <mx:HBox width="100%" id="legendDetails" verticalAlign="top"> <mx:Image source="{data.imgSource}" height="16" width="16" id="legendSwatch"/> <mx:Text text="{data.label}" fontSize="9" fontStyle="normal" fontWeight="normal" textAlign="left" textDecoration="none" selectable="false" id="legendText" width="150"/> </mx:HBox> </mx:VBox> now i'm stuck trying to shrink the HBox height (setting visible to false still seems to take up space) if there's no data for it's children. again it seems to mostly work until the grid is scrolled then strange stuff happens. rows w/data are hidden, etc. obviously still missing something fundamental about item renderers.....

