<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Flex Examples &#187; stroke</title>
	<atom:link href="http://blog.flexexamples.com/tag/stroke/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.flexexamples.com</link>
	<description>Just a bunch of Adobe Flex Examples</description>
	<lastBuildDate>Wed, 26 Jan 2011 18:09:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Setting the end caps on a Spark Line stroke in Flex 4</title>
		<link>http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/</link>
		<comments>http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/#comments</comments>
		<pubDate>Mon, 24 Aug 2009 13:52:06 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta1]]></category>
		<category><![CDATA[caps]]></category>
		<category><![CDATA[CapsStyle]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[SolidColorStroke]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/?p=1708</guid>
		<description><![CDATA[<p>The following example shows how you can set the end caps on a Spark SolidColorStroke object by setting the caps property to one of the static constant values in the flash.display.CapsStyle class.</p> <p>Full code after the jump.</p> <p></p> &#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62; &#60;!-- http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/ --&#62; &#60;s:Application name=&#34;Spark_Line_stroke_caps_test&#34; xmlns:fx=&#34;http://ns.adobe.com/mxml/2009&#34; xmlns:s=&#34;library://ns.adobe.com/flex/spark&#34; xmlns:mx=&#34;library://ns.adobe.com/flex/halo&#34;&#62; &#160; &#60;mx:ApplicationControlBar width=&#34;100%&#34; cornerRadius=&#34;0&#34;&#62; &#60;mx:Form styleName=&#34;plain&#34;&#62; [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the end caps on a Spark SolidColorStroke object by setting the <code>caps</code> property to one of the static constant values in the flash.display.CapsStyle class.</p>
<p>Full code after the jump.</p>
<p><span id="more-1708"></span></p>
<p class="alert">The following example(s) require Flash Player 10 and the Adobe Flex 4 SDK. To download the Adobe Flash Builder 4 trial, see <a href="http://bit.ly/crThlI">http://www.adobe.com/products/flex/</a>. To download the latest nightly build of the Flex 4 SDK, see <a href="http://bit.ly/Flex4SDK">http://opensource.adobe.com/wiki/display/flexsdk/Download+Flex+4</a>.<br/><strong>For more information on getting started with Flex 4 and Flash Builder 4, see the official <a href="http://bit.ly/dCkecm">Adobe Flex Team blog</a>.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="mxml" style="font-family:monospace;"><span style="color: #000000;">&lt;?xml version=<span style="color: #ff0000;">&quot;1.0&quot;</span> encoding=<span style="color: #ff0000;">&quot;utf-8&quot;</span>?<span style="color: #7400FF;">&gt;</span></span>
<span style="color: #000000;"><span style="color: #808080; font-style: italic;">&lt;!-- http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/ --&gt;</span></span>
<span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Application</span> name=<span style="color: #ff0000;">&quot;Spark_Line_stroke_caps_test&quot;</span></span>
<span style="color: #000000;">        xmlns:fx=<span style="color: #ff0000;">&quot;http://ns.adobe.com/mxml/2009&quot;</span> </span>
<span style="color: #000000;">        xmlns:s=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/spark&quot;</span> </span>
<span style="color: #000000;">        xmlns:mx=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/halo&quot;</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:ApplicationControlBar</span> width=<span style="color: #ff0000;">&quot;100%&quot;</span> cornerRadius=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:Form</span> styleName=<span style="color: #ff0000;">&quot;plain&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:FormItem</span> label=<span style="color: #ff0000;">&quot;caps:&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:DropDownList</span> id=<span style="color: #ff0000;">&quot;dropDownList&quot;</span> requireSelection=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:ArrayList</span> source=<span style="color: #ff0000;">&quot;[round,square,none]&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:DropDownList</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:FormItem</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:ApplicationControlBar</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:VRule</span> height=<span style="color: #ff0000;">&quot;{vGr.height+20}&quot;</span></span>
<span style="color: #000000;">            horizontalCenter=<span style="color: #ff0000;">&quot;-100&quot;</span></span>
<span style="color: #000000;">            verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:VRule</span> height=<span style="color: #ff0000;">&quot;{vGr.height+20}&quot;</span></span>
<span style="color: #000000;">            horizontalCenter=<span style="color: #ff0000;">&quot;100&quot;</span></span>
<span style="color: #000000;">            verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:VGroup</span> id=<span style="color: #ff0000;">&quot;vGr&quot;</span> gap=<span style="color: #ff0000;">&quot;10&quot;</span> horizontalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Line</span> width=<span style="color: #ff0000;">&quot;200&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> color=<span style="color: #ff0000;">&quot;red&quot;</span></span>
<span style="color: #000000;">                        caps=<span style="color: #ff0000;">&quot;{dropDownList.selectedItem}&quot;</span></span>
<span style="color: #000000;">                        weight=<span style="color: #ff0000;">&quot;20&quot;</span></span>
<span style="color: #000000;">                        alpha=<span style="color: #ff0000;">&quot;0.4&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Line</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:VGroup</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
<span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Application</span><span style="color: #7400FF;">&gt;</span></span></pre></div></div>

<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/spark/Spark_Line_stroke_caps_test/bin/srcview/">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/spark/Spark_Line_stroke_caps_test/bin/main.html" width="100%" height="200"></iframe></p>
<div span="googleAdsLeaderboard">
<script type="text/javascript"><!--
google_ad_client = "pub-3325829455487492";
/* 728x90, created 7/15/09 */
google_ad_slot = "6403511741";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<br />
</div>
<p>You can also set the <code>caps</code> property using ActionScript, as seen in the following example:</p>

<div class="wp_syntax"><div class="code"><pre class="mxml" style="font-family:monospace;"><span style="color: #000000;">&lt;?xml version=<span style="color: #ff0000;">&quot;1.0&quot;</span> encoding=<span style="color: #ff0000;">&quot;utf-8&quot;</span>?<span style="color: #7400FF;">&gt;</span></span>
<span style="color: #000000;"><span style="color: #808080; font-style: italic;">&lt;!-- http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/ --&gt;</span></span>
<span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Application</span> name=<span style="color: #ff0000;">&quot;Spark_Line_stroke_caps_test&quot;</span></span>
<span style="color: #000000;">        xmlns:fx=<span style="color: #ff0000;">&quot;http://ns.adobe.com/mxml/2009&quot;</span> </span>
<span style="color: #000000;">        xmlns:s=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/spark&quot;</span> </span>
<span style="color: #000000;">        xmlns:mx=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/halo&quot;</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #000000;">            import mx.graphics.SolidColorStroke;</span>
<span style="color: #000000;">            import spark.events.IndexChangeEvent;</span>
&nbsp;
<span style="color: #000000;">            protected function dropDownList_change<span style="color: #66cc66;">&#40;</span>evt:IndexChangeEvent<span style="color: #66cc66;">&#41;</span>:void <span style="color: #66cc66;">&#123;</span></span>
<span style="color: #000000;">                lineStroke.caps = dropDownList.selectedItem;</span>
<span style="color: #000000;">                /* or</span>
<span style="color: #000000;">                SolidColorStroke<span style="color: #66cc66;">&#40;</span>line.stroke<span style="color: #66cc66;">&#41;</span>.caps = dropDownList.selectedItem;</span>
<span style="color: #000000;">                */</span>
<span style="color: #000000;">            <span style="color: #66cc66;">&#125;</span></span>
<span style="color: #000000;">        <span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:ApplicationControlBar</span> width=<span style="color: #ff0000;">&quot;100%&quot;</span> cornerRadius=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:Form</span> styleName=<span style="color: #ff0000;">&quot;plain&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:FormItem</span> label=<span style="color: #ff0000;">&quot;caps:&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:DropDownList</span> id=<span style="color: #ff0000;">&quot;dropDownList&quot;</span></span>
<span style="color: #000000;">                        requireSelection=<span style="color: #ff0000;">&quot;true&quot;</span></span>
<span style="color: #000000;">                        change=<span style="color: #ff0000;">&quot;dropDownList_change(event);&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:ArrayList</span> source=<span style="color: #ff0000;">&quot;[round,square,none]&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:DropDownList</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:FormItem</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:ApplicationControlBar</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:VRule</span> height=<span style="color: #ff0000;">&quot;{vGr.height+20}&quot;</span></span>
<span style="color: #000000;">            horizontalCenter=<span style="color: #ff0000;">&quot;-100&quot;</span></span>
<span style="color: #000000;">            verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:VRule</span> height=<span style="color: #ff0000;">&quot;{vGr.height+20}&quot;</span></span>
<span style="color: #000000;">            horizontalCenter=<span style="color: #ff0000;">&quot;100&quot;</span></span>
<span style="color: #000000;">            verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:VGroup</span> id=<span style="color: #ff0000;">&quot;vGr&quot;</span> gap=<span style="color: #ff0000;">&quot;10&quot;</span> horizontalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Line</span> id=<span style="color: #ff0000;">&quot;line&quot;</span> width=<span style="color: #ff0000;">&quot;200&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> id=<span style="color: #ff0000;">&quot;lineStroke&quot;</span></span>
<span style="color: #000000;">                        color=<span style="color: #ff0000;">&quot;red&quot;</span></span>
<span style="color: #000000;">                        weight=<span style="color: #ff0000;">&quot;20&quot;</span></span>
<span style="color: #000000;">                        alpha=<span style="color: #ff0000;">&quot;0.4&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Line</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:VGroup</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
<span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Application</span><span style="color: #7400FF;">&gt;</span></span></pre></div></div>

<p>Due to popular demand, here is the &#8220;same&#8221; example in a more ActionScript friendly format:</p>

<div class="wp_syntax"><div class="code"><pre class="mxml" style="font-family:monospace;"><span style="color: #000000;">&lt;?xml version=<span style="color: #ff0000;">&quot;1.0&quot;</span> encoding=<span style="color: #ff0000;">&quot;utf-8&quot;</span>?<span style="color: #7400FF;">&gt;</span></span>
<span style="color: #000000;"><span style="color: #808080; font-style: italic;">&lt;!-- http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/ --&gt;</span></span>
<span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Application</span> name=<span style="color: #ff0000;">&quot;Spark_Line_stroke_caps_test&quot;</span></span>
<span style="color: #000000;">        xmlns:fx=<span style="color: #ff0000;">&quot;http://ns.adobe.com/mxml/2009&quot;</span> </span>
<span style="color: #000000;">        xmlns:s=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/spark&quot;</span> </span>
<span style="color: #000000;">        xmlns:mx=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/halo&quot;</span></span>
<span style="color: #000000;">        initialize=<span style="color: #ff0000;">&quot;init();&quot;</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #000000;">            import mx.collections.ArrayList;</span>
<span style="color: #000000;">            import mx.containers.ApplicationControlBar;</span>
<span style="color: #000000;">            import mx.containers.Form;</span>
<span style="color: #000000;">            import mx.containers.FormItem;</span>
<span style="color: #000000;">            import mx.controls.VRule;</span>
<span style="color: #000000;">            import mx.graphics.SolidColorStroke;</span>
<span style="color: #000000;">            import spark.components.DropDownList;</span>
<span style="color: #000000;">            import spark.components.VGroup;</span>
<span style="color: #000000;">            import spark.events.IndexChangeEvent;</span>
<span style="color: #000000;">            import spark.primitives.Line;</span>
&nbsp;
<span style="color: #000000;">            private var dropDownList:DropDownList;</span>
<span style="color: #000000;">            private var line:Line;</span>
<span style="color: #000000;">            private var lineStroke:SolidColorStroke;</span>
<span style="color: #000000;">            private var vGr:VGroup;</span>
&nbsp;
<span style="color: #000000;">            private function init<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:void <span style="color: #66cc66;">&#123;</span></span>
<span style="color: #000000;">                var arr:Array = <span style="color: #66cc66;">&#91;</span>CapsStyle.ROUND, CapsStyle.SQUARE, CapsStyle.NONE<span style="color: #66cc66;">&#93;</span>;</span>
<span style="color: #000000;">                var arrList:ArrayList = new ArrayList<span style="color: #66cc66;">&#40;</span>arr<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                dropDownList = new DropDownList<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                dropDownList.dataProvider = arrList;</span>
<span style="color: #000000;">                dropDownList.requireSelection = true;</span>
<span style="color: #000000;">                dropDownList.addEventListener<span style="color: #66cc66;">&#40;</span>IndexChangeEvent.CHANGE, dropDownList_change<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                var formItem:FormItem = new FormItem<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                formItem.label = <span style="color: #ff0000;">&quot;caps:&quot;</span>;</span>
<span style="color: #000000;">                formItem.addElement<span style="color: #66cc66;">&#40;</span>dropDownList<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                var form:Form = new Form<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                form.styleName = <span style="color: #ff0000;">&quot;plain&quot;</span>;</span>
<span style="color: #000000;">                form.addElement<span style="color: #66cc66;">&#40;</span>formItem<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                var appControlBar:ApplicationControlBar = new ApplicationControlBar<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                appControlBar.percentWidth = <span style="color: #cc66cc;">100</span>;</span>
<span style="color: #000000;">                appControlBar.setStyle<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;cornerRadius&quot;</span>, <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                appControlBar.addElement<span style="color: #66cc66;">&#40;</span>form<span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                addElementAt<span style="color: #66cc66;">&#40;</span>appControlBar, <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                var vRule1:VRule = new VRule<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                vRule1.height = <span style="color: #cc66cc;">40</span>;</span>
<span style="color: #000000;">                vRule1.horizontalCenter = -<span style="color: #cc66cc;">100</span>;</span>
<span style="color: #000000;">                vRule1.verticalCenter = <span style="color: #cc66cc;">0</span>;</span>
<span style="color: #000000;">                addElement<span style="color: #66cc66;">&#40;</span>vRule1<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                var vRule2:VRule = new VRule<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                vRule2.height = <span style="color: #cc66cc;">40</span>;</span>
<span style="color: #000000;">                vRule2.horizontalCenter = <span style="color: #cc66cc;">100</span>;</span>
<span style="color: #000000;">                vRule2.verticalCenter = <span style="color: #cc66cc;">0</span>;</span>
<span style="color: #000000;">                addElement<span style="color: #66cc66;">&#40;</span>vRule2<span style="color: #66cc66;">&#41;</span>;</span>
&nbsp;
<span style="color: #000000;">                lineStroke = new SolidColorStroke<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                lineStroke.color = 0xFF0000; // red</span>
<span style="color: #000000;">                lineStroke.caps = dropDownList.selectedItem;</span>
<span style="color: #000000;">                lineStroke.weight = <span style="color: #cc66cc;">20</span>;</span>
<span style="color: #000000;">                lineStroke.alpha = <span style="color: #cc66cc;">0.4</span>; // <span style="color: #cc66cc;">40</span>%</span>
&nbsp;
<span style="color: #000000;">                line = new Line<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                line.width = <span style="color: #cc66cc;">200</span>;</span>
<span style="color: #000000;">                line.stroke = lineStroke;</span>
&nbsp;
<span style="color: #000000;">                vGr = new VGroup<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                vGr.gap = <span style="color: #cc66cc;">10</span>;</span>
<span style="color: #000000;">                vGr.horizontalCenter = <span style="color: #cc66cc;">0</span>;</span>
<span style="color: #000000;">                vGr.verticalCenter = <span style="color: #cc66cc;">0</span>;</span>
<span style="color: #000000;">                vGr.addElement<span style="color: #66cc66;">&#40;</span>line<span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">                addElement<span style="color: #66cc66;">&#40;</span>vGr<span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">            <span style="color: #66cc66;">&#125;</span></span>
&nbsp;
<span style="color: #000000;">            protected function dropDownList_change<span style="color: #66cc66;">&#40;</span>evt:IndexChangeEvent<span style="color: #66cc66;">&#41;</span>:void <span style="color: #66cc66;">&#123;</span></span>
<span style="color: #000000;">                lineStroke.caps = dropDownList.selectedItem;</span>
<span style="color: #000000;">                /* or</span>
<span style="color: #000000;">                SolidColorStroke<span style="color: #66cc66;">&#40;</span>line.stroke<span style="color: #66cc66;">&#41;</span>.caps = dropDownList.selectedItem;</span>
<span style="color: #000000;">                */</span>
<span style="color: #000000;">            <span style="color: #66cc66;">&#125;</span></span>
<span style="color: #000000;">        <span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
<span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Application</span><span style="color: #7400FF;">&gt;</span></span></pre></div></div>

<p class="alert">This entry is based on a beta version of the Flex 4 SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex 4 SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the end caps on a Spark Line stroke in Flex 4 on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/',contentID: 'post-1708',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'caps,CapsStyle,Gumbo,SolidColorStroke,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/08/24/setting-the-end-caps-on-a-spark-line-stroke-in-flex-4/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the miter limit on a Path stroke in Flex 4</title>
		<link>http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Sat, 17 Jan 2009 07:55:33 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[Path]]></category>
		<category><![CDATA[SolidColorStroke]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[joints]]></category>
		<category><![CDATA[miterLimit]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the miter limit on a Flex 4 Path stroke by setting the miterLimit property on a stroke object.</p> <p>Full code after the jump.</p> <p></p> &#60;?xml version="1.0" encoding="utf-8"?&#62; &#60;!-- http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/ --&#62; &#60;Application name="Path_stroke_miterLimit_test" xmlns="http://ns.adobe.com/mxml/2009" layout="vertical" verticalAlign="middle" backgroundColor="white"&#62; &#60;Declarations&#62; &#60;String id="pathData"&#62;M 0 0 L 200 0 L 0 80 [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the miter limit on a Flex 4 Path stroke by setting the <code>miterLimit</code> property on a stroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-929"></span></p>
<p class="alert">The following example(s) require Flash Player 10 and the Adobe Flex 4 SDK. To download the Adobe Flash Builder 4 trial, see <a href="http://bit.ly/crThlI">http://www.adobe.com/products/flex/</a>. To download the latest nightly build of the Flex 4 SDK, see <a href="http://bit.ly/Flex4SDK">http://opensource.adobe.com/wiki/display/flexsdk/Download+Flex+4</a>.<br/><strong>For more information on getting started with Flex 4 and Flash Builder 4, see the official <a href="http://bit.ly/dCkecm">Adobe Flex Team blog</a>.</strong></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="Path_stroke_miterLimit_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Declarations&gt;
        &lt;String id="pathData"&gt;M 0 0 L 200 0 L 0 80 Z&lt;/String&gt;
    &lt;/Declarations&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="miterLimit:"&gt;
                &lt;HSlider id="slider"
                        minimum="0"
                        maximum="10"
                        value="0"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Path id="path" data="{pathData}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke id="pathStroke"
                        joints="miter"
                        miterLimit="{slider.value}"
                        color="red"
                        weight="40" /&gt;
            &lt;/stroke&gt;
        &lt;/Path&gt;
        &lt;Path data="{pathData}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke
                        color="black"
                        weight="1" /&gt;
            &lt;/stroke&gt;
        &lt;/Path&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p>You can also set the <code>miterLimit</code> property using ActionScript, as seen in the following example:</p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="Path_stroke_miterLimit_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.SliderEvent;

            private function slider_change(evt:SliderEvent):void {
                pathStroke.miterLimit = evt.value;
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;Declarations&gt;
        &lt;String id="pathData"&gt;M 0 0 L 200 0 L 0 80 Z&lt;/String&gt;
    &lt;/Declarations&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="miterLimit:"&gt;
                &lt;HSlider id="slider"
                        minimum="0"
                        maximum="10"
                        value="0"
                        tickInterval="1"
                        liveDragging="true"
                        change="slider_change(event);" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Path id="path" data="{pathData}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke id="pathStroke"
                        joints="miter"
                        color="red"
                        weight="40" /&gt;
            &lt;/stroke&gt;
        &lt;/Path&gt;
        &lt;Path data="{pathData}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke
                        color="black"
                        weight="1" /&gt;
            &lt;/stroke&gt;
        &lt;/Path&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex 4 SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex 4 SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the miter limit on a Path stroke in Flex 4 on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/',contentID: 'post-929',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,joints,miterLimit,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/16/setting-the-miter-limit-on-a-path-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the thickness of a stroke on a Line object in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/#comments</comments>
		<pubDate>Tue, 13 Jan 2009 07:48:51 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[Line]]></category>
		<category><![CDATA[SolidColorStroke]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[stroke]]></category>
		<category><![CDATA[weight]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set an Line object&#8217;s stroke weight by setting the weight property on the SolidColorStroke object.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set an Line object&#8217;s stroke weight by setting the <code>weight</code> property on the SolidColorStroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-931"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/ --&gt;
&lt;Application name="Line_stroke_weight_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="weight:"&gt;
                &lt;HSlider id="slider"
                        minimum="0"
                        maximum="20"
                        snapInterval="1"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Line width="300"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke id="lineStroke"
                        color="haloOrange"
                        weight="{slider.value}" /&gt;
            &lt;/stroke&gt;
        &lt;/Line&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the thickness of a stroke on a Line object in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/',contentID: 'post-931',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,stroke,weight',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/12/setting-the-thickness-of-a-stroke-on-a-line-object-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the scale mode on an Ellipse object stroke in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Sat, 10 Jan 2009 16:47:03 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[Ellipse]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[LineScaleMode]]></category>
		<category><![CDATA[SolidColorStroke]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[scaleMode]]></category>
		<category><![CDATA[scaleX]]></category>
		<category><![CDATA[scaleY]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the scale mode on an Ellipse object&#8217;s stroke object by setting the scaleMode property to one of the static constants in the LineScaleMode class.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the scale mode on an Ellipse object&#8217;s stroke object by setting the <code>scaleMode</code> property to one of the static constants in the LineScaleMode class.</p>
<p>Full code after the jump.</p>
<p><span id="more-932"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="Ellipse_stroke_scaleMode_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="scaleMode:"&gt;
                &lt;ComboBox id="comboBox" selectedIndex="1"&gt;
                    &lt;dataProvider&gt;
                        &lt;Array&gt;
                            &lt;String&gt;{LineScaleMode.NONE}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.NORMAL}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.HORIZONTAL}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.VERTICAL}&lt;/String&gt;
                        &lt;/Array&gt;
                    &lt;/dataProvider&gt;
                &lt;/ComboBox&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="scaleX:"&gt;
                &lt;HSlider id="xSlider"
                        minimum="1"
                        maximum="5"
                        value="1"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="scaleY:"&gt;
                &lt;HSlider id="ySlider"
                        minimum="1"
                        maximum="5"
                        value="1"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Ellipse id="ellipse"
                width="80"
                height="60"
                scaleX="{xSlider.value}"
                scaleY="{ySlider.value}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke id="lineStroke"
                        scaleMode="{comboBox.selectedItem}"
                        weight="10" /&gt;
            &lt;/stroke&gt;
        &lt;/Ellipse&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p>You can also set the <code>scaleMode</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="Ellipse_stroke_scaleMode_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.ListEvent;

            private function comboBox_change(evt:ListEvent):void {
                lineStroke.scaleMode = comboBox.selectedItem.toString();
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="scaleMode:"&gt;
                &lt;ComboBox id="comboBox"
                        selectedIndex="1"
                        change="comboBox_change(event);"&gt;
                    &lt;dataProvider&gt;
                        &lt;Array&gt;
                            &lt;String&gt;{LineScaleMode.NONE}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.NORMAL}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.HORIZONTAL}&lt;/String&gt;
                            &lt;String&gt;{LineScaleMode.VERTICAL}&lt;/String&gt;
                        &lt;/Array&gt;
                    &lt;/dataProvider&gt;
                &lt;/ComboBox&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="scaleX:"&gt;
                &lt;HSlider id="xSlider"
                        minimum="1"
                        maximum="5"
                        value="1"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="scaleY:"&gt;
                &lt;HSlider id="ySlider"
                        minimum="1"
                        maximum="5"
                        value="1"
                        tickInterval="1"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Ellipse id="ellipse"
                width="80"
                height="60"
                scaleX="{xSlider.value}"
                scaleY="{ySlider.value}"&gt;
            &lt;stroke&gt;
                &lt;SolidColorStroke id="lineStroke"
                        weight="10" /&gt;
            &lt;/stroke&gt;
        &lt;/Ellipse&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the scale mode on an Ellipse object stroke in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/',contentID: 'post-932',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,scaleMode,scaleX,scaleY,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/10/setting-the-scale-mode-on-an-ellipse-object-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Setting the joint style on a Path stroke in Flex 4</title>
		<link>http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Fri, 09 Jan 2009 16:03:56 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[Flex4]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[JointStyle]]></category>
		<category><![CDATA[Path]]></category>
		<category><![CDATA[SolidColorStroke]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[joints]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the joint style on a Flex 4 SolidColorStroke object by setting the joints property to a static constant in the JointStyle class (flash.display.JointStyle).</p> <p></p> &#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62; &#60;!-- http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/ --&#62; &#60;s:Application name=&#34;Spark_Path_stroke_joints_test&#34; xmlns:fx=&#34;http://ns.adobe.com/mxml/2009&#34; xmlns:s=&#34;library://ns.adobe.com/flex/spark&#34; xmlns:mx=&#34;library://ns.adobe.com/flex/mx&#34;&#62; &#160; &#60;fx:Declarations&#62; &#60;fx:String id=&#34;pathData&#34;&#62;M 0 0 L 200 0 L 0 80 [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the joint style on a Flex 4 SolidColorStroke object by setting the <code>joints</code> property to a static constant in the JointStyle class (flash.display.JointStyle).</p>
<p><span id="more-928"></span></p>
<p class="alert">The following example(s) require Flash Player 10 and the Adobe Flex 4 SDK. To download the Adobe Flash Builder 4 trial, see <a href="http://bit.ly/crThlI">http://www.adobe.com/products/flex/</a>. To download the latest nightly build of the Flex 4 SDK, see <a href="http://bit.ly/Flex4SDK">http://opensource.adobe.com/wiki/display/flexsdk/Download+Flex+4</a>.<br/><strong>For more information on getting started with Flex 4 and Flash Builder 4, see the official <a href="http://bit.ly/dCkecm">Adobe Flex Team blog</a>.</strong></p>

<div class="wp_syntax"><div class="code"><pre class="mxml" style="font-family:monospace;"><span style="color: #000000;">&lt;?xml version=<span style="color: #ff0000;">&quot;1.0&quot;</span> encoding=<span style="color: #ff0000;">&quot;utf-8&quot;</span>?<span style="color: #7400FF;">&gt;</span></span>
<span style="color: #000000;"><span style="color: #808080; font-style: italic;">&lt;!-- http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/ --&gt;</span></span>
<span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Application</span> name=<span style="color: #ff0000;">&quot;Spark_Path_stroke_joints_test&quot;</span></span>
<span style="color: #000000;">        xmlns:fx=<span style="color: #ff0000;">&quot;http://ns.adobe.com/mxml/2009&quot;</span></span>
<span style="color: #000000;">        xmlns:s=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/spark&quot;</span></span>
<span style="color: #000000;">        xmlns:mx=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/mx&quot;</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:Declarations</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:String</span> id=<span style="color: #ff0000;">&quot;pathData&quot;</span><span style="color: #7400FF;">&gt;</span></span>M 0 0 L 200 0 L 0 80 Z<span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:String</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:Declarations</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:controlBarContent</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:FormItem</span> label=<span style="color: #ff0000;">&quot;joints:&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:DropDownList</span> id=<span style="color: #ff0000;">&quot;comboBox&quot;</span> requireSelection=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:ArrayList</span> source=<span style="color: #ff0000;">&quot;[bevel,miter,round]&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:DropDownList</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:FormItem</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:controlBarContent</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Group</span> horizontalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Path</span> id=<span style="color: #ff0000;">&quot;path&quot;</span> data=<span style="color: #ff0000;">&quot;{pathData}&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> id=<span style="color: #ff0000;">&quot;pathStroke&quot;</span></span>
<span style="color: #000000;">                        joints=<span style="color: #ff0000;">&quot;{comboBox.selectedItem}&quot;</span></span>
<span style="color: #000000;">                        color=<span style="color: #ff0000;">&quot;red&quot;</span></span>
<span style="color: #000000;">                        weight=<span style="color: #ff0000;">&quot;40&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Path</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Path</span> data=<span style="color: #ff0000;">&quot;{pathData}&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> color=<span style="color: #ff0000;">&quot;black&quot;</span> weight=<span style="color: #ff0000;">&quot;1&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Path</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Group</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
<span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Application</span><span style="color: #7400FF;">&gt;</span></span></pre></div></div>

<div span="googleAdsLeaderboard">
<script type="text/javascript"><!--
google_ad_client = "pub-3325829455487492";
/* 728x90, created 7/15/09 */
google_ad_slot = "6403511741";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<br />
</div>
<p class="information"><a href="http://dl.dropbox.com/u/4509565/FlexExamples_com/Spark_Path_stroke_joints_test/srcview/index.html">View source</a> is enabled in the following example.</p>
<p><iframe src="http://dl.dropbox.com/u/4509565/FlexExamples_com/Spark_Path_stroke_joints_test/main.html" width="100%" height="300"></iframe></p>
<p>You can also set the <code>joints</code> property using ActionScript, as seen in the following example:</p>

<div class="wp_syntax"><div class="code"><pre class="mxml" style="font-family:monospace;"><span style="color: #000000;">&lt;?xml version=<span style="color: #ff0000;">&quot;1.0&quot;</span> encoding=<span style="color: #ff0000;">&quot;utf-8&quot;</span>?<span style="color: #7400FF;">&gt;</span></span>
<span style="color: #000000;"><span style="color: #808080; font-style: italic;">&lt;!-- http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/ --&gt;</span></span>
<span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Application</span> name=<span style="color: #ff0000;">&quot;Spark_Path_stroke_joints_test&quot;</span></span>
<span style="color: #000000;">        xmlns:fx=<span style="color: #ff0000;">&quot;http://ns.adobe.com/mxml/2009&quot;</span> </span>
<span style="color: #000000;">        xmlns:s=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/spark&quot;</span> </span>
<span style="color: #000000;">        xmlns:mx=<span style="color: #ff0000;">&quot;library://ns.adobe.com/flex/mx&quot;</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:controlBarContent</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;mx:FormItem</span> label=<span style="color: #ff0000;">&quot;joints:&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:DropDownList</span> id=<span style="color: #ff0000;">&quot;comboBox&quot;</span></span>
<span style="color: #000000;">                        selectedIndex=<span style="color: #ff0000;">&quot;2&quot;</span></span>
<span style="color: #000000;">                        change=<span style="color: #ff0000;">&quot;comboBox_change(event);&quot;</span><span style="color: #7400FF;">&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:ArrayList</span><span style="color: #7400FF;">&gt;</span></span>
                            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:source</span><span style="color: #7400FF;">&gt;</span></span>
                                <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:String</span><span style="color: #7400FF;">&gt;</span></span>{JointStyle.BEVEL}<span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:String</span><span style="color: #7400FF;">&gt;</span></span>
                                <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:String</span><span style="color: #7400FF;">&gt;</span></span>{JointStyle.MITER}<span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:String</span><span style="color: #7400FF;">&gt;</span></span>
                                <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:String</span><span style="color: #7400FF;">&gt;</span></span>{JointStyle.ROUND}<span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:String</span><span style="color: #7400FF;">&gt;</span></span>
                            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:source</span><span style="color: #7400FF;">&gt;</span></span>
                        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:ArrayList</span><span style="color: #7400FF;">&gt;</span></span>
                    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:dataProvider</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:DropDownList</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:FormItem</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/mx:Form</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:controlBarContent</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #000000;">            import mx.events.ListEvent;</span>
<span style="color: #000000;">            import spark.events.IndexChangeEvent;</span>
&nbsp;
<span style="color: #000000;">            protected function comboBox_change<span style="color: #66cc66;">&#40;</span>evt:IndexChangeEvent<span style="color: #66cc66;">&#41;</span>:void <span style="color: #66cc66;">&#123;</span></span>
<span style="color: #000000;">                pathStroke.joints = comboBox.selectedItem.toString<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</span>
<span style="color: #000000;">            <span style="color: #66cc66;">&#125;</span></span>
<span style="color: #000000;">        <span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:Script</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:Declarations</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;fx:String</span> id=<span style="color: #ff0000;">&quot;pathData&quot;</span><span style="color: #7400FF;">&gt;</span></span>M 0 0 L 200 0 L 0 80 Z<span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:String</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/fx:Declarations</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Graphic</span> horizontalCenter=<span style="color: #ff0000;">&quot;0&quot;</span> verticalCenter=<span style="color: #ff0000;">&quot;0&quot;</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Path</span> id=<span style="color: #ff0000;">&quot;path&quot;</span> data=<span style="color: #ff0000;">&quot;{pathData}&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> id=<span style="color: #ff0000;">&quot;pathStroke&quot;</span></span>
<span style="color: #000000;">                        color=<span style="color: #ff0000;">&quot;red&quot;</span></span>
<span style="color: #000000;">                        weight=<span style="color: #ff0000;">&quot;40&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Path</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:Path</span> data=<span style="color: #ff0000;">&quot;{pathData}&quot;</span><span style="color: #7400FF;">&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
                <span style="color: #000000;"><span style="color: #7400FF;">&lt;s:SolidColorStroke</span> color=<span style="color: #ff0000;">&quot;black&quot;</span> weight=<span style="color: #ff0000;">&quot;1&quot;</span> <span style="color: #7400FF;">/&gt;</span></span>
            <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:stroke</span><span style="color: #7400FF;">&gt;</span></span>
        <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Path</span><span style="color: #7400FF;">&gt;</span></span>
    <span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Graphic</span><span style="color: #7400FF;">&gt;</span></span>
&nbsp;
<span style="color: #000000;"><span style="color: #7400FF;">&lt;/s:Application</span><span style="color: #7400FF;">&gt;</span></span></pre></div></div>

<p class="alert">This entry is based on a beta version of the Flex 4 SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex 4 SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the joint style on a Path stroke in Flex 4 on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/',contentID: 'post-928',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,joints,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/09/setting-the-joint-style-on-a-path-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Setting the origin X and Y coordinate for a linear gradient stroke in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Mon, 05 Jan 2009 07:42:11 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[GradientEntry]]></category>
		<category><![CDATA[LinearGradientStroke]]></category>
		<category><![CDATA[Rect]]></category>
		<category><![CDATA[entries]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[rotation]]></category>
		<category><![CDATA[stroke]]></category>
		<category><![CDATA[x]]></category>
		<category><![CDATA[y]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the origin X and Y coordinate for a linear gradient stroke in Flex Gumbo by setting the x and y properties on the LinearGradientStroke object.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the origin X and Y coordinate for a linear gradient stroke in Flex Gumbo by setting the <code>x</code> and <code>y</code> properties on the LinearGradientStroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-923"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_x_test/bin/srcview/source/main_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_x_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="x:"&gt;
                &lt;HSlider id="xSlider"
                        minimum="-100"
                        maximum="100"
                        value="0"
                        snapInterval="1"
                        tickInterval="25"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="y:"&gt;
                &lt;HSlider id="ySlider"
                        minimum="-100"
                        maximum="100"
                        value="0"
                        snapInterval="1"
                        tickInterval="25"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="rotation:"&gt;
                &lt;HSlider id="rotationSlider"
                        minimum="-360"
                        maximum="360"
                        value="0"
                        snapInterval="1"
                        tickInterval="45"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        x="{xSlider.value}"
                        y="{ySlider.value}"
                        rotation="{rotationSlider.value}"
                        weight="5"&gt;
                    &lt;GradientEntry color="red" /&gt;
                    &lt;GradientEntry color="white" /&gt;
                    &lt;GradientEntry color="blue" /&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_x_test/bin/srcview/">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_x_test/bin/main_4407.html" width="100%" height="350"></iframe></p>
<p>You can also set the LinearGradientStroke object&#8217;s <code>x</code>, <code>y</code>, and <code>rotation</code> properties using ActionScript, as seen in the following example:</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_x_test/bin/srcview/source/main2_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_x_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.SliderEvent;

            private function xSlider_change(evt:SliderEvent):void {
                linearGrad.x = evt.value;
            }

            private function ySlider_change(evt:SliderEvent):void {
                linearGrad.y = evt.value;
            }

            private function rotationSlider_change(evt:SliderEvent):void {
                linearGrad.rotation = evt.value;
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="x:"&gt;
                &lt;HSlider id="xSlider"
                        minimum="-100"
                        maximum="100"
                        value="0"
                        snapInterval="1"
                        tickInterval="25"
                        liveDragging="true"
                        change="xSlider_change(event);" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="y:"&gt;
                &lt;HSlider id="ySlider"
                        minimum="-100"
                        maximum="100"
                        value="0"
                        snapInterval="1"
                        tickInterval="25"
                        liveDragging="true"
                        change="ySlider_change(event);" /&gt;
            &lt;/FormItem&gt;
            &lt;FormItem label="rotation:"&gt;
                &lt;HSlider id="rotationSlider"
                        minimum="-360"
                        maximum="360"
                        value="0"
                        snapInterval="1"
                        tickInterval="45"
                        liveDragging="true"
                        change="rotationSlider_change(event);" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        x="{xSlider.value}"
                        y="{ySlider.value}"
                        rotation="{rotationSlider.value}"
                        weight="5"&gt;
                    &lt;GradientEntry color="red" /&gt;
                    &lt;GradientEntry color="white" /&gt;
                    &lt;GradientEntry color="blue" /&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the origin X and Y coordinate for a linear gradient stroke in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/',contentID: 'post-923',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'entries,Gumbo,rotation,stroke,x,y',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/04/setting-the-origin-x-and-y-coordinate-for-a-linear-gradient-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the rotation of a linear gradient stroke in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Sun, 04 Jan 2009 07:59:45 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[GradientEntry]]></category>
		<category><![CDATA[LinearGradientStroke]]></category>
		<category><![CDATA[Rect]]></category>
		<category><![CDATA[entries]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[rotation]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the angle of a LinearGradientStroke stroke on a Flex Gumbo Ellipse object by setting the rotation property on the LinearGradientStroke object.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the angle of a LinearGradientStroke stroke on a Flex Gumbo Ellipse object by setting the <code>rotation</code> property on the LinearGradientStroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-922"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_rotation_test/bin/srcview/source/main_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_rotation_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="rotation:"&gt;
                &lt;HSlider id="slider"
                        minimum="-360"
                        maximum="360"
                        value="0"
                        snapInterval="1"
                        tickInterval="45"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        rotation="{slider.value}"
                        weight="10"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_rotation_test/bin/srcview/">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_rotation_test/bin/main_4407.html" width="100%" height="300"></iframe></p>
<p>You can also set the <code>rotation</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_rotation_test/bin/srcview/source/main2_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_rotation_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.SliderEvent;

            private function slider_change(evt:SliderEvent):void {
                linearGrad.rotation = evt.value;
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="rotation:"&gt;
                &lt;HSlider id="slider"
                        minimum="-360"
                        maximum="360"
                        value="0"
                        snapInterval="1"
                        tickInterval="45"
                        liveDragging="true"
                        change="slider_change(event);" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        weight="10"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the rotation of a linear gradient stroke in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/',contentID: 'post-922',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'entries,Gumbo,rotation,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/03/setting-the-rotation-of-a-linear-gradient-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the miter limit on a stroke object in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/#comments</comments>
		<pubDate>Sat, 03 Jan 2009 06:42:07 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[GradientEntry]]></category>
		<category><![CDATA[LinearGradientStroke]]></category>
		<category><![CDATA[Rect]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[joints]]></category>
		<category><![CDATA[miterLimit]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the miter limit on a Flex Gumbo stroke by setting the miterLimit property on a stroke object.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the miter limit on a Flex Gumbo stroke by setting the <code>miterLimit</code> property on a stroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-921"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_miterLimit_test/bin/srcview/source/main_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_miterLimit_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="miterLimit:"&gt;
                &lt;HSlider id="slider"
                        minimum="0"
                        maximum="2"
                        tickInterval="0.5"
                        liveDragging="true" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        joints="miter"
                        miterLimit="{slider.value}"
                        weight="40"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_miterLimit_test/bin/srcview/">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_miterLimit_test/bin/main_4407.html" width="100%" height="350"></iframe></p>
<p>You can also set the <code>miterLimit</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_miterLimit_test/bin/srcview/source/main2_4407.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_miterLimit_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.SliderEvent;

            private function slider_change(evt:SliderEvent):void {
                linearGrad.miterLimit = slider.value;
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="miterLimit:"&gt;
                &lt;HSlider id="slider"
                        minimum="0"
                        maximum="2"
                        tickInterval="0.5"
                        liveDragging="true"
                        change="slider_change(event);" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        joints="miter"
                        weight="40"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the miter limit on a stroke object in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/',contentID: 'post-921',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,joints,miterLimit,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/02/setting-the-miter-limit-on-a-stroke-object-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Setting the joint style on a stroke in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/#comments</comments>
		<pubDate>Fri, 02 Jan 2009 05:57:21 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[JointStyle]]></category>
		<category><![CDATA[LinearGradientStroke]]></category>
		<category><![CDATA[Rect]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[joints]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set the joint style on a Flex Gumbo LinearGradientStroke object by setting the joints property to a static constant in the JointStyle class (flash.display.JointStyle).</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set the joint style on a Flex Gumbo LinearGradientStroke object by setting the <code>joints</code> property to a static constant in the JointStyle class (flash.display.JointStyle).</p>
<p>Full code after the jump.</p>
<p><span id="more-920"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_joints_test/bin/srcview/source/main_4423.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_joints_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="joints:"&gt;
                &lt;ComboBox id="comboBox"
                        dataProvider="[bevel,miter,round]" /&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        joints="{comboBox.selectedItem}"
                        weight="20"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_joints_test/bin/srcview/">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_joints_test/bin/main_4423.html" width="100%" height="300"></iframe></p>
<p>You can also set the <code>joints</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/LinearGradientStroke_joints_test/bin/srcview/source/main2_4423.mxml.html">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/ --&gt;
&lt;Application name="LinearGradientStroke_joints_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.events.ListEvent;

            private function comboBox_change(evt:ListEvent):void {
                linearGrad.joints = comboBox.selectedItem.toString();
            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;ApplicationControlBar dock="true"&gt;
        &lt;Form styleName="plain"&gt;
            &lt;FormItem label="joints:"&gt;
                &lt;ComboBox id="comboBox"
                        selectedIndex="2"
                        change="comboBox_change(event);"&gt;
                    &lt;dataProvider&gt;
                        &lt;Array&gt;
                            &lt;String&gt;{JointStyle.BEVEL}&lt;/String&gt;
                            &lt;String&gt;{JointStyle.MITER}&lt;/String&gt;
                            &lt;String&gt;{JointStyle.ROUND}&lt;/String&gt;
                        &lt;/Array&gt;
                    &lt;/dataProvider&gt;
                &lt;/ComboBox&gt;
            &lt;/FormItem&gt;
        &lt;/Form&gt;
    &lt;/ApplicationControlBar&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad"
                        weight="20"&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Setting the joint style on a stroke in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/',contentID: 'post-920',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'Gumbo,joints,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2009/01/01/setting-the-joint-style-on-a-stroke-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating a linear gradient stroke on a Rect object in Flex Gumbo</title>
		<link>http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/</link>
		<comments>http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/#comments</comments>
		<pubDate>Thu, 01 Jan 2009 07:46:20 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[beta]]></category>
		<category><![CDATA[FXG]]></category>
		<category><![CDATA[GradientEntry]]></category>
		<category><![CDATA[LinearGradientStroke]]></category>
		<category><![CDATA[Rect]]></category>
		<category><![CDATA[entries]]></category>
		<category><![CDATA[Gumbo]]></category>
		<category><![CDATA[stroke]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/</guid>
		<description><![CDATA[<p>The following example shows how you can set a linear gradient stroke on a Flex Gumbo Rect object by setting the stroke property to a LinearGradientStroke object.</p> <p>Full code after the jump.</p> <p></p> <p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder [...]]]></description>
			<content:encoded><![CDATA[<p>The following example shows how you can set a linear gradient stroke on a Flex Gumbo Rect object by setting the <code>stroke</code> property to a LinearGradientStroke object.</p>
<p>Full code after the jump.</p>
<p><span id="more-919"></span></p>
<p class="alert">To use the following code, you must have Flash Player 10 and a Flex Gumbo SDK installed in your Flex Builder 3. For more information on downloading and installing the Gumbo SDK into Flex Builder 3, see <a href="http://blog.flexexamples.com/2008/08/02/using-the-beta-gumbo-sdk-in-flex-builder-3/">&#8220;Using the beta Gumbo SDK in Flex Builder 3&#8243;</a>.</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/ --&gt;
&lt;Application name="Rect_stroke_LinearGradientStroke_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke&gt;
                    &lt;entries&gt;
                        &lt;GradientEntry color="red" /&gt;
                        &lt;GradientEntry color="white" /&gt;
                        &lt;GradientEntry color="blue" /&gt;
                    &lt;/entries&gt;
                &lt;/LinearGradientStroke&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p>You can also set the LinearGradientStroke object&#8217;s <code>entries</code> property using data binding, as seen in the following example:</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/ --&gt;
&lt;Application name="Rect_stroke_LinearGradientStroke_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Declarations&gt;
        &lt;Array id="arr"&gt;
            &lt;GradientEntry color="red" /&gt;
            &lt;GradientEntry color="white" /&gt;
            &lt;GradientEntry color="blue" /&gt;
        &lt;/Array&gt;
    &lt;/Declarations&gt;

    &lt;Graphic&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke entries="{arr}" /&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p>Or, you can set the LinearGradientStroke object&#8217;s <code>entries</code> property using ActionScript, as seen in the following example:</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/ --&gt;
&lt;Application name="Rect_stroke_LinearGradientStroke_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.graphics.GradientEntry;

            private var arr:Array;

            private function init():void {
                arr = [];
                arr.push(new GradientEntry(0xFF0000));
                arr.push(new GradientEntry(0xFFFFFF));
                arr.push(new GradientEntry(0x0000FF));
                linearGrad.entries = arr;

            }
        ]]&gt;
    &lt;/Script&gt;

    &lt;Graphic creationComplete="init();"&gt;
        &lt;Rect id="rect" width="300" height="200"&gt;
            &lt;stroke&gt;
                &lt;LinearGradientStroke id="linearGrad" /&gt;
            &lt;/stroke&gt;
        &lt;/Rect&gt;
    &lt;/Graphic&gt;

&lt;/Application&gt;
</pre>
<p>Due to popular demand, here is the &#8220;same&#8221; example in a more ActionScript friendly format:</p>
<p class="download"><a href="">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/ --&gt;
&lt;Application name="Rect_stroke_LinearGradientStroke_test"
        xmlns="http://ns.adobe.com/mxml/2009"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"
        initialize="init();"&gt;

    &lt;Script&gt;
        &lt;![CDATA[
            import mx.graphics.GradientEntry;
            import mx.graphics.Graphic;
            import mx.graphics.LinearGradientStroke;
            import mx.graphics.Rect;

            private var arr:Array;
            private var rect:Rect;
            private var linearGrad:LinearGradientStroke;

            private function init():void {
                arr = [];
                arr.push(new GradientEntry(0xFF0000));
                arr.push(new GradientEntry(0xFFFFFF));
                arr.push(new GradientEntry(0x0000FF));

                linearGrad = new LinearGradientStroke();
                linearGrad.entries = arr;

                rect = new Rect();
                rect.stroke = linearGrad;
                rect.width = 300;
                rect.height = 200;

                var gr:Graphic = new Graphic();
                gr.addElement(rect);
                addChild(gr);
            }
        ]]&gt;
    &lt;/Script&gt;

&lt;/Application&gt;
</pre>
<p class="alert">This entry is based on a beta version of the Flex Gumbo SDK and therefore is very likely to change as development of the Flex SDK continues. The API can (and will) change causing examples to possibly not compile in newer versions of the Flex Gumbo SDK.</p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Creating a linear gradient stroke on a Rect object in Flex Gumbo on FlexExamples.com',url: 'http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/',contentID: 'post-919',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'entries,Gumbo,stroke',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2008/12/31/creating-a-linear-gradient-stroke-on-a-rect-object-in-flex-gumbo/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

