title: How do you add a stroke to text?
body: <p>How do I add a stroke to text in Flex 4? Specifically I'd like to add it to a Label (the text will change in it). </p>
  
  <p><strong>Update</strong><br>
  The closest solution suggested has been to add a drop shadow filter as shown below. I've added a rectangle with a stroke for comparison. If the stroke weight is between 2 to 3 it's acceptable. If it's above or below that then it's too blurry or rough. In my case I need to support 2 to 6 weight.    </p>
  
  <p>A follow up question would be is it possible to create a stroke filter through Pixel Bender. </p>
  
  <pre><code>&lt;s:VGroup&gt;
  
  &lt;s:Label text="Select an example on the left. Right-click to view source." 
           color="#FF8C00"
           top="10" left="10"
           fontSize="25"&gt;
      &lt;s:filters&gt;
          &lt;s:DropShadowFilter blurX="2" blurY="2" distance="0" quality="1" strength="10" color="#000000"/&gt;
      &lt;/s:filters&gt;
  &lt;/s:Label&gt;
  
  &lt;s:Rect width="100%" radiusX="8" radiusY="8"
          height="18"&gt;
      &lt;s:fill&gt;
          &lt;s:SolidColor color="#FF8C00"/&gt;
      &lt;/s:fill&gt;
      &lt;s:stroke&gt;
          &lt;s:SolidColorStroke weight="1" /&gt;
      &lt;/s:stroke&gt;
  &lt;/s:Rect&gt;
  
  &lt;s:Label text="Select an example on the left. Right-click to view source." 
           color="#FF8C00"
           top="10" left="10"
           fontSize="25"&gt;
      &lt;s:filters&gt;
          &lt;s:DropShadowFilter blurX="4" blurY="4" distance="0" quality="1" strength="10" color="#000000"/&gt;
      &lt;/s:filters&gt;
  &lt;/s:Label&gt;
  
  &lt;s:Rect width="100%" radiusX="8" radiusY="8"
          height="18"&gt;
      &lt;s:fill&gt;
          &lt;s:SolidColor color="#FF8C00"/&gt;
      &lt;/s:fill&gt;
      &lt;s:stroke&gt;
          &lt;s:SolidColorStroke weight="2" /&gt;
      &lt;/s:stroke&gt;
  &lt;/s:Rect&gt;
  
  &lt;s:Label text="Select an example on the left. Right-click to view source." 
           color="#FF8C00"
           top="10" left="10"
           fontSize="25"&gt;
      &lt;s:filters&gt;
          &lt;s:DropShadowFilter blurX="6" blurY="6" distance="0" quality="1" strength="10" color="#000000"/&gt;
      &lt;/s:filters&gt;
  &lt;/s:Label&gt;
  
  &lt;s:Rect width="100%" radiusX="8" radiusY="8"
          height="18"&gt;
      &lt;s:fill&gt;
          &lt;s:SolidColor color="#FF8C00"/&gt;
      &lt;/s:fill&gt;
      &lt;s:stroke&gt;
          &lt;s:SolidColorStroke weight="3" /&gt;
      &lt;/s:stroke&gt;
  &lt;/s:Rect&gt;
  
  &lt;s:Label text="Select an example on the left. Right-click to view source." 
           color="#FF8C00"
           top="10" left="10"
           fontSize="25"&gt;
      &lt;s:filters&gt;
          &lt;s:DropShadowFilter blurX="8" blurY="8" distance="0" quality="1" strength="10" color="#000000"/&gt;
      &lt;/s:filters&gt;
  &lt;/s:Label&gt;
  
  &lt;s:Rect width="100%" radiusX="8" radiusY="8"
          height="18"&gt;
      &lt;s:fill&gt;
          &lt;s:SolidColor color="#FF8C00"/&gt;
      &lt;/s:fill&gt;
      &lt;s:stroke&gt;
          &lt;s:SolidColorStroke weight="4" /&gt;
      &lt;/s:stroke&gt;
  &lt;/s:Rect&gt;
  
  &lt;/s:VGroup&gt;
  </code></pre>