<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
<title>Matt Ryall's Weblog</title>
<link>http://www.mattryall.net</link>

<description>Matt Ryall's Weblog</description>
<ttl>60</ttl>


<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/mattryall" type="application/rss+xml" /><item>
	<title>My iPhone story</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/339720302/my-iphone-story</link>
	<description>&lt;p&gt;Yesterday, I finally got an iPhone. And I queued a lot longer than I expected, which was a bit of a shame.&lt;/p&gt;

&lt;p&gt;After walking past a few Optus stores on launch day last Friday, I decided I was going to wait until this week to get my iPhone. Unfortunately, the Apple store &lt;a href="http://www.mattryall.net/blog/2008/07/still-no-iphone-for-me"&gt;always seemed&lt;/a&gt; to have a really long queue whenever I went past. I thought I should follow the advice of the Apple store staff and come in early one morning. They assured me that they got new stock in every night, so I wouldn&amp;#8217;t have trouble getting a black 16 GB model if I arrived early in the morning.&lt;/p&gt;

&lt;p&gt;I arranged with a colleague, Michael, that we&amp;#8217;d try to get to the store early on Friday morning. I arrived at 7.05 am to find him second last in the queue, so I slotted in next to him. We started off with about twenty people in front of us. Michael said he&amp;#8217;d have to go back to work by 9.30 am, and I needed to get in by 10. We didn&amp;#8217;t think this would be any trouble with only twenty people in front of us.&lt;/p&gt;

&lt;p&gt;The store opened at 8 am, and the queue slid around into the front of the store. We ended up just outside the door after this happened. After an entire hour &amp;#8212; at 9 am &amp;#8212; we were &lt;em&gt;still&lt;/em&gt; just outside the door. The queue inside had moved forward by &lt;em&gt;two people&lt;/em&gt; in an hour. &lt;/p&gt;

&lt;p&gt;At 9.30 am, we got to move inside and the Apple store kindly provided coffee and hot chocolate for the people in the queue. This was good, but it was still to be two more hours before Michael and I were allowed upstairs to sign the contracts and so on.&lt;/p&gt;

&lt;p&gt;While we were standing in the queue, one of the Apple staff mentioned that they&amp;#8217;d increased the number of Optus staff signing up new customers from two up to eight. However, this didn&amp;#8217;t seem to make any improvement whatsoever to the speed of the queue. Even though he mentioned this at around 10, it took more than 90 minutes to process the ten people in front of us.&lt;/p&gt;

&lt;p&gt;I finally signed all the paperwork and got my new phone shortly before 12. Was it worth it? No, not really. I&amp;#8217;d got up yesterday morning expecting to spend perhaps one or two hours in a queue. While I think the iPhone 3G is a great device, I wish I had those five hours of my life back. &lt;/p&gt;

&lt;p&gt;If I had known at the beginning it would take so long, I don&amp;#8217;t think I would have stuck around. When you&amp;#8217;ve been waiting for a few hours, the front of the queue is getting &lt;em&gt;so close&lt;/em&gt;, the staff tell you that processing is getting faster, it just ends up with people like me waiting around for much longer than we ever intended.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-19T17:25:18+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/my-iphone-story</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/my-iphone-story</feedburner:origLink></item>

<item>
	<title>Browser market share</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/337893511/browser-market-share</link>
	<description>&lt;p&gt;You can never be too sure how accurate these figures are, but I came across &lt;a href="http://marketshare.hitslink.com/report.aspx?qprid=0"&gt;some interesting statistics&lt;/a&gt; while researching another article:&lt;/p&gt;

&lt;table class="style1"&gt;
&lt;tr&gt;&lt;th&gt;Internet Explorer&lt;/th&gt;&lt;td&gt;73.01%&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;Firefox&lt;/th&gt;&lt;td&gt;19.03%&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;Safari&lt;/th&gt;&lt;td&gt;6.31%&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;&amp;#8230; and the rest&lt;/th&gt;&lt;td&gt;1.65%&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;

&lt;p&gt;With over 25% of the web using Firefox and Safari, the browser wars are definitely back on. As a web developer, you certainly can&amp;#8217;t ignore these browsers now. Not even for intranet development, in my opinion.&lt;/p&gt;

&lt;p&gt;The use of alternative browsers is only going to increase, I believe, with increasing market share of Safari in the mobile market, and release of Firefox 3.0 increasing its adoption in the desktop market.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-17T18:41:27+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/browser-market-share</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/browser-market-share</feedburner:origLink></item>

<item>
	<title>Making Adium look hot</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/336499490/making-adium-look-hot</link>
	<description>&lt;p&gt;One of the things I do when I set up a new computer is installing and customising &lt;a href="http://www.adiumx.com/"&gt;Adium&lt;/a&gt;, the Mac chat client. &lt;/p&gt;

&lt;p&gt;Adium is an amazing application. It connects to all the major chat networks, has a great default appearance, and doesn&amp;#8217;t really cause me any problems. But a while ago I started playing around with Adium&amp;#8217;s appearance, just because I could, and came up with a new design that looked kind of nice.&lt;/p&gt;

&lt;p&gt;I&amp;#8217;ve had to redo these changes on a couple of computers now, and I often forget exactly what customisations I do. This time I thought I&amp;#8217;d write them down as I did them, for future reference and for anyone else to play around with.&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;img alt="Adium screenshot" src="http://www.mattryall.net/image/adium.png"&gt;&lt;br/&gt;
Adium with my customisations
&lt;/p&gt;

&lt;p&gt;What you can&amp;#8217;t see in the screenshot is that the contact list is slightly transparent. In general, I don&amp;#8217;t like transparent windows, because they make the text hard to read. In this case, however, it seems to work fairly well for my contact list. Probably because I&amp;#8217;m not actually reading it very often, and I have adjusted the text to make it stand out more.&lt;/p&gt;

&lt;p&gt;Here are the steps to customise it in this way:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;In Adium preferences, go to the Appearance tab. Select &amp;#8216;iBubble status&amp;#8217; in the Status Icons drop-down.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Click on the Theme drop-down and select &amp;#8216;Add New Theme&amp;#8230;&amp;#8217;. Give it a name and make the following customisations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;set the background to black&lt;/li&gt;
&lt;li&gt;turn off highlight and alternate grid&lt;/li&gt;
&lt;li&gt;on the status tab, set online to white and offline to 25% grey&lt;/li&gt;
&lt;li&gt;still on the status tab, turn off the other status colours and tick &amp;#8216;Dim icons of online contacts at the bottom&amp;#8217;&lt;/li&gt;
&lt;li&gt;for the groups tab, pick black text and two shades of grey that work with this. I set the text shadow and first background colour to 25% grey, and the second background color to 50% grey.&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Click on the List Layout drop-down and select &amp;#8216;Add New Layout&amp;#8230;&amp;#8217;. Give it a name and make the following customisations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;select left alignment for contacts&lt;/li&gt;
&lt;li&gt;leave the fonts at 11pt and 10pt Lucida Grande&lt;/li&gt;
&lt;li&gt;uncheck the &amp;#8216;Show (idle status) (below name)&amp;#8217; option&lt;/li&gt;
&lt;li&gt;uncheck the &amp;#8216;Show user icon&amp;#8217; option&lt;/li&gt;
&lt;li&gt;check the &amp;#8216;Show status icons&amp;#8217; option and select the &amp;#8216;Far Left&amp;#8217; position from the drop-down&lt;/li&gt;
&lt;li&gt;uncheck the &amp;#8216;Show service icons&amp;#8217; option&lt;/li&gt;
&lt;li&gt;leave the groups tab settings with the default, bold Lucida Grande 11pt, left-aligned&lt;/li&gt;
&lt;li&gt;set the spacing to the following values: Spacing 6px, Left Margin 1px, Right Margin 1px, Mockie Spacing 2px.&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Set the Window Style to &amp;#8216;Group Bubbles&amp;#8217;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Set the opacity to 66%.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Set the width to 175 px.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That&amp;#8217;s pretty much it on the appearance customisation.  I don&amp;#8217;t really customise the message view at all.&lt;/p&gt;

&lt;p&gt;On the View menu, I hide offline contacts and sort contacts alphabetically. I also have Show Groups enabled.&lt;/p&gt;

&lt;p&gt;The only other setting I always change when installing Adium is on the &amp;#8216;General&amp;#8217; tab, where I make the keys to switch tabs Command-brackets. Otherwise Command-left and Command-right don&amp;#8217;t go to the start and end of line like other Mac applications.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-16T07:31:28+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/making-adium-look-hot</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/making-adium-look-hot</feedburner:origLink></item>

<item>
	<title>Still no iPhone for me</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/335485168/still-no-iphone-for-me</link>
	<description>&lt;p&gt;Despite &lt;a href="http://www.mattryall.net/blog/2008/07/picking-an-iphone-plan"&gt;picking my plan&lt;/a&gt; early last week, long queues have on several occasions put me off getting an iPhone since they went on sale last Friday in Sydney.&lt;/p&gt;

&lt;p&gt;Originally, I was planning to head up to the &lt;a href="http://maps.google.com/maps?f=q&amp;amp;hl=en&amp;amp;geocode=&amp;amp;q=1%20oxford%20st%2C%20sydney%2C%20australia&amp;amp;mrt=all"&gt;Optus store on Oxford St&lt;/a&gt; early in the morning. I missed my alarm and by the time I was dressed and near the store, the queue wasn&amp;#8217;t too bad with only twenty or thirty people. Unfortunately, they had sold out of the black 16 GB model I wanted, so I headed off towards the city to see if there were any easy purchases there.&lt;/p&gt;

&lt;p&gt;The queue at &lt;a href="http://maps.google.com/maps?f=q&amp;amp;hl=en&amp;amp;geocode=&amp;amp;q=pitt%20st%20mall%2C%20sydney&amp;amp;mrt=all"&gt;Optus in Pitt St&lt;/a&gt; was much longer, and they had sold out of 16 GB phones too. I didn&amp;#8217;t walk past the Apple store that morning, but some of my friends had turned up at 7 am and didn&amp;#8217;t get their phones until lunchtime.&lt;/p&gt;

&lt;p&gt;By Sunday, I was sure that I&amp;#8217;d be able to walk into &lt;a href="http://www.apple.com/au/retail/sydney/"&gt;the Apple store&lt;/a&gt; and pick up a phone without joining a queue. No such luck. I walked past at 2 pm on Sunday, and the queue was &lt;em&gt;still&lt;/em&gt; across the length of the ground floor of the Apple store and out the door around to King St.&lt;/p&gt;

&lt;p&gt;I&amp;#8217;m starting to wonder when this craziness will go away. Not that I&amp;#8217;m worried too much about getting the phone &amp;#8212; I still have a phone that works well &amp;#8212; but it does seem a bit weird that I might have to line up to get a phone an entire week after it has been released and on sale in hundreds of places across the country.&lt;/p&gt;

&lt;p&gt;Does anyone have a tip on where I might be able to get a 16 GB black iPhone and not have to queue? I want to sign up with an Optus 12-month contract.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-15T08:06:22+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/still-no-iphone-for-me</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/still-no-iphone-for-me</feedburner:origLink></item>

<item>
	<title>ICFP programming contest 2008</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/335017826/icfp-programming-contest-2008</link>
	<description>&lt;p&gt;This year I organised another team from work for the &lt;a href="http://www.icfpcontest.org/"&gt;ICFP programming contest&lt;/a&gt;. Our team, &lt;em&gt;The Unchecked Exceptions&lt;/em&gt;, this year consisted of Chris, Jed, &lt;a href="http://diversions.nfshost.com/blog/"&gt;Tom&lt;/a&gt; and me.&lt;/p&gt;

&lt;p&gt;I&amp;#8217;ll write up a more thorough report once I recover from the lack of sleep, but I can safely say we all had a great time writing our &lt;a href="http://smlnj.org/icfp08-contest/task.html"&gt;Martian rover AI&lt;/a&gt;. Below are a couple of screenshots of our work that I took over the weekend.&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/simulator.png"&gt;&lt;img alt="Rover simulator screenshot" src="http://www.mattryall.net/image/simulator-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
Our rover running on the provided simulator (click to see full image)
&lt;/p&gt;

&lt;p&gt;We wrote a couple of different visualisation tools to help show different aspects of the Martian rover strategy. Our chosen method of detecting tangents of obstacles was quite easy to show in the different visualisations.&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/obstacle-detection.png"&gt;&lt;img alt="Obstacle detection screenshot" src="http://www.mattryall.net/image/obstacle-detection-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
Obstacle detection with visualisation (click to see full image)
&lt;/p&gt;

&lt;p&gt;Another tool that helps with the analysis of our paths was watching the trails of objects, to chart our AI&amp;#8217;s reaction to surrounding objects.&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/visualisation-trails.png"&gt;&lt;img alt="Visualisation with trails screenshot" src="http://www.mattryall.net/image/visualisation-trails-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
Visualisation with trails and obstacles (click to see full image)
&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/almost-hit-a-martian.png"&gt;&lt;img alt="Another visualisation screenshot" src="http://www.mattryall.net/image/almost-hit-a-martian-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
Another visualisation (click to see full image)
&lt;/p&gt;

&lt;p&gt;After making the AI work reasonably well, we discovered a surprising bug in our tangent calculation function. The graph below showed the problems.&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/broken-tangent-function.png"&gt;&lt;img alt="Tangent screenshot" src="http://www.mattryall.net/image/broken-tangent-function-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
Tangent function analysis (click to see full image)
&lt;/p&gt;

&lt;p&gt;Thanks to the competition organisers and my team mates &amp;#8212; for me, it was definitely the most interesting competition so far!&lt;/p&gt;

&lt;p&gt;I&amp;#8217;ll write some more thorough notes about our algorithm and results in a couple of days.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-14T20:29:23+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/icfp-programming-contest-2008</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/icfp-programming-contest-2008</feedburner:origLink></item>

<item>
	<title>Benefit #35 of open source software</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/333923099/open-source</link>
	<description>&lt;p&gt;Several years ago, while I was still working for &lt;a href="http://www.macquarie.com.au"&gt;a bank&lt;/a&gt; and writing Java code in &lt;a href="http://www.eclipse.org"&gt;Eclipse&lt;/a&gt;, I found myself wanting split-screen editing in Eclipse. I found the relevant improvement request: &lt;a href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=8009"&gt;Bug 8009&lt;/a&gt; in the Eclipse issue tracker, and added myself as a CC. &lt;/p&gt;

&lt;p&gt;For over three years now, I&amp;#8217;ve been getting updates on patches to partially fix the problem, plugins people have developed to work around it, and watching many other people being added as CCs. There have been over a hundred comments on the bug, many of them from people wondering how such basic functionality can go unimplemented for so long.&lt;/p&gt;

&lt;p&gt;The reason for this is simple. The feature is hard to implement, and noone in the Eclipse community thinks it is important enough to spend their free time implementing it, testing it, and getting into the main release. I don&amp;#8217;t blame them. I&amp;#8217;d rather spend my spare time doing something else too.&lt;/p&gt;

&lt;p&gt;But with the last comment came some hope. &lt;a href="http://bonovox.be/blog/"&gt;Nikolay Botev&lt;/a&gt; is going to be working on this task as part of the &lt;a href="http://code.google.com/soc/2008/"&gt;Google Summer of Code&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;To the 180+ fans of this bug-&lt;/p&gt;
  
  &lt;p&gt;If you still have not given up on Eclipse out of frustration for the lack of
  split editing, there is still hope!&lt;/p&gt;
  
  &lt;p&gt;I am working on fixing this bug as part of Google Summer of Code.&lt;/p&gt;
  
  &lt;p&gt;You can track my progress on &lt;a href="http://bonovox.be/blog/"&gt;my blog&lt;/a&gt; and the &lt;a href="http://wiki.eclipse.org/index.php?title=Implement_Split_File_Editor_Functionality_for_the_Eclipse_IDE#Implementations"&gt;Eclipse
  wiki&lt;/a&gt;&lt;/p&gt;
  
  &lt;p&gt;The first, VERY early prototype of a split editor is available for download.
  Check out either the blog or the wiki for a link and instructions.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And this is benefit #35 of open source software: features can be requested and left unimplemented for a very long time. Once someone is interested in implementing it, all the patches, plugins and requests from interested people are archived ready for the implementer to pick up.&lt;/p&gt;

&lt;p&gt;You can some of the same benefits in commercial projects by having a public issue tracker. Of course, it&amp;#8217;s not possible for anyone to actually resolve the problem or implement the feature, but you do get the benefits of having all discussion about a particular issue archived in a single location. If customers have the source code of your software, they can provide patches that might partially solve the problem. &lt;/p&gt;

&lt;p&gt;This benefit is what we see at Atlassian with our &lt;a href="http://jira.atlassian.com"&gt;public issue tracker&lt;/a&gt;. It definitely far outweighs the drawbacks of people being able to see a list of problems in your software and how long you have left a particular feature unimplemented. In fact, we tend to think that is a good thing too &amp;#8212; customers should be able to see the defects and missing features &lt;em&gt;before&lt;/em&gt; they purchase the software, not after.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-13T10:24:04+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/open-source</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/open-source</feedburner:origLink></item>

<item>
	<title>Artistic JavaScript</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/333081976/artistic-javascript</link>
	<description>&lt;p&gt;I came across this amazing JavaScript art project this morning, &lt;a href="http://azarask.in/projects/algorithm-ink/"&gt;Algorithm Ink&lt;/a&gt;. Have a read of &lt;a href="http://azarask.in/blog/post/contextfreejs-algorithm-ink-making-art-with-javascript/"&gt;Aza&amp;#8217;s introductory blog post&lt;/a&gt;, which explains how to use the tool:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;In honor of the the release of Firefox 3, I’m releasing ContextFree.js today, along with the demo site &lt;a href="http://azarask.in/projects/algorithm-ink/"&gt;Algorithm Ink&lt;/a&gt;. ContextFree.js is about drawing striking images&amp;#8212;and making art&amp;#8212;with minimal amounts of code.&lt;/p&gt;
  
  &lt;p&gt;Computers programs lost something important when displaying a splash of color stopped being one line of code. As a kid, I remember being able to type “plot x,y” on the Apple II to throw up a phosphorescent splotch. When the simplicity of the one-line plotter went away, so did the delight at being so effortlessly generative&amp;#8212;in a visual way&amp;#8212;on the computer. ContextFree.js is a stab at making it easy again. It’s like a grown up version of Logo (or at least the Turtle Graphics part of Logo).&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Here&amp;#8217;s a little graphic I made, with some very simple changes to the example he gives:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://www.mattryall.net/image/circles-canvas.png" alt="&amp;quot;Circles&amp;quot;" /&gt; &lt;br /&gt;
&lt;em&gt;Circles&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Unfortunately, I closed my browser tab and lost the source to this amazing work of art. I&amp;#8217;m sure it won&amp;#8217;t be hard for someone to &lt;a href="http://azarask.in/projects/algorithm-ink/"&gt;recreate&lt;/a&gt;, though.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-12T07:28:52+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/artistic-javascript</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/artistic-javascript</feedburner:origLink></item>

<item>
	<title>jQuery filter demo</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/332126055/jquery-filter-demo</link>
	<description>&lt;p&gt;The other night I spent a few hours hacking together an upload file control for this site. As part of that work, I decided to build a little file viewer which let me see all the images I had uploaded so far.&lt;/p&gt;

&lt;p&gt;It turned out to be a pretty neat example of jQuery and a CSS grid layout, so I split out the filtering into a new demo: &lt;a href="http://www.mattryall.net/demo/filter/"&gt;Filter demo&lt;/a&gt;.&lt;/p&gt;

&lt;p class="figure" style="text-align: center"&gt;
&lt;a href="http://www.mattryall.net/demo/filter/"&gt;&lt;img alt="Filter demo screenshot" src="http://www.mattryall.net/image/filter-demo.png" title="Filter demo"/&gt;&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;You just type a few keystrokes and some JavaScript goes through the list of pictures and selects the ones with titles that match what you typed. Surprisingly, the JavaScript for this with jQuery is very simple:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$("#filter").keyup(function () {
    var filter = $(this).val(), count = 0;
    $(".filtered:first li").each(function () {
        if ($(this).text().search(new RegExp(filter, "i")) &amp;lt; 0) {
            $(this).addClass("hidden");
        } else {
            $(this).removeClass("hidden");
            count++;
        }
    });
    $("#filter-count").text(count);
});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;It uses an input field with an ID of &amp;#8216;filter&amp;#8217;, a list contained in an element with class &amp;#8216;filtered&amp;#8217;, and uses the text inside each list item for filtering. The element with an ID of &amp;#8216;filter-count&amp;#8217; has its value set to the number of elements remaining after the filter is applied.&lt;/p&gt;

&lt;p&gt;This should be generic enough that it&amp;#8217;s possible to apply it to many different situations. You could also modify the matching line to use &lt;a href="http://orderedlist.com/articles/live-search-with-quicksilver-style-for-jquery"&gt;the Quicksilver scoring algorithm&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The layout is completely CSS based, and should scale up and down and reflow nicely in browsers with decent CSS support. It took me quite a while to get that right, and I had to add one non-meaningful element to the markup to fix the width of each image-caption pair.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-11T07:33:07+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/jquery-filter-demo</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/jquery-filter-demo</feedburner:origLink></item>

<item>
	<title>Speculating about the price of petrol</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/331164087/speculating-about-the-price-of-petrol</link>
	<description>&lt;p&gt;I&amp;#8217;ve heard a few rumblings recently about the price of petrol, which has often surpassed $1.60 per litre in Sydney (that&amp;#8217;s US$5.68 per gallon). Several people have commented that the speculation in the oil futures market is somehow the cause of these price increases. Even our government is &lt;a href="http://www.smh.com.au/news/national/rudd-fingers-financial-speculators-in-oil/2008/06/19/1213770827377.html" title="Rudd fingers financial speculators in oil"&gt;pursuing this idea&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Kevin Rudd told Parliament there were increasing concerns in the international community about the role of excessive speculation by financial institutions trading oil as an investment like shares and currencies.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The Economist has a good article which &lt;a href="http://www.economist.com/opinion/displayStory.cfm?source=hptextfeature&amp;amp;story_id=11670357" title="The oil price: don't blame the speculators"&gt;debunks this myth&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Neither index funds nor other speculators ever buy any physical oil. Instead, they buy futures and options which they settle with a cash payment when they fall due. In essence, these are bets on which way the oil price will move. Since the real currency of such contracts is cash, rather than barrels of crude, there is no limit to the number of bets that can be made. And since no oil is ever held back from the market, these bets do not affect the price of oil any more than bets on a football match affect the result.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In fact, because hedging in the futures market allows both oil producers and consumers to provide security around their future income or expenses, it helps maintain the liquidity of the oil market:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Despite their dismal reputation, the oil speculators provide a vital service. They help airlines and other big oil consumers to hedge against rising prices, and so to reduce risk&amp;#8212;a massive boon amid the economic turmoil. By the same token, they provide oil producers with more predictable future revenues, and so allow them to expand more confidently and borrow more cheaply. That, in turn, should help to lower the price of oil in the long run. Any attempt to curtail speculation, by contrast, is likely to make life harder for firms and oil more expensive.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The speculators and futures market exist as an open market which improves the flow of goods and services within the economy. Don&amp;#8217;t buy into the idea that these important markets are responsible for unjustified movements in the price of oil.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-10T08:15:47+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/speculating-about-the-price-of-petrol</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/speculating-about-the-price-of-petrol</feedburner:origLink></item>

<item>
	<title>Picking an iPhone plan</title>
	<link>http://feeds.feedburner.com/~r/mattryall/~3/330222277/picking-an-iphone-plan</link>
	<description>&lt;p&gt;Like many people in Sydney, I&amp;#8217;m considering buying an iPhone when it&amp;#8217;s released later this week. A friend just sent through this great tool that finds the right tool for you: &lt;a href="http://mobile-phones.smh.com.au/Mobile"&gt;SMH: Find the best mobile phone plan&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Here&amp;#8217;s a screenshot of my recommended plans:&lt;/p&gt;

&lt;p class="figure"&gt;
&lt;a href="http://www.mattryall.net/image/plans.png" title="iPhone plans"&gt;&lt;img alt="Mobile phone plans screenshot" src="http://www.mattryall.net/image/plans-thumbnail.png"/&gt;&lt;/a&gt;&lt;br/&gt;
My suggested iPhone plans
&lt;/p&gt;

&lt;p&gt;I make just a few short calls typically, so hopefully my plan won&amp;#8217;t be too expensive.&lt;/p&gt;
</description>
	<dc:creator>Matt Ryall</dc:creator>
	<dc:date>2008-07-09T08:11:28+11:00</dc:date>
	<guid isPermaLink="false">http://www.mattryall.net/blog/2008/07/picking-an-iphone-plan</guid>
<feedburner:origLink>http://www.mattryall.net/blog/2008/07/picking-an-iphone-plan</feedburner:origLink></item>


</channel>
</rss>
