I have this component, and inside i have some nested stuff...  I'm
trying to get my textHolder to wordwrap... i don't know what's
throwing it off... but my tileHolder is a second component, 30 pixels
tall right below it might be throwing this off, but I'm drawing it
with the draw api...

Please, help, what am I not understanding about how this lays out?

thanks,
Patrick



<mx:Fade id="fadeIn" alphaFrom="0" alphaTo="1" />
        <mx:VBox id="panelHolder" width="346" verticalScrollPolicy="off"
horizontalScrollPolicy="off" verticalAlign="middle" paddingBottom="0"
paddingTop="0" minHeight="50" horizontalAlign="Left" verticalGap="0"
creationCompleteEffect="fadeIn">
                <mx:HBox id="horizontalHolder" width="100%" 
horizontalAlign="Left"
horizontalGap="10" verticalAlign="middle" paddingLeft="15"
paddingRight="15" height="100%" horizontalScrollPolicy="off"
paddingBottom="2" paddingTop="2">       
                        <mx:Image id="imageHolder"  width="100" 
scaleContent="true"
autoLoad="true" completeEffect="{fadeIn}"/>
                        <mx:VBox verticalAlign="middle" paddingTop="0" 
paddingBottom="0"
height="100%">
                                        <mx:Text id="textHolder"  
styleName="subHeadingText"
selectable="false" />
                                        <mx:HBox id="tileHolder"  height="30"/>
                        </mx:VBox>
                </mx:HBox>
        </mx:VBox>
</mx:Canvas>


I'm using this custom wordwrap function, which was cheesy as all
get-out, but working, until i discovered the mac has different size
text... 


if (myRadioPanel.textHolder.htmlText.length<40)
myRadioPanel.textHolder.height = 15;
                                                                if
((myRadioPanel.textHolder.htmlText.length>40)&&(myRadioPanel.textHolde
r.htmlText.length<80)) myRadioPanel.textHolder.height = 30;
                                                                if
((myRadioPanel.textHolder.htmlText.length>80)&&(myRadioPanel.textHolde
r.htmlText.length<120))myRadioPanel.textHolder.height= 45;




Reply via email to