<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>The Pixel-And-Ink Code Blog</title>
	<atom:link href="http://davidfranzen.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://davidfranzen.wordpress.com</link>
	<description>I forgot to RTFM!</description>
	<lastBuildDate>Fri, 09 Jul 2010 22:53:52 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='davidfranzen.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>The Pixel-And-Ink Code Blog</title>
		<link>http://davidfranzen.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://davidfranzen.wordpress.com/osd.xml" title="The Pixel-And-Ink Code Blog" />
	<atom:link rel='hub' href='http://davidfranzen.wordpress.com/?pushpress=hub'/>
		<item>
		<title>JavaScript to Calculate Print Sizes at the Right Aspect Ratio</title>
		<link>http://davidfranzen.wordpress.com/2010/07/09/javascript-to-calculate-print-sizes-at-the-right-aspect-ratio/</link>
		<comments>http://davidfranzen.wordpress.com/2010/07/09/javascript-to-calculate-print-sizes-at-the-right-aspect-ratio/#comments</comments>
		<pubDate>Fri, 09 Jul 2010 22:41:20 +0000</pubDate>
		<dc:creator>davidfranzen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://davidfranzen.wordpress.com/?p=211</guid>
		<description><![CDATA[Client: Hey I really like these two photos, can I buy some prints? Photographer: Thanks! Sure I can make you prints. What size prints do you want? Client: I want eight-by-tens. Photographer: Well, one of the photos you want is &#8230; <a href="http://davidfranzen.wordpress.com/2010/07/09/javascript-to-calculate-print-sizes-at-the-right-aspect-ratio/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=211&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><em><strong>Client:</strong> Hey I really like these two photos, can I buy some prints?</em></p>
<p><em><strong>Photographer:</strong> Thanks! Sure I can make you prints. What size prints do you want?</em></p>
<p><em><strong>Client:</strong> I want eight-by-tens.</em></p>
<p><em><strong>Photographer:</strong> Well, one of the photos you want is square, and the other has a three-to-two aspect ratio? Do you want a ten-by-ten and a eight-by-twelve, or some other sizes?</em></p>
<p><em><strong>Client</strong> Uh, I&#8217;ll get back to you&#8230;</em></p>
<p>I&#8217;ve found it hard to communicate with some potential customers for my prints what size they want. Usually they ask for one of the “standard” picture frame sizes, like eight-by-ten, even though though the crops don’t match that aspect ratio. Just recropping to the asked-for size is destructive, and probably not what they really want. Throwing the term “aspect ratio” back in their face is just confusing.</p>
<p>I think the solution is to be able to just show the user a list of sizes available <em>for that specific image</em>. I plan to add this to pixel-and-ink.com at some point (when I have time).</p>
<p>I believe showing the customer a list of sizes can also encourage them to order a larger print than they might otherwise. I like making big prints. Most photos look great big, and if someone is only buying one or two prints, it&#8217;s just as much work to make a large print as a 4&#215;6.</p>
<p>For now I have written a JavaScript library to calculate print sizes consistent with a given image&#8217;s aspect ratio. The range of sizes is bound by a maximum print area and the smallest desired print size (on the long edge). The resulting print sizes are formatted as whole and fractional inches.</p>
<p>I&#8217;ve added a BSD-style license to the scripts. Links to them are available on <a href="http://www.pixel-and-ink.com/demos/printsizes/testpage.html">a demo web app</a>. You can view source to see how to use the API, but here&#8217;s a bare-bones example snippet:</p>
<p><code>// the largest I can print in house, in points (72 points-per inch)<br />
var superB = new PrintSize( 13 * 72, 19 * 72 );<br />
// Typical dimensions of digital image from a DSLR<br />
var twoByThree = new PrintSize( 4256, 2832 );</p>
<p>// Available print sizes, on Super B down to 6 inches.<br />
var printSizes = PrintSizes.GetPrintSizeOptions( twoByThree, superB, (6 * 72) );<br />
for( var p in printSizes )<br />
{<br />
	var nextSize = printSizes[p];<br />
	console.log( nextSize.toString() );<br />
}</code></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/davidfranzen.wordpress.com/211/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/davidfranzen.wordpress.com/211/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/davidfranzen.wordpress.com/211/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=211&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://davidfranzen.wordpress.com/2010/07/09/javascript-to-calculate-print-sizes-at-the-right-aspect-ratio/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/29cd79937349deb1550f24ae0f46ce7b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">davidfranzen</media:title>
		</media:content>
	</item>
		<item>
		<title>Don’t Forget animated: When Pushing View Controllers!</title>
		<link>http://davidfranzen.wordpress.com/2010/05/06/don%e2%80%99t-forget-animate-when-pushing-view-controllers/</link>
		<comments>http://davidfranzen.wordpress.com/2010/05/06/don%e2%80%99t-forget-animate-when-pushing-view-controllers/#comments</comments>
		<pubDate>Thu, 06 May 2010 08:11:45 +0000</pubDate>
		<dc:creator>davidfranzen</dc:creator>
				<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Objective C]]></category>
		<category><![CDATA[RTFM]]></category>

		<guid isPermaLink="false">http://davidfranzen.wordpress.com/?p=200</guid>
		<description><![CDATA[In a UITableViewController why does this crash? [self.navigationController pushViewController:anotherViewController]; Cuz the method is - (void)pushViewController:(UIViewController) viewController animated:(BOOL) animated Duh. This is also why XCode gave me a warning about an unrecognized selector when I built the code. Classes tend to have &#8230; <a href="http://davidfranzen.wordpress.com/2010/05/06/don%e2%80%99t-forget-animate-when-pushing-view-controllers/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=200&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In a UITableViewController why does this crash?</p>
<p><code>[self.navigationController pushViewController:anotherViewController];</code></p>
<p>Cuz the method is</p>
<p><code>- (void)pushViewController:(UIViewController) viewController<br />
         animated:(BOOL) animated </code></p>
<p>Duh. This is also why XCode gave me a warning about an unrecognized selector when I built the code. Classes tend to have the methods developers gave them, not the methods I remembered they had.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/davidfranzen.wordpress.com/200/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/davidfranzen.wordpress.com/200/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/davidfranzen.wordpress.com/200/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=200&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://davidfranzen.wordpress.com/2010/05/06/don%e2%80%99t-forget-animate-when-pushing-view-controllers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/29cd79937349deb1550f24ae0f46ce7b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">davidfranzen</media:title>
		</media:content>
	</item>
		<item>
		<title>Test Post</title>
		<link>http://davidfranzen.wordpress.com/2010/05/06/test-post/</link>
		<comments>http://davidfranzen.wordpress.com/2010/05/06/test-post/#comments</comments>
		<pubDate>Thu, 06 May 2010 07:23:49 +0000</pubDate>
		<dc:creator>davidfranzen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://davidfranzen.wordpress.com/?p=194</guid>
		<description><![CDATA[This is only a test. var thingy:Object = new Object(); thingy.partA = "head"; thingy.partB = "tail"; trace("The Keys:"); for( var key in thingy ) { trace( key ); } trace("The Values:"); for each( var value in thingy ) { trace( &#8230; <a href="http://davidfranzen.wordpress.com/2010/05/06/test-post/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=194&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is only a test.</p>
<pre>var thingy:Object = new Object();
thingy.partA = "head";
thingy.partB = "tail";

trace("The Keys:");
for( var key in thingy )
{
	trace( key );
}

trace("The Values:");
for each( var value in thingy )
{
	trace( value );
}</pre>
<p>End of test.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/davidfranzen.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/davidfranzen.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/davidfranzen.wordpress.com/194/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=davidfranzen.wordpress.com&amp;blog=10176666&amp;post=194&amp;subd=davidfranzen&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://davidfranzen.wordpress.com/2010/05/06/test-post/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/29cd79937349deb1550f24ae0f46ce7b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">davidfranzen</media:title>
		</media:content>
	</item>
	</channel>
</rss>
