<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Creating a bitmap background fill on a Spark List control in Flex 4</title>
	<atom:link href="http://blog.flexexamples.com/2009/04/26/creating-a-bitmap-background-fill-on-a-spark-list-control-in-flex-gumbo/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.flexexamples.com/2009/04/26/creating-a-bitmap-background-fill-on-a-spark-list-control-in-flex-gumbo/</link>
	<description>Just a bunch of Adobe Flex Examples</description>
	<lastBuildDate>Sun, 12 Feb 2012 19:26:49 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Peter deHaan</title>
		<link>http://blog.flexexamples.com/2009/04/26/creating-a-bitmap-background-fill-on-a-spark-list-control-in-flex-gumbo/comment-page-1/#comment-8516</link>
		<dc:creator>Peter deHaan</dc:creator>
		<pubDate>Tue, 02 Nov 2010 17:26:52 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2009/04/26/1048/#comment-8516</guid>
		<description>You can also create a custom bitmap fill item renderer in ActionScript, as seen in the following example:
&lt;pre lang=&quot;actionscript3&quot;&gt;
package {
    import mx.graphics.BitmapFill;
    import mx.graphics.BitmapFillMode;
    import spark.components.ResizeMode;
    import spark.skins.spark.ListSkin;
    
    public class CustomListSkinAS extends ListSkin {
        protected var bmpFill:BitmapFill;
        
        [Embed(&quot;pattern_149.gif&quot;)]
        protected const img:Class;
        
        public function CustomListSkinAS() {
            super();
            
            bmpFill = new BitmapFill();
            bmpFill.alpha = 0.3;
            bmpFill.fillMode = BitmapFillMode.REPEAT;
            bmpFill.source = img;
            background.fill = bmpFill;
        }
    }
}
&lt;/pre&gt;

Peter</description>
		<content:encoded><![CDATA[<p>You can also create a custom bitmap fill item renderer in ActionScript, as seen in the following example:</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript3" style="font-family:monospace;"><span style="color: #9900cc; font-weight: bold;">package</span> <span style="color: #000000;">&#123;</span>
    <span style="color: #0033ff; font-weight: bold;">import</span> mx<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">graphics</span><span style="color: #000066; font-weight: bold;">.</span>BitmapFill<span style="color: #000066; font-weight: bold;">;</span>
    <span style="color: #0033ff; font-weight: bold;">import</span> mx<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">graphics</span><span style="color: #000066; font-weight: bold;">.</span>BitmapFillMode<span style="color: #000066; font-weight: bold;">;</span>
    <span style="color: #0033ff; font-weight: bold;">import</span> spark<span style="color: #000066; font-weight: bold;">.</span>components<span style="color: #000066; font-weight: bold;">.</span>ResizeMode<span style="color: #000066; font-weight: bold;">;</span>
    <span style="color: #0033ff; font-weight: bold;">import</span> spark<span style="color: #000066; font-weight: bold;">.</span>skins<span style="color: #000066; font-weight: bold;">.</span>spark<span style="color: #000066; font-weight: bold;">.</span>ListSkin<span style="color: #000066; font-weight: bold;">;</span>
&nbsp;
    <span style="color: #0033ff; font-weight: bold;">public</span> <span style="color: #9900cc; font-weight: bold;">class</span> CustomListSkinAS <span style="color: #0033ff; font-weight: bold;">extends</span> ListSkin <span style="color: #000000;">&#123;</span>
        <span style="color: #0033ff; font-weight: bold;">protected</span> <span style="color: #6699cc; font-weight: bold;">var</span> bmpFill<span style="color: #000066; font-weight: bold;">:</span>BitmapFill<span style="color: #000066; font-weight: bold;">;</span>
&nbsp;
        <span style="color: #000000;">&#91;</span>Embed<span style="color: #000000;">&#40;</span><span style="color: #990000;">&quot;pattern_149.gif&quot;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span>
        <span style="color: #0033ff; font-weight: bold;">protected</span> const img<span style="color: #000066; font-weight: bold;">:</span><span style="color: #004993;">Class</span><span style="color: #000066; font-weight: bold;">;</span>
&nbsp;
        <span style="color: #0033ff; font-weight: bold;">public</span> <span style="color: #339966; font-weight: bold;">function</span> CustomListSkinAS<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#123;</span>
            <span style="color: #0033ff; font-weight: bold;">super</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span>
&nbsp;
            bmpFill = <span style="color: #0033ff; font-weight: bold;">new</span> BitmapFill<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span>
            bmpFill<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">alpha</span> = <span style="color: #000000; font-weight:bold;">0.3</span><span style="color: #000066; font-weight: bold;">;</span>
            bmpFill<span style="color: #000066; font-weight: bold;">.</span>fillMode = BitmapFillMode<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">REPEAT</span><span style="color: #000066; font-weight: bold;">;</span>
            bmpFill<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">source</span> = img<span style="color: #000066; font-weight: bold;">;</span>
            <span style="color: #004993;">background</span><span style="color: #000066; font-weight: bold;">.</span>fill = bmpFill<span style="color: #000066; font-weight: bold;">;</span>
        <span style="color: #000000;">&#125;</span>
    <span style="color: #000000;">&#125;</span>
<span style="color: #000000;">&#125;</span></pre></div></div>

<p>Peter</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter deHaan</title>
		<link>http://blog.flexexamples.com/2009/04/26/creating-a-bitmap-background-fill-on-a-spark-list-control-in-flex-gumbo/comment-page-1/#comment-8020</link>
		<dc:creator>Peter deHaan</dc:creator>
		<pubDate>Sun, 27 Jun 2010 19:04:53 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2009/04/26/1048/#comment-8020</guid>
		<description>@Thilo,

Nope, just looks like the APIs changed between the time I originally wrote the example and when Flex 4.0 shipped.
I updated the code above so it should work in the final Flex 4.0.0.14159 SDK and the Flex 4.1.0.16076 SDK. I&#039;ll work on updating the SWF/ZIP too at some point.

Peter</description>
		<content:encoded><![CDATA[<p>@Thilo,</p>
<p>Nope, just looks like the APIs changed between the time I originally wrote the example and when Flex 4.0 shipped.<br />
I updated the code above so it should work in the final Flex 4.0.0.14159 SDK and the Flex 4.1.0.16076 SDK. I&#8217;ll work on updating the SWF/ZIP too at some point.</p>
<p>Peter</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Thilo</title>
		<link>http://blog.flexexamples.com/2009/04/26/creating-a-bitmap-background-fill-on-a-spark-list-control-in-flex-gumbo/comment-page-1/#comment-8019</link>
		<dc:creator>Thilo</dc:creator>
		<pubDate>Sun, 27 Jun 2010 16:57:23 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2009/04/26/1048/#comment-8019</guid>
		<description>Hi Peter,

could you give me a hint on how the item renderer has access to the property selectionColor for example? I&#039;m using the Flex 4.0 SDK 14159 and the compiler produces an error 1120: Access of undefined property selectionColor. I have the same issue with contentBackgroundColor and rollOverColor. In your online example it works perfectly and I have tried to rebuild that example without any changes but it won&#039;t run. Do you think it is a problem with the SDK version? Even if it would run I&#039;d wonder how the item renderer can be aware of these properties?!

Thanks and best regards!
Thilo</description>
		<content:encoded><![CDATA[<p>Hi Peter,</p>
<p>could you give me a hint on how the item renderer has access to the property selectionColor for example? I&#8217;m using the Flex 4.0 SDK 14159 and the compiler produces an error 1120: Access of undefined property selectionColor. I have the same issue with contentBackgroundColor and rollOverColor. In your online example it works perfectly and I have tried to rebuild that example without any changes but it won&#8217;t run. Do you think it is a problem with the SDK version? Even if it would run I&#8217;d wonder how the item renderer can be aware of these properties?!</p>
<p>Thanks and best regards!<br />
Thilo</p>
]]></content:encoded>
	</item>
</channel>
</rss>

