<?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>beThinker Concepts - Knowledge in many different ways &#187; Scalable Inman Flash Replacement</title>
	<atom:link href="http://www.bethinkerconcepts.com/category/sifr/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.bethinkerconcepts.com</link>
	<description>beThinkerConcepts.com is a variaty of tutorials that help improve those beginner in web development.</description>
	<lastBuildDate>Mon, 29 Mar 2010 14:17:46 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Embedding Fonts using sIFR 3</title>
		<link>http://www.bethinkerconcepts.com/2009/06/embedding-fonts/</link>
		<comments>http://www.bethinkerconcepts.com/2009/06/embedding-fonts/#comments</comments>
		<pubDate>Sun, 21 Jun 2009 15:15:52 +0000</pubDate>
		<dc:creator>beThinker</dc:creator>
				<category><![CDATA[Scalable Inman Flash Replacement]]></category>
		<category><![CDATA[Embedding]]></category>
		<category><![CDATA[Font]]></category>
		<category><![CDATA[Replacement]]></category>

		<guid isPermaLink="false">http://www.bethinkerconcepts.com/?p=65</guid>
		<description><![CDATA[What is sIFR?
Scalable Inman Flash Replacement (sIFR) is a technology that allows you to replace text elements on screen with Flash equivalents. sIFR lets you use your favorite font on the website without the user having it installed in their computer and by cleverly working with Flash, JavaScript and CSS.
sIFR requires JavaScript to be enabled [...]]]></description>
			<content:encoded><![CDATA[<p><strong>What is sIFR?</strong></p>
<p><strong>Scalable Inman Flash Replacement (sIFR)</strong> is a technology that allows you to replace text elements on screen with Flash equivalents. sIFR lets you use your favorite font on the website without the user having it installed in their computer and by cleverly working with <strong>Flash</strong>, <strong>JavaScript</strong> and <strong>CSS</strong>.</p>
<p>sIFR requires JavaScript to be enabled and the Flash player plugin in the reading browser. If either the two condition is not present then the reader&#8217;s browser will automatically display the traditional way using CSS based styling, the user will not notice or know the difference.</p>
<p><span id="more-65"></span><br />
Before will begin this tutorial, please note that you&#8217;ll need the <a title="Adobe" href="http://www.adobe.com/products/flash/" target="_blank">Flash 8 Editor</a> in order to export the Flash movies. To help get up and running quickly see the details in <a href="http://wiki.novemberborn.net/sifr3/Flash+Configuration" target="_blank">Flash Configuration</a> and <a href="http://wiki.novemberborn.net/sifr3/JavaScript+Configuration" target="_blank">JavaScript Configuration</a>.</p>
<p>Download the latest sIFR release, <a href="http://www.bethinkerconcepts.com/downloads/sifr3-r436.zip">click here</a>.</p>
<p>Now to export new typeface, open the sifr.fla in Flash Professional and double click the visible Movie Clip then inside that movieclip there is a dynamic text then click that one. If the &#8220;Properties&#8221; palette is not already visible, open it by selecting &#8220;Windows &gt; Properties&#8221;, and select your desire font. You can also create bold and italic styles for you font by clicking on the &#8220;I&#8221; or &#8220;B&#8221; buttons. To export the swf file, choose &#8220;File &gt; Export &gt; Export Movie&#8221;, and save as yourfontname.swf. Maker sure to export as Flash 6!.</p>
<p>If you don&#8217;t have a Flash Professional then you can also try the sIFR Font Embedder for Window or <a href="http://ajaxian.com/archives/opensifr-tool-to-generate-font-files" target="_blank">OpensIFR</a> for Mac OS X (this is also work in Windows).</p>
<p><strong>Applying CSS print styles</strong></p>
<p>Copy and paste the CSS rules found in the sIFR-print.css to you own print style sheet. These ensure that your original headline styling will be printed, rather that the Flash replacements.</p>
<p><strong>Applying CSS screen style</strong></p>
<p>Apply the styles in the sIFR-screeen.css file with your own screen style sheet. These are the styles wich will be applied by the Javascript if Flash is found to be present on the user&#8217;s browser.</p>
<p><strong>Including the Javascript</strong></p>
<p>You must call the sifr.js script on any page that will be replacing headlines. Include the following line after the begin of the &#8220;&lt;head&gt;&#8221; tag or before the closing tag of the &lt;/head&gt;, below is the code:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;script src=&quot;sifr.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;</div></td></tr></tbody></table></div>
<p>Now, to embed your font copy also the sifr-config.js and put it to the path of sifr.js. Then call the file, the same what we did in sifr.js. Edit the sifr-config.js then change the variable name and the source. For example will use Zafino font, so the code should look like this:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">var zafino = {src:'/path/to/zafino.swf'};</div></td></tr></tbody></table></div>
<p>Remember try using the font name as the variable name, it is easy to remember which object you&#8217;re using. Next is to activate the sIFR. Put this code below the variable name:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">sIFR.activate(zafino);</div></td></tr></tbody></table></div>
<p>You can also use multiple movies, like so:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">var zafino = {src:'/path/to/zafino.swf'};<br />
var futuna = {src:'/path/to/futuna.swf'};<br />
var rockwell = {src:'/path/to/rockwell.swf'};<br />
<br />
sIFR.activate(zafino,futuna,rockwell);</div></td></tr></tbody></table></div>
<p>Note: There must be &#8220;Only One&#8221; sIFR.activate(). Now we can do the replacements. You can do as many as you like, but as an example, we&#8217;ll replace all &#8216;h3&#8242; element with the Zafino movie.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">sIFR.replace(zafino,{<br />
&nbsp; &nbsp;selector: 'h3',<br />
&nbsp; &nbsp;css:'.sIFR-root{background-color: #ffcc00; color:000000;}'<br />
});</div></td></tr></tbody></table></div>
<p>The first argument to &#8217;sIFR.replace&#8217; is the &#8216;zafino&#8217; object we created earlier. Second argument is another object, on which you can specify a number of parameters or &#8220;keyword arguments&#8221;. For the full list, <a href="http://wiki.novemberborn.net/sifr3/JavaScript+Methods" target="_blank">click here</a></p>
<p>The first argument you see here is &#8217;selector&#8217;, which is a normal CSS selector. That means you can also do things like id and class selector &#8216;#left h1&#8242; or &#8216;h1.title&#8217;. The second argument determines what the Flash text looks like. The main text is styled via &#8216;.sIFR-root&#8217; class. Here we&#8217;ve specified background-color and color of the text. To read more about styling, <a href="http://wiki.novemberborn.net/sifr3/Styling" target="_blank">click here</a></p>
<p>I&#8217;ve already tested this one and It works, I had no trouble in most of the browser.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bethinkerconcepts.com/2009/06/embedding-fonts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
