Hello,

Thanks Alina, 
I think it will be easier for me to just define a new class that extends
mx:Label and listen to an event which indicates that the text has changed
and then execute a simple function to redefine the text.
just as followed
        public function changeStr():void {
            if (maxWidth) {
                if (this.measuredWidth > maxWidth) {
                    this.toolTip = this.text;
                    var len:int = text.length-1;
                    for(var index:int = len; index > 0; index--)
                    {
                        this.text = this.text.substring(0,index)+"...";
                        if (this.measuredWidth < maxWidth) {
                            break;
                        }
                    }
                }
            }
        }
I just need to find the proper event to listen

Nicolas




-----
Nicolas
--
Sent from: http://apache-royale-users.20374.n8.nabble.com/

Reply via email to