<?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>Mozilla Hacks - the Web developer blog &#187; Frederic Wenzel</title>
	<atom:link href="http://hacks.mozilla.org/author/fwenzel/feed/" rel="self" type="application/rss+xml" />
	<link>http://hacks.mozilla.org</link>
	<description>hacks.mozilla.org</description>
	<lastBuildDate>Wed, 08 Feb 2012 22:52:35 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>shadow boxing with -moz-box-shadow</title>
		<link>http://hacks.mozilla.org/2009/06/moz-box-shadow/</link>
		<comments>http://hacks.mozilla.org/2009/06/moz-box-shadow/#comments</comments>
		<pubDate>Fri, 12 Jun 2009 12:00:03 +0000</pubDate>
		<dc:creator>Frederic Wenzel</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Feature]]></category>

		<guid isPermaLink="false">http://hacks.mozilla.org/?p=202</guid>
		<description><![CDATA[Another fun CSS3 feature that&#8217;s been implemented in Firefox 3.5 is box shadows. This feature allows the casting of a drop &#8220;shadow&#8221; from the frame of almost any arbitrary element. As the CSS3 box shadow property is still a work in progress, however, it&#8217;s been implemented as -moz-box-shadow in Firefox. This is how Mozilla tests [...]]]></description>
			<content:encoded><![CDATA[<p>Another fun CSS3 feature that&#8217;s been implemented in Firefox 3.5 is box shadows. This feature allows the casting of a drop &#8220;shadow&#8221; from the frame of almost any arbitrary element.</p>
<p>As the CSS3 box shadow property is still a work in progress, however, it&#8217;s been implemented as <code>-moz-box-shadow</code> in Firefox.  This is how Mozilla tests experimental properties in CSS, with property names prefaced with &#8220;-moz-&#8221;.  When the specification is finalized, the property will be named &#8220;box-shadow.&#8221;</p>
<p><strong>How it works</strong></p>
<p>Applying a box shadow to an element is straightforward. The <a href="http://dev.w3.org/csswg/css3-background/#the-box-shadow">CSS3 standard</a> allows as its value:</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">none | &lt;shadow&gt; [ &lt;shadow&gt; ]*</pre></div></div>

<p>where <code>&lt;shadow&gt;</code> is:</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">&lt;shadow&gt; = inset? &amp;&amp; [ &lt;length&gt;{2,4} &amp;&amp; &lt;color&gt;? ]</pre></div></div>

<p>The first two lengths are the <em>horizontal and vertical offset</em> of the shadow, respectively. The third length is the <em>blur radius</em> (compare that to the blur radius in in the <a href="http://hacks.mozilla.org/2009/06/text-shadow/">text-shadow property</a>). Finally the fourth length is the <em>spread radius</em>, allowing the shadow to grow (positive values) or shrink (negative values) compared to the size of the parent element.</p>
<p>The <code>inset</code> keyword is pretty well explained by the standard itself:<br />
<blockquote>if present, [it] changes the drop shadow from an outer shadow (one that shadows the box onto the canvas, as if it were lifted above the canvas) to an inner shadow (one that shadows the canvas onto the box, as if the box were cut out of the canvas and shifted behind it).</p></blockquote>
<p>But talk is cheap, let&#8217;s look at some examples.</p>
<p>To draw a simple shadow, just define an offset and a color, and off you go:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"> -moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">10px</span> <span style="color: #cc00cc;">#00f</span><span style="color: #00AA00;">;</span></pre></div></div>

<p><span style="display:block; width:150px; height:50px; border:1px solid black; background-color: #00f; -moz-box-shadow: 1px 1px 10px #00f;">&nbsp;</span></p>
<p><img src="https://wiki.mozilla.org/images/6/60/35days-box-shadow-simple.jpg" alt="simple box shadow" /></p>
<p>(Each of the examples in this article are live examples first, followed by a screen shot from Firefox 3.5 on OSX).</p>
<p>Similarly, you can draw an in-set shadow with the aforementioned keyword.</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;">-moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #993333;">inset</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">10px</span> <span style="color: #cc00cc;">#888</span><span style="color: #00AA00;">;</span></pre></div></div>

<p><span style="display:block; width:150px; height:50px; border:1px solid black; background-color: #fff; -moz-box-shadow: inset 1px 1px 10px #888;">&nbsp;</span></p>
<p><img src="https://wiki.mozilla.org/images/f/f4/35days-box-shadow-inset.jpg" alt="inset box shadow" /></p>
<p>With the help of a <em>spread radius</em>, you can define smaller (or bigger) shadows than the element it is applied to:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;">-moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">0px</span> <span style="color: #933;">20px</span> <span style="color: #933;">10px</span> <span style="color: #933;">-10px</span> <span style="color: #cc00cc;">#888</span><span style="color: #00AA00;">;</span></pre></div></div>

<p><span style="display:block; width:150px; height:50px; border:1px solid black; background-color: #fff; margin:30px; -moz-box-shadow: 0px 20px 10px -10px #888;">&nbsp;</span></p>
<p><img src="https://wiki.mozilla.org/images/4/4c/35days-box-shadow-spread.jpg" alt="box shadow with spread radius" /></p>
<p>If you want, you can also define multiple shadows by defining several shadows, separated by commas (courtesy of <a href="http://markusstange.wordpress.com/2009/02/15/fun-with-box-shadows/">Markus Stange</a>):</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;">-moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #933;">20px</span> <span style="color: #000000; font-weight: bold;">black</span><span style="color: #00AA00;">,</span> <span style="color: #933;">20px</span> <span style="color: #933;">15px</span> <span style="color: #933;">30px</span> <span style="color: #993333;">yellow</span><span style="color: #00AA00;">,</span> <span style="color: #933;">-20px</span> <span style="color: #933;">15px</span> <span style="color: #933;">30px</span> <span style="color: #993333;">lime</span><span style="color: #00AA00;">,</span> <span style="color: #933;">-20px</span> <span style="color: #933;">-15px</span> <span style="color: #933;">30px</span> <span style="color: #000000; font-weight: bold;">blue</span><span style="color: #00AA00;">,</span> <span style="color: #933;">20px</span> <span style="color: #933;">-15px</span> <span style="color: #933;">30px</span> <span style="color: #993333;">red</span><span style="color: #00AA00;">;</span></pre></div></div>

<p><span style="display:block; width:150px; height:50px; border:1px solid black; background-color: #fff; margin:50px; -moz-box-shadow: 0 0 20px black, 20px 15px 30px yellow, -20px 15px 30px lime, -20px -15px 30px blue, 20px -15px 30px red;">&nbsp;</span></p>
<p><img src="https://wiki.mozilla.org/images/3/30/35days-box-shadow-multiple.jpg" alt="multiple box shadows" /></p>
<p>The different shadows blend into each other very smoothly, and as you may have noticed, the order in which they are defined does make a difference. As <code>box-shadow</code> is a CSS3 feature, Firefox&nbsp;3.5 adheres to the CSS3 painting order. That means, the first specified shadow shows up <em>on top</em>, so keep that in mind when designing multiple shadows.</p>
<p>As a final example, I want to show you the combination of <code>-moz-box-shadow</code> with an <a href="http://www.w3.org/TR/css3-color/#rgba-color">RGBA color definition</a>. RGBA is the same as RGB, but it adds an alpha-channel transparency to change the opacity of the color. Let&#8217;s make a black, un-blurred box shadow with an opacity of 50 percent, on a yellow background:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;">-moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #993333;">inset</span> <span style="color: #933;">5px</span> <span style="color: #933;">5px</span> <span style="color: #cc66cc;">0</span> rgba<span style="color: #00AA00;">&#40;</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">,</span> .5<span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span></pre></div></div>

<p><span style="display:block; width:150px; height:50px; border:1px solid black; background-color: yellow; -moz-box-shadow: inset 5px 5px 0 rgba(0, 0, 0, .5);">&nbsp;</span></p>
<p><img src="https://wiki.mozilla.org/images/e/ea/35days-box-shadow-rgba.jpg" alt="box shadow with RGBA" /></p>
<p>As you can see, the yellow background is visible though the half-transparent shadow without further ado. This feature becomes particularly interesting when background images are involved, as you&#8217;ll be able to see them shining through the box shadow.</p>
<p><strong>Cross-Browser Compatibility</strong></p>
<p>As a newer, work-in-progress CSS3 property, box-shadow has not yet been widely adopted by browser makers.</p>
<ul>
<li>Firefox 3.5 supports the feature as <code>-moz-box-shadow</code>, as well as multiple shadows, the <code>inset</code> keyword and a spread radius.</li>
<li>Safari/WebKit has gone down a similar route as Firefox by implementing the feature as <code>-webkit-box-shadow</code>. Multiple shadows are supported since version 4.0, while neither inset shadows nor the spread radius feature are supported yet in WebKit.</li>
<li>Finally, Opera and Microsoft Internet Explorer have not yet implemented the box shadow property, though in MSIE you may want to check out their proprietary <a href="http://msdn.microsoft.com/en-us/library/ms532985(VS.85).aspx">DropShadow filter</a>.</li>
</ul>
<p>To achieve the biggest possible coverage, it is advisable to define all three, the <code>-moz</code>, <code>-webkit</code>, and standard CSS3 syntax in parallel. Applicable browsers will then pick and adhere to the ones they support. For example:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"> -moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">10px</span> <span style="color: #cc00cc;">#00f</span><span style="color: #00AA00;">;</span>
 -webkit-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">10px</span> <span style="color: #cc00cc;">#00f</span><span style="color: #00AA00;">;</span>
 box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">10px</span> <span style="color: #cc00cc;">#00f</span><span style="color: #00AA00;">;</span></pre></div></div>

<p>The good news is that the <code>box-shadow</code> property degrades gracefully on unsupported browsers. For example, all the examples above will look like plain and boring boxes with no shadow in MSIE.</p>
<p><strong>Conclusions</strong></p>
<p>The CSS3 <code>box-shadow</code> property is not yet as widely available in browsers (and therefore, to users) as, for example, the <code>text-shadow</code> property, but with the limited box shadow support of WebKit as well as the full support provided by Firefox 3.5 (as far as the current status of the feature draft is concerned), more and more users will be able to see some level of CSS box shadows.</p>
<p>As a web developer, you can therefore use the feature, confident that you are giving users with modern browsers an improved experience while not turning away users with older browsers.</p>
<p><strong>Further resources</strong><br />
<strong>Documentation</strong></p>
<ul>
<li><a href="https://developer.mozilla.org/en/CSS/-moz-box-shadow">https://developer.mozilla.org/en/CSS/-moz-box-shadow</a></li>
<li><a href="http://dev.w3.org/csswg/css3-background/#the-box-shadow">http://dev.w3.org/csswg/css3-background/#the-box-shadow</a></li>
</ul>
<p><strong>Examples</strong></p>
<ul>
<li><a href="http://markusstange.wordpress.com/2009/02/15/fun-with-box-shadows/">http://markusstange.wordpress.com/2009/02/15/fun-with-box-shadows/</a></li>
<li><a href="http://www.css3.info/preview/box-shadow/">http://www.css3.info/preview/box-shadow/</a></li>
<li><a href="http://www.elektronotdienst-nuernberg.de/bugs/box-shadow_inset.html">http://www.elektronotdienst-nuernberg.de/bugs/box-shadow_inset.html</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://hacks.mozilla.org/2009/06/moz-box-shadow/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>stylish text with text-shadow</title>
		<link>http://hacks.mozilla.org/2009/06/text-shadow/</link>
		<comments>http://hacks.mozilla.org/2009/06/text-shadow/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 13:37:13 +0000</pubDate>
		<dc:creator>Frederic Wenzel</dc:creator>
				<category><![CDATA[35 Days]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Feature]]></category>
		<category><![CDATA[Firefox 3.5]]></category>

		<guid isPermaLink="false">http://hacks.mozilla.org/?p=128</guid>
		<description><![CDATA[This post is from Frederic Wenzel, who works on Mozilla&#8217;s Web Development team. The text-shadow CSS property does what the name implies: It lets you create a slightly blurred, slightly moved copy of text, which ends up looking somewhat like a real-world shadow. The text-shadow property was first introduced in CSS2, but as it was [...]]]></description>
			<content:encoded><![CDATA[<p><em>This post is from <a href="http://fredericiana.com/">Frederic Wenzel</a>, who works on Mozilla&#8217;s Web Development team.</em></p>
<p>The <em>text-shadow</em> CSS property does what the name implies: It lets you create a slightly blurred, slightly moved copy of text, which ends up looking somewhat like a real-world shadow.</p>
<p>The <em>text-shadow</em> property was first introduced in CSS2, but as it was improperly defined at the time, its support was dropped again in CSS2.1. The feature was re-introduced with CSS3 and has now <a href="https://developer.mozilla.org/en/CSS/text-shadow">made it into Firefox 3.5</a>.</p>
<p><strong>How it Works</strong></p>
<p>According to the CSS3 specification, the text-shadow property can have the following values:</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">none | [&lt;shadow&gt;, ] * &lt;shadow&gt;,</pre></div></div>

<p>&lt;shadow&gt; is defined as:</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">[ &lt;color&gt;? &lt;length&gt; &lt;length&gt; &lt;length&gt;? | &lt;length&gt; &lt;length&gt; &lt;length&gt;? &lt;color&gt;? ],</pre></div></div>

<p>where the first two lengths represent the horizontal and vertical offset and the third an optional blur radius. The best way to describe it is with examples.</p>
<p>We can make a simple shadow like this, for example:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span> <span style="color: #933;">2px</span> <span style="color: #933;">2px</span> <span style="color: #933;">3px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span></pre></div></div>

<div style="padding: 10px">
<div style="width: 233px; height: 43px; line-height: 43px; text-align: center; color: #000; background: #fff; font-size: 200%; text-shadow: 2px 2px 3px #000;">
A simple shadow
</div>
<p><img src="https://wiki.mozilla.org/images/4/47/35days-text-shadow-simple.jpg"/>
</div>
<p>(All of the examples are a live example first, then a picture of the working feature &#8212; so you can compare your browser&#8217;s behavior with the one of Firefox 3.5 on OSX)</p>
<p>If you are a fan of hard edges, you can just refrain from using a blur radius altogether:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span> <span style="color: #933;">2px</span> <span style="color: #933;">2px</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc00cc;">#888</span><span style="color: #00AA00;">;</span></pre></div></div>

<div style="padding: 10px">
<div style="width: 226px; height: 40px; line-height: 40px; text-align: center; color: #000; background: #fff; font-size: 200%; text-shadow: 2px 2px 0 #888;">
I don&#8217;t like blurs
</div>
<p><img src="https://wiki.mozilla.org/images/0/0e/35days-text-shadow-noblur.jpg"/>
</div>
<p><strong>Glowing text, and multiple shadows</strong></p>
<p>But due to the flexibility of the feature, the fun does not stop here. By varying the text offset, blur radius, and of course the color, you can achieve various effects, a mysterious glow for example:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"> <span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">5px</span> <span style="color: #cc00cc;">#fff</span><span style="color: #00AA00;">;</span></pre></div></div>

<div style="padding: 10px">
<div style="width: 181px; height: 49px; line-height: 49px; text-align: center; color: #fff; background: #000; font-size: 200%; text-shadow: 1px 1px 5px #fff;">
Glowing text</div>
<p><img src="https://wiki.mozilla.org/images/d/de/35days-text-shadow-glowing.jpg"/> </div>
<p>or a simple, fuzzy blur:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span> <span style="color: #933;">0px</span> <span style="color: #933;">0px</span> <span style="color: #933;">5px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span></pre></div></div>

<div style="padding: 10px">
<div style="width: 164px; height: 49px; line-height: 49px; text-align: center; color: #000; background: #fff; font-size: 200%; text-shadow: 0px 0px 5px #000;">
Blurry text
</div>
<p><img src="https://wiki.mozilla.org/images/2/25/35days-text-shadow-blurry.jpg"/>
</div>
<p>Finally, you can add &#8221;more than one shadow&#8221;, allowing you to create pretty &#8220;hot&#8221; effects (courtesy of <a href="http://www.css3.info/preview/text-shadow/ css3.info">http://www.css3.info/preview/text-shadow/ css3.info</a>):</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #933;">4px</span> <span style="color: #993333;">white</span><span style="color: #00AA00;">,</span> <span style="color: #cc66cc;">0</span> <span style="color: #933;">-5px</span> <span style="color: #933;">4px</span> <span style="color: #cc00cc;">#FFFF33</span><span style="color: #00AA00;">,</span> <span style="color: #933;">2px</span> <span style="color: #933;">-10px</span> <span style="color: #933;">6px</span> <span style="color: #cc00cc;">#FFDD33</span><span style="color: #00AA00;">,</span> <span style="color: #933;">-2px</span> <span style="color: #933;">-15px</span> <span style="color: #933;">11px</span> <span style="color: #cc00cc;">#FF8800</span><span style="color: #00AA00;">,</span> <span style="color: #933;">2px</span> <span style="color: #933;">-25px</span> <span style="color: #933;">18px</span> <span style="color: #cc00cc;">#FF2200</span></pre></div></div>

<div style="padding: 15px">
<div style="width: 356px; height: 53px; text-align: center; line-height: 58px; color: #fff; background: #000; font-size: 200%; padding-top:5px; text-shadow:0 0 4px white, 0 -5px 4px #FFFF33, 2px -10px 6px #FFDD33, -2px -15px 11px #FF8800, 2px -25px 18px #FF2200">
Multiple shadows are hot
</div>
<p><img src="https://wiki.mozilla.org/images/d/d9/35days-text-shadow-fire.jpg"/> </div>
<p>The number of <em>text-shadow</em>s you can apply at the same time in Firefox 3.5 is &#8212; in theory &#8212; unlimited, though you may want to stick with a reasonable amount. Like all CSS properties, you can modify <em>text-shadow</em> on the fly using JavaScript: </p>
<div style="color: #fff; background: #000; font-size: 200%; padding:20px; text-align: center" id="animationtext">
Animated shadows with JavaScript
</div>
<p><script type="text/javascript">
<!--
var textshadow = {
  colors: [ '#f00', '#0f0', '#00f' ],
  shadows: [ '0 -10px 2px', '10px 10px 2px', '-10px 10px 2px' ],
  state: [0, 1, 2],
  animate: function() {
    var t = document.getElementById("animationtext");
    var s = '';
    for (var i = 0; i < 3; i++)
    {
      if (s) s += ", ";
      var myshadows = this.shadows[this.state[i]]; s += myshadows + ' ' + this.colors[i];
      this.state[i] = ++this.state[i] % 3; /* rotate */
    }
    t.style.textShadow = s;
  },
  toggleAnimation: function() {
    if (this.handle) {
      window.clearInterval(this.handle);
      this.handle = false;
      var t = document.getElementById('animationtext');
      t.style.textShadow = '';
      }
  else {
    this.handle = window.setInterval(function() { textshadow.animate(); }, 100); } return false;
  }
} 
//--></script></p>
<div style="font-size: 120%; text-align: center; font-weight: bold">
<a href="#" onclick="textshadow.toggleAnimation();return false;"><br />
Start/stop animation</a>
</div>
<p><strong>Performance, Accessibility and Cross-Browser Compatibility</strong></p>
<p>The times of using pictures (or even worse, Flash) for text shadows on the web are numbered for two reasons:</p>
<p>First, there are significant advantages to using text instead of pictures. Not using pictures saves on bandwidth and HTTP connection overhead. Accessibility, both for people who use screen readers and search engines, is greatly improved. And page zoom will work better because the text can be scaled instead of using pixel interpolation to scale up an image.</p>
<p>Second this feature is largely cross-browser compatible:</p>
<ul>
<li>Opera supports <em>text-shadow</em> since version 9.5. According to the <a href="https://developer.mozilla.org/en/CSS/text-shadow">Mozilla Developer Center</a>, Opera 9.x supports up to 6 shadows on the same element.
<li>Safari has had the feature since version 1.1 (and other WebKit-based browsers along with it).
<li>Internet Explorer does not support the <em>text-shadow</em> property, but the feature degrades gracefully to regular text. In addition, if you want to emulate some of the <em>text-shadow</em> functionality in MSIE, you can use Microsoft&#8217;s proprietary <a href="http://msdn.microsoft.com/en-us/library/ms673539%28VS.85%29.aspx">&#8221;Shadow&#8221; and &#8221;DropShadow&#8221; filters</a>.
<li>Similarly to MSIE, when other, older browsers do not support the feature (including Firefox 3 and older), they will just show the regular text without any shadows.
</ul>
<p>A caveat worth mentioning is the &#8221;drawing order&#8221;: While Opera 9.x adheres to the CSS2 painting order (i.e., the first specified shadow is drawn at the bottom), Firefox 3.5 adheres to the CSS3 painting order (the first specified shadow is on top). Keep this in mind when drawing multiple shadows.</p>
<p><strong>Conclusions</strong></p>
<p><em>text-shadow</em> is a subtle but powerful CSS feature that is &#8212; now that it is supported by Firefox 3.5 &#8212; likely to be widely adopted across the web in the foreseeable future. Due to its graceful degradation in older browsers, it can safely be used by developers and will, over time, be seen by more and more users.</p>
<p>Finally, some words of wisdom: Like any eye candy, use it like salt in a soup &#8212; with moderation, not by the bucket. If the web developers of the world overdo it, <em>text-shadow</em> may die a short, yet painful death. It would be sad if we make users flinch at the sight of text shadows like <a href="http://xkcd.com/590/">typography geeks at the sight of &#8220;Papyrus&#8221;</a>, and thus needed to bury the feature deeply in our treasure chest.</p>
<p>That being said: <span style="text-shadow:3px 3px 3px #888;">Go try it out!</span></p>
<p><strong>Further resources</strong></p>
<p>Documentation</p>
<ul>
<li><a href="https://developer.mozilla.org/en/CSS/text-shadow">https://developer.mozilla.org/en/CSS/text-shadow</a>
<li><a href="http://www.quirksmode.org/css/textshadow.html">http://www.quirksmode.org/css/textshadow.html</a>
<li><a href="http://www.w3.org/TR/css3-text/#text-shadow">http://www.w3.org/TR/css3-text/#text-shadow</a>
</ul>
<p>Examples</p>
<ul>
<li><a href="http://maettig.com/code/css/text-shadow.html">http://maettig.com/code/css/text-shadow.html</a>
<li><a href="http://www.kremalicious.com/2008/04/make-cool-and-clever-text-effects-with-css-text-shadow/">http://www.kremalicious.com/2008/04/make-cool-and-clever-text-effects-with-css-text-shadow/</a>
<li><a href="https://bug10713.bugzilla.mozilla.org/attachment.cgi?id=273985">https://bug10713.bugzilla.mozilla.org/attachment.cgi?id=273985</a>
<li><a href="https://bug10713.bugzilla.mozilla.org/attachment.cgi?id=197360">https://bug10713.bugzilla.mozilla.org/attachment.cgi?id=197360</a>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://hacks.mozilla.org/2009/06/text-shadow/feed/</wfw:commentRss>
		<slash:comments>23</slash:comments>
		</item>
	</channel>
</rss>

