<?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>Font Replacement Archives - Michael Soriano</title>
	<atom:link href="https://michaelsoriano.com/tag/font-replacement/feed/" rel="self" type="application/rss+xml" />
	<link>https://michaelsoriano.com/tag/font-replacement/</link>
	<description>I turn code into captivating user experiences for the web</description>
	<lastBuildDate>Wed, 14 Oct 2009 05:08:40 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.4</generator>
	<item>
		<title>Cufonize Your Pages &#8211; How to add Cufon to your Web Design</title>
		<link>https://michaelsoriano.com/cufonize-your-pages-how-to-add-cufon-to-your-web-design/</link>
					<comments>https://michaelsoriano.com/cufonize-your-pages-how-to-add-cufon-to-your-web-design/#comments</comments>
		
		<dc:creator><![CDATA[Michael Soriano]]></dc:creator>
		<pubDate>Wed, 14 Oct 2009 05:08:40 +0000</pubDate>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Cufon]]></category>
		<category><![CDATA[Font Replacement]]></category>
		<guid isPermaLink="false">http://fearlessflyer.com/?p=781</guid>

					<description><![CDATA[<p>I’m a big fan of Woothemes. It seems that each time they come out with a theme &#8211; they push the boundaries of web design. Take a look at their latest creation: Therapy – I can’t help but fall in love with the fine background gradients, smooth and seamless transparencies and nice rounded edges. But [&#8230;]</p>
<p>The post <a href="https://michaelsoriano.com/cufonize-your-pages-how-to-add-cufon-to-your-web-design/">Cufonize Your Pages &#8211; How to add Cufon to your Web Design</a> appeared first on <a href="https://michaelsoriano.com">Michael Soriano</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I’m a big fan of <a href="http://woothemes.com">Woothemes</a>. It seems that each time they come out with a theme &#8211; they push the boundaries of web design. Take a look at their latest creation: <a href="http://www.woothemes.com/2009/10/therapy/">Therapy</a> – I can’t help but fall in love with the fine background gradients, smooth and seamless transparencies and nice rounded edges. But what I really like about Therapy is it&#8217;s amazing typography. I said to myself: <strong>“that’s excellent utilization of sIFR”.</strong> So I right clicked on a post title, expecting to see the <strong>“About Macromedia Flash” </strong>entry – but didn’t see it. So I asked my confused self: <strong>“if it’s not sIFR, then what is converting all this dynamic text?&#8221;</strong><br />
I inspect element in Firebug – then I see span class “<strong>cufon</strong>” everywhere.<br />
<img fetchpriority="high" decoding="async" class="alignnone size-full wp-image-785" title="A view of the source code for Therapy - Cufon all over the place" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-1.jpg" alt="cufon-1" width="576" height="323" /></p>
<h3>So What in the world is Cufon?</h3>
<p>Cufon is defined as <strong>&#8220;fast text replacement with canvas and VML&#8221;</strong>. It also claims to be a worthy alternative to sIFR – which is, to those who are not familiar – stands for Scalable Inman Flash Replacement. sIFR is the technology used by web designers to replace dynamic text with non-web safe fonts. Although sIFR has done an okay job with text replacement – it has proven to be quite tricky to set up. I’ve used sIFR in a few projects in the past and do admit that it is not the easiest thing to get going. On top of that – sIFR seems a bit buggy, as well as slows down page loads. These are serious consequences to consider for the price of using a unique font for your pages.<br />
So I went ahead and tried Cufon. To my amazement, the following steps is all that it takes to fully &#8220;Cufonize&#8221; your web pages. *Forgive the use of the term &#8220;cufonize&#8221; &#8211; it may sound funny, but after you try these steps, you too will &#8220;cufonize&#8221; your pages.</p>
<h3>Step 1: Get Cufon</h3>
<p>The first thing you need is to download the core javascript file which is responsible for the rendering of your custom font inside your HTML. Head on to <a href="http://cufon.shoqolate.com/generate/">http://cufon.shoqolate.com/generate/</a> and right click the “<strong>Download</strong>” tab – choose “<strong>Save Link As…</strong>” Save <strong>cufon-yui.js</strong> into a local directory in your machine.<br />
<img decoding="async" class="alignnone size-full wp-image-786" title="Download the core code" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-2.jpg" alt="cufon-2" width="576" height="323" /></p>
<h3>Step 2: Generate your Font</h3>
<p>On the same page at <a href="http://cufon.shoqolate.com/generate/">http://cufon.shoqolate.com/generate/</a> &#8211; click on the “<strong>Regular typeface</strong>” field – and browse to your desired font in your local machine.<br />
<img decoding="async" class="alignnone size-full wp-image-787" title="Create the code for your font" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-3.jpg" alt="cufon-3" width="576" height="323" /><br />
The rest of the upload fields are optional. I left all of them default for the sake of making this tutorial short. Just make sure – you are using a font that is legit to use, check off the EULAs and the Terms of Agreement. Click on the <strong>“Let’s Do This</strong>” Button at the very end of that page.<br />
This should generate a custom font javascript code for you – depending on your font choice. In my case, I picked something very un-extraordinary: Gigi.TTF – which produced a file named Gigi_400.font.js.<br />
Go ahead and save this file in the same directory where you saved the core Cufon-yui.js file and we’re ready to build your page:<br />
<img decoding="async" class="alignnone size-full wp-image-788" style="border: 0px;" title="Once created, save the js file locally" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-4.png" alt="cufon-4" width="573" height="178" /></p>
<h3>Step 3: Cufonize your Page</h3>
<p>All you really need to do from this point is to link to these javascript files in the head section of your HTML. Also make sure that cufon-yui.js is called before the font.js file:<br />
<script src="https://gist.github.com/michaelsoriano/73cd7909c742ac6bb73d.js"></script><br />
To begin the replacement process – create a custom script like below:<br />
<script src="https://gist.github.com/michaelsoriano/d063fae04ef34e7b41f5.js"></script><br />
The above script is telling the cufon to replace all H3 and P tags to our custom font.<br />
<img decoding="async" class="alignnone size-full wp-image-789" title="Refresh your page and Voila!" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-5.jpg" alt="cufon-5" width="576" height="323" /><br />
Note that if you want to target specific elements in your page the same way you assign CSS classes and Ids, you have to use a framework such as jQuery that’ll let you do such a thing. To download jQuery, go to <a href="http://docs.jquery.com/Downloading_jQuery">http://docs.jquery.com/Downloading_jQuery</a>. Make sure you link to this file BEFORE the core cufon-yui.js in your header.<br />
With the jQuery library in place, now you can select more specific elements in your page (hashtags for IDs and periods for classes). See example code below:<br />
<script src="https://gist.github.com/michaelsoriano/88a4fa055473e7f82468.js"></script><br />
The above code will Cufonize only the h3 tags with the id of “convert-me”, and p tags with the id of “convert-me-too”.<br />
<img decoding="async" class="alignnone size-full wp-image-784" title="Use jQuery Selectors to target elements" src="https://michaelsoriano.com/wp-content/uploads/2009/10/cufon-6.jpg" alt="cufon-6" width="576" height="494" /></p>
<h3>Conclusion:</h3>
<p>That’s basically it! That’s all it takes for you to use any font you like in your web pages. What I like best about Cufon is that it’s quick and it works. You will also find that general CSS properties such as color, size and positioning still applies on the transformed font. To find out more about the specifics of Cufon styling &#8211; see <a href="http://wiki.github.com/sorccu/cufon/styling">http://wiki.github.com/sorccu/cufon/styling</a>.<br />
Much respect to the people who created Cufon. I&#8217;m sure this marks a new trend in web typography. To the folks at Woothemes: keep pushing the boundaries &#8211; your work is pure inspiration to web artists everywhere.</p>
<h3>Who&#8217;s Using Cufon?</h3>
<p>The following list of websites are already using Cufon text replacement in their pages:<br />
<strong>Healthy Valdosta</strong><br />
<a href="http://www.healthyvaldosta.com/"><img decoding="async" class="alignnone size-full wp-image-797" title="healthyvaldosta" src="https://michaelsoriano.com/wp-content/uploads/2009/10/healthyvaldosta.jpg" alt="healthyvaldosta" width="576" height="300" /></a><br />
<strong>Press75</strong><br />
<a href="http://www.press75.com/"><img decoding="async" class="alignnone size-full wp-image-798" title="press75" src="https://michaelsoriano.com/wp-content/uploads/2009/10/press75.jpg" alt="press75" width="576" height="300" /></a><br />
<strong>International Rugby Academy</strong><br />
<a href="http://www.internationalrugbyacademy.com/new-zealand/"><img decoding="async" class="alignnone size-full wp-image-799" title="intlrugby" src="https://michaelsoriano.com/wp-content/uploads/2009/10/intlrugby.jpg" alt="intlrugby" width="576" height="300" /></a><br />
<strong>Zen Desk</strong><br />
<a href="http://www.zendesk.com/"><img decoding="async" class="alignnone size-full wp-image-800" title="zenddesk" src="https://michaelsoriano.com/wp-content/uploads/2009/10/zenddesk.jpg" alt="zenddesk" width="576" height="300" /></a><br />
<strong>Rock Beats Paper</strong><br />
<a href="http://rockbeatspaper.com/"><img decoding="async" class="alignnone size-full wp-image-802" title="rockbeatspaper" src="https://michaelsoriano.com/wp-content/uploads/2009/10/rockbeatspaper.jpg" alt="rockbeatspaper" width="576" height="300" /></a><br />
<strong>Shopify</strong><br />
<a href="http://www.shopify.com/"><img decoding="async" class="alignnone size-full wp-image-803" title="shopify" src="https://michaelsoriano.com/wp-content/uploads/2009/10/shopify.jpg" alt="shopify" width="576" height="300" /></a></p>
<p>The post <a href="https://michaelsoriano.com/cufonize-your-pages-how-to-add-cufon-to-your-web-design/">Cufonize Your Pages &#8211; How to add Cufon to your Web Design</a> appeared first on <a href="https://michaelsoriano.com">Michael Soriano</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://michaelsoriano.com/cufonize-your-pages-how-to-add-cufon-to-your-web-design/feed/</wfw:commentRss>
			<slash:comments>70</slash:comments>
		
		
			</item>
	</channel>
</rss>
