On Fri, 5 Feb 2010 14:33:40 +0000, Steffen Beyer wrote:
> That would not be a problem. The point is, scaling is not applied at all.
> 
>>>     border.width = w;
> 
> ...has no effect!

Next try:

protected function drawBorder(w:Number, h:Number):void
{
    if (w > 0)
    {
        var g:Graphics = graphics;
                        
        var border:Bitmap = new borderImage();
        border.width = w;
                        
        var scaledBorder:BitmapData = new BitmapData(w, border.height);
        scaledBorder.draw(border);
                
        g.beginBitmapFill(border.bitmapData);
        g.drawRect(0, h - 19, w, 19);
        g.endFill();
    }
}

I expected BitmapData.draw to apply the scaling -- but it doesn't.  :(

This cannot be so difficult!?

Kind regards,
-- 
Steffen Beyer <[email protected]>

GnuPG key fingerprint: CA00 1611 242B 89D4 E643  E235 05F3 7689 DD3E EB26
Public key available upon request or at http://wwwkeys.de.pgp.net

Reply via email to