<?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>Aaron As a Chimp &#187; Quickies</title>
	<atom:link href="http://sachimp.com/category/quickies/feed/" rel="self" type="application/rss+xml" />
	<link>http://sachimp.com</link>
	<description>with a typewriter</description>
	<lastBuildDate>Sat, 18 Jun 2011 15:26:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Label Tags and Fitts&#8217; Law</title>
		<link>http://sachimp.com/2010/09/01/label-tags-and-fitts-law/</link>
		<comments>http://sachimp.com/2010/09/01/label-tags-and-fitts-law/#comments</comments>
		<pubDate>Wed, 01 Sep 2010 18:27:48 +0000</pubDate>
		<dc:creator>AaronAsAChimp</dc:creator>
				<category><![CDATA[Quickies]]></category>

		<guid isPermaLink="false">http://sachimp.com/?p=234</guid>
		<description><![CDATA[A quick way to improve the usability of your forms is to use the label tag. It will increase the size of the click-able area of a form input. As we know from Fitts&#8217; law the larger an element the easier it is to interact with it. Try it with a check box. The clickable [...]]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop --><!-- End Shareaholic LikeButtonSetTop --><p>A quick way to improve the usability of your forms is to use the label tag. It will increase the size of the click-able area of a form input. As we know from Fitts&#8217; law the larger an element the easier it is to interact with it. Try it with a check box. The clickable area is outlined in red.</p>
<form>
<span style="border: 1px solid red; display: inline-block;"><br />
<input type="checkbox"> </span> a check box without label<br />
<label style="border: 1px solid red; display: inline-block;"><br />
<input type="checkbox"> a check box with label</label><br />
</form>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">label</span>&gt;</span>
    <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;checkbox&quot;</span>&gt;</span> label text
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">label</span>&gt;</span></pre></div></div>

<div class="shr-publisher-234"></div><!-- Start Shareaholic LikeButtonSetBottom --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:none;height:30px;'><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F09%2F01%2Flabel-tags-and-fitts-law%2F' data-shr_title='Label+Tags+and+Fitts%27+Law'></a><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F09%2F01%2Flabel-tags-and-fitts-law%2F' data-shr_title='Label+Tags+and+Fitts%27+Law'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetBottom -->]]></content:encoded>
			<wfw:commentRss>http://sachimp.com/2010/09/01/label-tags-and-fitts-law/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why width: 100% doesn&#8217;t do what you think it does</title>
		<link>http://sachimp.com/2010/06/13/why-width-100-doesnt-do-what-you-think-it-does/</link>
		<comments>http://sachimp.com/2010/06/13/why-width-100-doesnt-do-what-you-think-it-does/#comments</comments>
		<pubDate>Mon, 14 Jun 2010 00:24:16 +0000</pubDate>
		<dc:creator>AaronAsAChimp</dc:creator>
				<category><![CDATA[Quickies]]></category>
		<category><![CDATA[box-model]]></category>
		<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://sachimp.com/2010/06/13/why-width-100-doesnt-do-what-you-think-it-does/</guid>
		<description><![CDATA[Something I run across every so often when fixing bugs is a problem of content overflowing its parent element. The child has padding, margins, or a border, and a width set to 100%. This seems like it should fill the available space, but it protrudes out instead. The weird behavior comes from the standard box [...]]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop --><!-- End Shareaholic LikeButtonSetTop --><p>Something I run across every so often when fixing bugs is a problem of content overflowing its parent element. The child has padding, margins, or a border, and a width set to 100%. This seems like it should fill the available space, but it protrudes out instead.</p>
<p>The weird behavior comes from the standard box model. According to the standard box model, when you set the width, it sets the width of the content area. The padding, border, and margin get wrapped around it. Meaning that the box, which is already the full width of it&#8217;s parent, gets pushed out beyond the edge.</p>
<p>The fix is painfully simple. Simply set width of the chid element to auto, or remove it entirely. Block level elements automatically fill the available space, and that calculation takes into account the borders, margin, and padding.  </p>
<div class="shr-publisher-226"></div><!-- Start Shareaholic LikeButtonSetBottom --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:none;height:30px;'><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F06%2F13%2Fwhy-width-100-doesnt-do-what-you-think-it-does%2F' data-shr_title='Why+width%3A+100%25+doesn%27t+do+what+you+think+it+does'></a><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F06%2F13%2Fwhy-width-100-doesnt-do-what-you-think-it-does%2F' data-shr_title='Why+width%3A+100%25+doesn%27t+do+what+you+think+it+does'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetBottom -->]]></content:encoded>
			<wfw:commentRss>http://sachimp.com/2010/06/13/why-width-100-doesnt-do-what-you-think-it-does/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>What&#8217;s a &nbsp;?</title>
		<link>http://sachimp.com/2010/05/30/nbsp-quickie/</link>
		<comments>http://sachimp.com/2010/05/30/nbsp-quickie/#comments</comments>
		<pubDate>Sun, 30 May 2010 13:06:24 +0000</pubDate>
		<dc:creator>AaronAsAChimp</dc:creator>
				<category><![CDATA[Quickies]]></category>

		<guid isPermaLink="false">http://sachimp.com/?p=208</guid>
		<description><![CDATA[The non-breaking space (&#38;nbsp;) is the workhorse of the web. It can be used in so many contexts from its use as a poor-mans indent or even to workaround bugs in IE6 and Firefox. Not many people know the true value of a non-breaking space. As its name implies, its primary purpose to prevent line [...]]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop --><!-- End Shareaholic LikeButtonSetTop --><p>The non-breaking space (&amp;nbsp;) is the workhorse of the web. It can be used in so many contexts from its use as a poor-mans indent or even to workaround bugs in IE6 and Firefox.</p>
<p>Not many people know the true value of a non-breaking space. As its name implies, its primary purpose to prevent line breaks. Essentially the opposite of a break tag.</p>
<h2>A few examples</h2>
<h3>Prevent widows:</h3>
<p>By replacing the last space in a paragraph you can prevent a widowed word.

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">In aliquet leo aliquet enim tincidunt non tristique tortor
feugiat. Donec gravida egestas risus quis eleifend. Donec
adipiscing dolor nec augue dignissim<span style="color: #ddbb00;">&amp;nbsp;</span>pharetra.</pre></div></div>

<h3>Ensure words always appear together</h3>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">In aliquet leo aliquet enim tincidunt non tristique tortor
feugiat. ACME<span style="color: #ddbb00;">&amp;nbsp;</span>Widget<span style="color: #ddbb00;">&amp;nbsp;</span>XL donec gravida egestas
risus quis eleifend. Donec adipiscing dolor nec augue
dignissim pharetra.</pre></div></div>

<div class="shr-publisher-208"></div><!-- Start Shareaholic LikeButtonSetBottom --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:none;height:30px;'><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F05%2F30%2Fnbsp-quickie%2F' data-shr_title='What%27s+a+%26amp%3Bnbsp%3B%3F'></a><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F05%2F30%2Fnbsp-quickie%2F' data-shr_title='What%27s+a+%26amp%3Bnbsp%3B%3F'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetBottom -->]]></content:encoded>
			<wfw:commentRss>http://sachimp.com/2010/05/30/nbsp-quickie/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Scientific Notation &#8211; Quick JS Snippy</title>
		<link>http://sachimp.com/2010/01/16/scientific-notation-2/</link>
		<comments>http://sachimp.com/2010/01/16/scientific-notation-2/#comments</comments>
		<pubDate>Sat, 16 Jan 2010 21:19:36 +0000</pubDate>
		<dc:creator>AaronAsAChimp</dc:creator>
				<category><![CDATA[Quickies]]></category>

		<guid isPermaLink="false">http://sachimp.com/?p=143</guid>
		<description><![CDATA[Number.prototype.toScientific = function &#40;x&#41; &#123; &#160; var parts = this.toExponential&#40;x&#41;.split&#40; /[e]\+?/i ,2&#41;; &#160; return parts&#91;0&#93; + &#40;&#40;parts&#91;1&#93; != 0 &#38;&#38; parts &#91;1&#93; != 1&#41;? &#34; &#38;times; 10&#60;sup&#62;&#34; + parts&#91;1&#93; + &#34;&#60;/sup&#62;&#34;: &#34;&#34;&#41;; &#125;]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop --><!-- End Shareaholic LikeButtonSetTop -->
<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">Number.<span style="color: #660066;">prototype</span>.<span style="color: #660066;">toScientific</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span>x<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #003366; font-weight: bold;">var</span> parts <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">toExponential</span><span style="color: #009900;">&#40;</span>x<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">split</span><span style="color: #009900;">&#40;</span> <span style="color: #009966; font-style: italic;">/[e]\+?/i</span> <span style="color: #339933;">,</span><span style="color: #CC0000;">2</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">return</span> parts<span style="color: #009900;">&#91;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">+</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#40;</span>parts<span style="color: #009900;">&#91;</span><span style="color: #CC0000;">1</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">!=</span> <span style="color: #CC0000;">0</span> <span style="color: #339933;">&amp;&amp;</span> parts <span style="color: #009900;">&#91;</span><span style="color: #CC0000;">1</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">!=</span> <span style="color: #CC0000;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">?</span> <span style="color: #3366CC;">&quot; &amp;times; 10&lt;sup&gt;&quot;</span> <span style="color: #339933;">+</span> parts<span style="color: #009900;">&#91;</span><span style="color: #CC0000;">1</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">+</span> <span style="color: #3366CC;">&quot;&lt;/sup&gt;&quot;</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<div class="shr-publisher-143"></div><!-- Start Shareaholic LikeButtonSetBottom --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:none;height:30px;'><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F01%2F16%2Fscientific-notation-2%2F' data-shr_title='Scientific+Notation+-+Quick+JS+Snippy'></a><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http%3A%2F%2Fsachimp.com%2F2010%2F01%2F16%2Fscientific-notation-2%2F' data-shr_title='Scientific+Notation+-+Quick+JS+Snippy'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetBottom -->]]></content:encoded>
			<wfw:commentRss>http://sachimp.com/2010/01/16/scientific-notation-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

