Symmetri Developer Blog

May 14, 2009

Repeating image background in Flex

Flash/Flex - By Shourov Bhattacharya

Repeating an image in the background of a visual component in Flex turns out to be non-standard and not well documented. Given Flex 3 excellent support for CSS, you would probably assume that using background-image and background-repeat would do the trick. However, it turns out that background-repeat is not supported. The way to do it is to use the background-size style and set it to 100%:

.navPrimary
{
    background-image: Embed(../images/nav-background.png);
    background-size:100%;
}

Get free blog up and running in minutes with Blogsome
Theme designed by Janis Joseph