Thanks Mike, I started trying to do something similar to this before I asked for help. I kept stepping on my own foot figuring out a way to apply it. I have a lot to do today. But, I'll try to work this in. Again, this may be something that has been added to Flex final, but good gymnastics. Thanks again, I'll let you know how it works out.
-TH --- In flexcoders@yahoogroups.com, "Michael Schmalle" <[EMAIL PROTECTED]> wrote: > > Hey man, > > this is a primitive example: > > myContainer.setStyle("borderSkin", TaskListTitleBarBorderSkin ); > > or you know in CSS ;-) > > code > ------------------------------------------------------- > > package com.teotiGraphix.skins.teo > { > > import flash.geom.Matrix; > import flash.display.GradientType; > > import mx.skins.RectangularBorder; > > /** > * > */ > public class TaskListTitleBarBorderSkin extends RectangularBorder > { > > var backgroundColor:Number; > > /** > * Constructor > */ > public function TaskListTitleBarBorderSkin() > { > super(); > } > > /** > * > */ > public override function setActualSize(w:Number, h:Number):void > { > super.setActualSize(w, h); > > graphics.clear(); > var radius = getStyle("cornerRadius"); > var fillColors:Array = getStyle("fillColors"); > > var fillType:String = GradientType.LINEAR; > //var colors:Array = [0xFFFFFF, 0xC7D3F7]; > var alphas:Array = [100, 100]; > var ratios:Array = [0x33, 0xFF]; > var matr:Matrix = new Matrix(); > matr.createGradientBox(w, h - 5, 0/*(Math.PI/2)*/, 0, 0); > var spreadMethod:String = SpreadMethod.PAD; > > graphics.beginGradientFill(fillType, fillColors, alphas, ratios, > matr, spreadMethod); > > graphics.drawRoundRectComplex(0, 0, w, h, radius, radius, 0, 0); > graphics.endFill(); > } > } > } > > Peace, Mike > > On 6/20/06, Tim Hoff <[EMAIL PROTECTED]> wrote: > > > > In the process of styling, I wasn't able to apply gradient fillColors > > to containers (Panel, VBox...). Maybe, didn't make the final cut. In > > some situations this would come in handy. Vector graphics consume > > less resources. Has anyone subclassed this, to draw graphics as a > > container's background? > > > > Kindly, > > Tim Hoff > > > > > > > > > > -- > What goes up, does come down. > ------------------------ Yahoo! Groups Sponsor --------------------~--> Something is new at Yahoo! Groups. Check out the enhanced email design. http://us.click.yahoo.com/SISQkA/gOaOAA/yQLSAA/nhFolB/TM --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/