<?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>Pixel Pushing Monkey</title>
	<atom:link href="http://pixelpushingmonkey.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://pixelpushingmonkey.com</link>
	<description>Personal blog of Steve Mu, UI/UX Designer</description>
	<lastBuildDate>Thu, 19 Apr 2012 16:45:25 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Images for Retina Display</title>
		<link>http://pixelpushingmonkey.com/2012/03/images-for-retina-display/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=images-for-retina-display</link>
		<comments>http://pixelpushingmonkey.com/2012/03/images-for-retina-display/#comments</comments>
		<pubDate>Sat, 31 Mar 2012 23:06:27 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[css3]]></category>
		<category><![CDATA[display]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[responsive]]></category>
		<category><![CDATA[retina]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://pixelpushingmonkey.com/?p=49</guid>
		<description><![CDATA[I can&#8217;t wait until the day when every device we have is using a retina display. Meanwhile, the transition between normal resolution display to retina display is a painful process. Images made for normal websites look horrible on retina display, because mobile Safari have to double the pixels and stretch the normal low resolution graphics [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://pixelpushingmonkey.com/2012/03/images-for-retina-display/"><img class="alignnone size-full wp-image-50" title="Creating images for retina display" src="http://pixelpushingmonkey.com/wp-content/uploads/2012/03/retina_display.jpg" alt="" width="800" height="315" /></a></p>
<p>I can&#8217;t wait until the day when every device we have is using a retina display. Meanwhile, the transition between normal resolution display to retina display is a painful process. Images made for normal websites look horrible on retina display, because mobile Safari have to double the pixels and stretch the normal low resolution graphics to fit on the screen. The result on photographic images aren&#8217;t all that bad, but the less complex images, such as logos and icons are clearly grainy &amp; pixelated on the edges.<span id="more-49"></span></p>
<p>Making a retina display compatible image requires two steps, the first of which is really simple&#8230; take your normal size image and making one that&#8217;s twice as big. For example, if your logo.jpg is 200px by 200px, just make a version of it that&#8217;s called logo2x.jpg and make it 400px by 400px. You can simply upsample it in your application of choice, of course the result won&#8217;t be ideal if you simply upsample your images, but it&#8217;s still better than browser&#8217;s own upsampling. The better approach is to recreate your logo image from the ground up to fit in 400 by 400. Of course, that will be more time consuming&#8230; but it&#8217;s just a necessary pain to deal with.</p>
<p>Once you have your logo2x.jpg, you can simply use media query to make sure retina display picks up the higher resolution image:</p>
<blockquote>
<pre>.logo {
  display: block;
  background: transparent url(logo.jpg) no-repeat;
  width: 200px;
  height: 200px;
}

@media only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and (max--moz-device-pixel-ratio: 2) {
  .logo {
    background: url(logo2x.jpg) no-repeat;
    background-size: 200px 200px;
  }
}</pre>
</blockquote>
<p>The first .logo class is for the normal display, while the media query will load the double resolution image for retina displays. The important thing to remember here, is that mobile Safari will automatically calculate dimension values so developers don&#8217;t have to recode all of their stylesheets. So when you say a div has a width of 200px, mobile Safari will actually render the div at 400px on its screen. So similarly you would have to pretend the higher resolution logo image is actually going to be displayed at its &#8220;normal&#8221; dimension values. Thus the line: &#8220;background-size: 200px 200px&#8221; to <strong>squeeze the logo graphic down</strong> to size.</p>
<p>So this all works very well if you make 2 separate graphic images for retina displays and normal displays. What if I wanted to create a single sprite image that contained both? Turns out this could be done as well. Let&#8217;s say if you created a sprite that&#8217;s a combination of both logo.jpg and logo2x.jpg. You would have an image sprite of 400px wide by 600px height, where the high resolution logo would be at the -200px height background position:</p>
<blockquote>
<pre>.logo {
  display: block;
  background: transparent url(logo.jpg) no-repeat 0 0;
  width: 200px;
  height: 200px;
}

@media only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and (max--moz-device-pixel-rati0: 2) {
  .logo {
    background-position: 0 -100px;
    background-size: 200px 300px;
  }
}</pre>
</blockquote>
<p>Notice that the background-size attribute is half the size of the &#8220;entire&#8221; sprite image, not just the part that&#8217;s visible. Since the background size is again squeezed down, you also have to halve the pixel displacement of the sprite image.</p>
<p>Besides the little bit of oddity with sprite sizing and positioning, making graphics for retina display is pretty straight forward. Hopefully some people out there will find this helpful.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpushingmonkey.com/2012/03/images-for-retina-display/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cafe Japonaise</title>
		<link>http://pixelpushingmonkey.com/2012/03/cafe-japonaise/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=cafe-japonaise</link>
		<comments>http://pixelpushingmonkey.com/2012/03/cafe-japonaise/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 23:30:04 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Food]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[boston]]></category>
		<category><![CDATA[cafe]]></category>
		<category><![CDATA[japanese]]></category>

		<guid isPermaLink="false">http://pixelpushingmonkey.com/?p=30</guid>
		<description><![CDATA[When I last visited Boston, Cafe Japonaise only had one location in Brookline, now they&#8217;ve got three locations throughout the greater Boston area. This was one of the few bright spots on my visit to Boston this time around, good coffee and great pastry. Their various cream puff, specialty bread, and sliced loaves are to [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://pixelpushingmonkey.com/2012/03/cafe-japonaise/ "><img class="alignnone size-full wp-image-31" title="Cafe Japonaise" src="http://pixelpushingmonkey.com/wp-content/uploads/2012/03/food_japonaise.jpg" alt="" width="800" height="315" /></a></p>
<p>When I last visited Boston, <a title="Cafe Japonaise" href="http://www.japonaisebakery.com/">Cafe Japonaise</a> only had one location in Brookline, now they&#8217;ve got three locations throughout the greater Boston area. This was one of the few bright spots on my visit to Boston this time around, good coffee and great pastry. Their various cream puff, specialty bread, and sliced loaves are to die for.<span id="more-30"></span></p>
<p>By comparison, the nearby Chinese market has been recently purchased by another owner, and the new ownership isn&#8217;t doing much to clean the place up. The market has a stinky sewage smell as soon as you walk in. In the bread section are loaves of spongey bread stacked up and stuffed into a shelf. Some of the specialty breads are just still in stacks of cardboard boxes where they&#8217;re randomly throw together.</p>
<p>It was amazingly hard to find really high quality pastry, or even just mediocre quality pastry. Some of the well known chains have decent, but not great pastry. The croissants are just a little bit stale, cookies aren&#8217;t quite right.. etc.. etc..</p>
<p>So if you&#8217;re in Boston and you want really good pastry, Cafe Japonaise is the place to be.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpushingmonkey.com/2012/03/cafe-japonaise/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>It&#8217;s Good to Be Home</title>
		<link>http://pixelpushingmonkey.com/2012/03/its-good-to-be-home/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=its-good-to-be-home</link>
		<comments>http://pixelpushingmonkey.com/2012/03/its-good-to-be-home/#comments</comments>
		<pubDate>Mon, 26 Mar 2012 20:55:46 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Food]]></category>
		<category><![CDATA[News]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[boston]]></category>
		<category><![CDATA[chinese]]></category>
		<category><![CDATA[life]]></category>
		<category><![CDATA[san francisco]]></category>
		<category><![CDATA[silver house]]></category>

		<guid isPermaLink="false">http://pixelpushingmonkey.com/?p=10</guid>
		<description><![CDATA[As much as I wish the above picture is a creation of yours truly, it&#8217;s actually one of the best dish from an all-time local favorite. Although I&#8217;ve always been aware of the discrepancy between vacationing versus living at a particular destination, the actual impact of that discrepancy has never been more clear to me [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://pixelpushingmonkey.com/2012/03/its-good-to-be-home/"><img class="alignnone size-full wp-image-11" title="delicious, delicous food" src="http://pixelpushingmonkey.com/wp-content/uploads/2012/03/food_clams.jpg" alt="" width="800" height="315" /></a></p>
<p>As much as I wish the above picture is a creation of yours truly, it&#8217;s actually one of the best dish from <a title="Silver House" href="http://www.yelp.com/biz/silver-house-san-mateo">an all-time local favorite</a>. Although I&#8217;ve always been aware of the discrepancy between vacationing versus living at a particular destination, the actual impact of that discrepancy has never been more clear to me than the last month and half. Years ago when I visited Boston, it was only for a week during the best time of the year, and we checked out some of the best restaurants in town for the entire week. Life is much different when you&#8217;re not spending $100 a day just on food.<span id="more-10"></span></p>
<p>Mostly, what I missed was great Asian cuisine. Although Boston does have a Chinatown, the competition pales when compared to the availability of Asian cuisine here in the San Francisco Bay Area. Here, great Asian cuisine isn&#8217;t even necessarily in Chinatown, but all the way up and down in almost every city in the Peninsula. It speaks volume to the importance of competition in driving any economy forward, even for something as simple as food. In some ways, LA and San Diego has also outpaced San Francisco with newer and better quality cuisine, driven by newer generations of Asian immigrants that finds LA and SD more attractive venues.</p>
<p>I have friends who have spent their entire lives in California, and to some of them there&#8217;s always a question of, &#8220;Where would I go if I didn&#8217;t want to be in California anymore?&#8221; I&#8217;ve spent at least some of my childhood on the east coast, in the mid-west, and even a tiny little sliver of southern hospitality in between; maybe it&#8217;s the precise mixture of Asian-American that I&#8217;ve got in me, where I need just the right balance of both, but I can&#8217;t figure out where else I would be if not California. I even knew someone who took a job in Minnesota just to experience something different, only to return a year later never wanting to see snow again (a sentiment I can agree with completely).</p>
<p>I think that pretty much explains why, despite the insane real estate and living costs, that I still chose to stay here and hope for the best.</p>
]]></content:encoded>
			<wfw:commentRss>http://pixelpushingmonkey.com/2012/03/its-good-to-be-home/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

