<?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>Nutsmuggling &#187; Technolalia</title>
	<atom:link href="http://davidebenini.it/category/technolalia/feed/" rel="self" type="application/rss+xml" />
	<link>http://davidebenini.it</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Thu, 29 Apr 2010 10:34:42 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Rails 2.3.3 + Ruby 1.8.7 + Gmail SMTP settings</title>
		<link>http://davidebenini.it/2009/06/25/rails-233-ruby-187-gmail-smtp-settings/</link>
		<comments>http://davidebenini.it/2009/06/25/rails-233-ruby-187-gmail-smtp-settings/#comments</comments>
		<pubDate>Thu, 25 Jun 2009 07:11:45 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[rubyonrails]]></category>
		<category><![CDATA[1.8.7]]></category>
		<category><![CDATA[2.3.2]]></category>
		<category><![CDATA[actionmailer]]></category>
		<category><![CDATA[gmail]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[smtp]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=506</guid>
		<description><![CDATA[How to setup Rails to use you gmail smtp without installing any plugin]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s not rocket science, but since I took a while to figure this out I thought I&#8217;d share:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby" style="font-family:monospace;"><span style="color:#6666ff; font-weight:bold;">ActionMailer::Base</span>.<span style="color:#9900CC;">smtp_settings</span> = <span style="color:#006600; font-weight:bold;">&#123;</span>
  <span style="color:#ff3333; font-weight:bold;">:enable_starttls_auto</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#0000FF; font-weight:bold;">true</span>,
  <span style="color:#ff3333; font-weight:bold;">:address</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#996600;">&quot;smtp.gmail.com&quot;</span>,
  <span style="color:#ff3333; font-weight:bold;">:port</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#006666;">587</span>,
  <span style="color:#ff3333; font-weight:bold;">:domain</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#996600;">&quot;your-google-apps-domain&quot;</span>,
  <span style="color:#ff3333; font-weight:bold;">:authentication</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:plain</span>,
  <span style="color:#ff3333; font-weight:bold;">:user_name</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#996600;">&quot;username&quot;</span>,
  <span style="color:#ff3333; font-weight:bold;">:password</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#996600;">&quot;password&quot;</span>
<span style="color:#006600; font-weight:bold;">&#125;</span></pre></div></div>

<p>The most important line is <code>enable_starttls_auto =&gt; true</code>.</p>
<p>Unlike pre 2.2 Rails, no plugin is required. Not sure this setup works with Rails 2.2 though, never tried it.</p>
<p>Via <a href="http://www.railsforum.com/viewtopic.php?id=28480">this forum discussion</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2009/06/25/rails-233-ruby-187-gmail-smtp-settings/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>How I blueprint semantically</title>
		<link>http://davidebenini.it/2009/05/12/how-i-blueprint-semantically/</link>
		<comments>http://davidebenini.it/2009/05/12/how-i-blueprint-semantically/#comments</comments>
		<pubDate>Tue, 12 May 2009 14:29:53 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[advantages]]></category>
		<category><![CDATA[blueprint]]></category>
		<category><![CDATA[blueprintcss]]></category>
		<category><![CDATA[classes]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[disadvantages]]></category>
		<category><![CDATA[semantic]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=415</guid>
		<description><![CDATA[Lately there&#8217;s been a lot of talk about CSS frameworks, their advantages and disadvantages, and why you should or should not use them. Myself, I was quite curious about the concept of a CSS framework, but frankly had no idea about what a CSS framework could be. Then I had to refactor an existing style-sheet [...]]]></description>
			<content:encoded><![CDATA[<p>Lately there&#8217;s been a lot of talk about CSS frameworks, their advantages and disadvantages, and why you should or should not use them. Myself, I was quite curious about the concept of a CSS framework, but frankly had no idea about what a CSS framework could be. Then I had to refactor an existing style-sheet based on blueprint CSS, and that&#8217;s how I learned how blueprint works.</p>
<p><a href="http://www.blueprintcss.org/">Blueprint</a> is probably the most widespread CSS framework out there; I ignore whether Josh Clayton, blueprint&#8217;s dad, was the first to think about CSS frameworks, but for certain blueprint was the first framework to get good coverage in the geek news.</p>
<p>Since I had to deal with it anyway, I said &#8220;Why shouldn&#8217;t I use this gig as an occasion to learn something new?&#8221; And I did indeed. Not sure the last line is graceful to the ear, but let&#8217;s roll on.</p>
<h3>How I blueprinted at first</h3>
<p>The style-sheet I was working on wasn&#8217;t exactly tidy. To tidy it up, I had to look into the infamous grid.css and try to understand what those weird &#8220;span-n&#8221; classes were doing. Luckily, all of blueprint source files [[I know what you're thinking, <code>source files</code>, what now, do I have to use gcc for a css style-sheet? Not quite, but we'll get there.]] are well commented and clear.</p>
<p>The basic concept is that your layout is divided i 24 columns. You can put div whose width is determined by the aforementioned <code>.span-n</code> class. Just remember:</p>
<ul>
<li>put all you columns in the <code>.container</code> class</li>
<li>to make sure you reach &#8220;24&#8243; as a sum</li>
<li>you include <code>.last</code> in the last column of each row.</li>
</ul>
<p>You know the headaches of creating a well-clearing three-columns layout? Here&#8217;s how you do that with blueprint:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;div class='container'&gt;
	&lt;div class='span-6'&gt;
		left column
	&lt;/div&gt;
	&lt;div class='span-12'&gt;
		center column
	&lt;/div&gt;
	&lt;div class='span-6 last'&gt;
		right column
	&lt;/div&gt;
&lt;/div&gt;</pre></div></div>

<p>And this is it; but not all of it. You can add <code>.prepend-n</code> classes to prepend empty column, and <code>.append-n</code>to append them. You also have other nifty classes for hr, vertical lines and so on. In addition, and maybe more importantly, blueprint gives good typography [[Ever heard about vertical rhythm?]] and a CSS reset to make sure your website is cross-browser compatible. And it&#8217;s free.<br />
So it is good, why shouldn&#8217;t I use it?</p>
<h3>Ehm, what about semantic mark-up?</h3>
<p>Exactly, that is the problem. Just when we managed to get rid of the tables and their meaningless cell classes, here comes a CSS framework which binds you to class names that are just referred to measures, not semantic at all. Also, someone with no awareness of the concept of semantic could (mis)use blueprint as a pseudo-table; <code>.span-n</code> could be seen as a regurgitation of the <code>colspan</code> attribute of <code>td</code> cells. And sure we don&#8217;t want that, do we?</p>
<h3>Luckily there&#8217;s more</h3>
<p>Earlier I mentioned the <code>source</code>files, and I am sure some of you startled and thought that they had to learn c to use blueprint. Luckily that&#8217;s not the case, although there&#8217;s some ruby behind blueprint&#8217;s magic. The stylesheet you are supposed to attach to your html files (<code>screen.css</code>,<code>print.css</code>,<code>ie.css</code>) originally result from the compilation of the source style-sheets (<code>grid.css</code>,<code>typography.css</code> ans so an, all in the <code>src</code> directory) according to certain criteria. You can choose to ignore all of this, or you can decide you want to be a good, semantic coder and become a blueprint superuser. You don&#8217;t have much of a choice, do you?</p>
<h3>Welcome settings.yml</h3>
<p><code>settings.yml</code> is your best friend. Really, it is. This nice guy allows you to customise any aspect of the blueprint stylesheet. You might want more or less columns, wider ones, or more space between them. josh has a <a href="http://www.jdclayton.com/blueprints_compress_a_walkthrough.html">nice page</a> illustrating how you can customise blueprint. </p>
<p>I have a settings.yml file in <code>~/developing/bluprint/lib</code>, containing all the settings for each single project I am working on.<br />
When I start a new blueprint-based project, I just add a new entry to this file.</p>
<p>What I want to stress is the importance of leaving the <code>span-n</code> class alone (unless occasionally and during wireframing) and use the <em>semantic classes</em>. These classes (or ids) are defined at the end of each project entry. What they do is associating a semantic name to a geometric blueprint class. Look at the entry corresponding to my current project:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby" style="font-family:monospace;">personalproject:
	path: ~<span style="color:#006600; font-weight:bold;">/</span>blahblah<span style="color:#006600; font-weight:bold;">/</span>personalproject<span style="color:#006600; font-weight:bold;">/</span>
	custom_css:
    	ie.<span style="color:#9900CC;">css</span>:
    		<span style="color:#006600; font-weight:bold;">-</span> custom<span style="color:#006600; font-weight:bold;">-</span>ie.<span style="color:#9900CC;">css</span>
    	screen.<span style="color:#9900CC;">css</span>:
    		<span style="color:#006600; font-weight:bold;">-</span> custom<span style="color:#006600; font-weight:bold;">-</span>screen.<span style="color:#9900CC;">css</span>
  	custom_layout:
    	column_count: <span style="color:#006666;">24</span>
    	column_width: <span style="color:#006666;">30</span>
    	gutter_width: <span style="color:#006666;">10</span>
  	semantic_classes:
    	<span style="color:#996600;">&quot;#featured&quot;</span>: <span style="color:#996600;">&quot;.span-15, div.span-15&quot;</span></pre></div></div>

<p>In the last section, <code>#featured</code> is defined as equivalent to <code>.span-15, div.span-15</code>. In this way my layout will contain this:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;div id='featured'&gt;
	blah
&lt;/div&gt;</pre></div></div>

<p>instead of this</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;div class='span-15'&gt;
	blah
&lt;/div&gt;</pre></div></div>

<p>The difference is obvious.</p>
<p>And there&#8217;s more. Think about how easy it is to manage your layout this way. You don&#8217;t have to think about paddings and margins, you just think about columns, their number and their width. If I decide that I want to give a column more to my <code>#featured</code> article, I just alter a line in <code>settings.yml</code>: [[Of course you must also contract the following column, the sum must always be the same. ]]</p>

<div class="wp_syntax"><div class="code"><pre class="ruby" style="font-family:monospace;">	<span style="color:#996600;">&quot;#featured&quot;</span>: <span style="color:#996600;">&quot;.span-16, div.span-16&quot;</span></pre></div></div>

<p>and recompress through this terminal command:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">	ruby compress.rb <span style="color: #660033;">-p</span> personalproject</pre></div></div>

<p>If you decide your whole website is too wide, just narrow the columns and recompile. And so on.<br />
Of course your workflow has to adjust a little, but the advantages in terms of flexibility are enormous.</p>
<h3>Blueprint is not a ghetto</h3>
<p>Blueprint is perfectly suited for building an entire layout, but if you decide this is not your piece of cake, there&#8217;s no problem at all. All you have to do is insert one or more <code>.container</code>s into you css layout. I generally prefer to use blueprint for the main textual area, and leave the header (and sometimes the footer) alone. This way I can use wider divs for the background, and avoid using empty columns at the sides.</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;html&gt;
&lt;head&gt;[...]&lt;/head&gt;
&lt;body&gt;
	&lt;div id='wrapper'&gt;
		&lt;!-- This div has a nice background with shadows ad stuff --&gt;
		&lt;!-- Here I often put my header --&gt;
		&lt;div class='container'&gt;
			&lt;!-- Here goes the blueprint stuff --&gt;
		&lt;/div&gt;
	&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;</pre></div></div>

<h3>How I blueprint now</h3>
<p>Remember that first super-fast layout? Now we can remake it semantically. We just have to play a bit with <code>settings.yml</code> and <code>compress.rb</code>. </p>
<p>Here&#8217;s our <code>settings.yml</code></p>

<div class="wp_syntax"><div class="code"><pre class="ruby" style="font-family:monospace;">semanticlayout:
	path: ~<span style="color:#006600; font-weight:bold;">/</span>blahblah<span style="color:#006600; font-weight:bold;">/</span>semanticlayout<span style="color:#006600; font-weight:bold;">/</span>
	custom_css:
  		ie.<span style="color:#9900CC;">css</span>:
   			<span style="color:#006600; font-weight:bold;">-</span> custom<span style="color:#006600; font-weight:bold;">-</span>ie.<span style="color:#9900CC;">css</span>
   		screen.<span style="color:#9900CC;">css</span>:
   			<span style="color:#006600; font-weight:bold;">-</span> custom<span style="color:#006600; font-weight:bold;">-</span>screen.<span style="color:#9900CC;">css</span>
	custom_layout:
  		column_count: <span style="color:#006666;">24</span>
   		column_width: <span style="color:#006666;">30</span>
   		gutter_width: <span style="color:#006666;">10</span>
	semantic_classes:
   		<span style="color:#996600;">&quot;#left-sidebar&quot;</span>: <span style="color:#996600;">&quot;.span-6, div.span-6&quot;</span>
   		<span style="color:#996600;">&quot;#content&quot;</span>: <span style="color:#996600;">&quot;.span-12, div.span-12&quot;</span>
   		<span style="color:#996600;">&quot;#right-sidebar&quot;</span>: <span style="color:#996600;">&quot;.span-6, div.span-6, .last&quot;</span></pre></div></div>

<p>And here&#8217;s a clear-as-crystal layout:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;div class='container'&gt;
	&lt;div id='left-sidebar'&gt;
		left column
	&lt;/div&gt;
	&lt;div id='content'&gt;
		center column
	&lt;/div&gt;
	&lt;div class='right-sidebar'&gt;
		right column
	&lt;/div&gt;
&lt;/div&gt;</pre></div></div>

<p>Ain&#8217;t it nice? Fast, reliable, typographical <em>and</em> semantic.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2009/05/12/how-i-blueprint-semantically/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>iPhone SDK: sending formatted email</title>
		<link>http://davidebenini.it/2008/12/19/iphone-sdk-sending-formatted-email/</link>
		<comments>http://davidebenini.it/2008/12/19/iphone-sdk-sending-formatted-email/#comments</comments>
		<pubDate>Fri, 19 Dec 2008 18:40:34 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[iPhone SDK]]></category>
		<category><![CDATA[e-mail]]></category>
		<category><![CDATA[formatted]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=205</guid>
		<description><![CDATA[As a part of an iPhone app I&#8217;m presently working on1 I was confronted with an apparently simple problem, which turned out to be more difficult than I thought.
Except it was simple, once you knew how to do it.
Question
How do I send a tabular report via e-mail in the iPhone SDK?  
Short answer
Use a [...]]]></description>
			<content:encoded><![CDATA[<p>As a part of an iPhone app I&#8217;m presently working on<sup>1</sup> I was confronted with an apparently simple problem, which turned out to be more difficult than I thought.<br />
Except it was simple, once you knew how to do it.</p>
<h3>Question</h3>
<p>How do I send a tabular report via e-mail in the iPhone SDK?  </p>
<h3>Short answer</h3>
<p>Use a <code>mailto</code> url + <code>stringByAddingPercentEscapesUsingEncoding</code> + HTML.</p>
<h3>Longer answer</h3>
<p>So far (iPhone OS 2.2) the de facto way to send e-mail on your iPhone application is using a <code>mailto</code> url.<sup>2</sup></p>

<div class="wp_syntax"><div class="code"><pre class="objc" style="font-family:monospace;"><span style="color: #400080;">NSURL</span> <span style="color: #002200;">*</span>url <span style="color: #002200;">=</span> <span style="color: #002200;">&#91;</span><span style="color: #002200;">&#91;</span><span style="color: #400080;">NSURL</span> alloc<span style="color: #002200;">&#93;</span> initWithString<span style="color: #002200;">:</span>
<span style="color: #bf1d1a;">@</span><span style="color: #bf1d1a;">&quot;mailto:me@me.com?subject=subject&amp;body=Hi&quot;</span><span style="color: #002200;">&#93;</span>;
<span style="color: #002200;">&#91;</span><span style="color: #002200;">&#91;</span>UIApplication sharedApplication<span style="color: #002200;">&#93;</span> openURL<span style="color: #002200;">:</span>url<span style="color: #002200;">&#93;</span>;</pre></div></div>

<p>Of course you can use a format to include your own dynamic text, but the url string must be url escaped. Cocoa(Touch) provides a nice way to escape URLs, <code>stringByAddingPercentEscapesUsingEncoding:</code></p>

<div class="wp_syntax"><div class="code"><pre class="objc" style="font-family:monospace;"><span style="color: #400080;">NSString</span> <span style="color: #002200;">*</span>encodedBody <span style="color: #002200;">=</span> <span style="color: #002200;">&#91;</span>eMailBody stringByAddingPercentEscapesUsingEncoding<span style="color: #002200;">:</span>NSUTF8StringEncoding<span style="color: #002200;">&#93;</span>;</pre></div></div>

<p>The only problem left was representing tabular data. At first I though I&#8217;d use <code>\t</code> to create tabs, but I found out they&#8217;re not properly supported in e-mail bodies. Then a <a href="http://groups.google.com/group/iphonewebdev/browse_thread/thread/31496da7ed877667">discussion</a> on the Google Groups gave me the hint, the <code>body</code> parameter of <code>mailto</code> is actually parsed as HTML.<br />
So, amazing as it seems, this code works:</p>

<div class="wp_syntax"><div class="code"><pre class="objc" style="font-family:monospace;"><span style="color: #400080;">NSString</span> <span style="color: #002200;">*</span>eMailBody <span style="color: #002200;">=</span> <span style="color: #bf1d1a;">@</span><span style="color: #bf1d1a;">&quot;&lt;table&gt;
&lt;tr&gt;&lt;td style='text-align:right'&gt;&lt;b&gt;Name&lt;/b&gt;:&lt;/td&gt;
&lt;td&gt;John&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;
&lt;td style='text-align:right'&gt;&lt;b&gt;Surname&lt;/b&gt;:&lt;/td&gt;&lt;td&gt;Doe&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style='text-align:right'&gt;
 &lt;b&gt;Occupation:&lt;b/&gt;&lt;/td&gt;&lt;td&gt;Placeholder&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&quot;</span>;
<span style="color: #400080;">NSString</span> <span style="color: #002200;">*</span>encodedBody <span style="color: #002200;">=</span> 
<span style="color: #002200;">&#91;</span>eMailBody stringByAddingPercentEscapesUsingEncoding<span style="color: #002200;">:</span>NSUTF8StringEncoding<span style="color: #002200;">&#93;</span>; 
<span style="color: #400080;">NSString</span> <span style="color: #002200;">*</span>urlString <span style="color: #002200;">=</span> 
<span style="color: #002200;">&#91;</span><span style="color: #400080;">NSString</span> stringWithFormat<span style="color: #002200;">:</span><span style="color: #bf1d1a;">@</span><span style="color: #bf1d1a;">&quot;mailto:me@me.com?subject=HiPhone&amp;body=%@&quot;</span>, encodedBody<span style="color: #002200;">&#93;</span>;
<span style="color: #400080;">NSURL</span> <span style="color: #002200;">*</span>url <span style="color: #002200;">=</span> <span style="color: #002200;">&#91;</span><span style="color: #002200;">&#91;</span><span style="color: #400080;">NSURL</span> alloc<span style="color: #002200;">&#93;</span> initWithString<span style="color: #002200;">:</span>urlString<span style="color: #002200;">&#93;</span>;
<span style="color: #002200;">&#91;</span><span style="color: #002200;">&#91;</span>UIApplication sharedApplication<span style="color: #002200;">&#93;</span> openURL<span style="color: #002200;">:</span>url<span style="color: #002200;">&#93;</span>;</pre></div></div>

<p>And here&#8217;s the result:</p>
<div style="text-align:center;"><img src="http://davidebenini.it/wp-content/uploads/2008/12/img-0001.png" alt="IMG_0001.PNG" border="0" width="320" height="480" /></div>
<p>Bingo!</p>
<p>A weird downside of this method is that the user will be able to edit the email, but not is formatting: the bold characters will stay bold and so on; this seems to be a feature of the mail app itself. </p>
<h3>Device vs Simulator</h3>
<p>Since the iPhone simulator does not have a Mail.app, you can use e-mail URLs only in the actual device. As a matter of fact, it’s advisable to use compiler statements to create specific simulator/device code:</p>

<div class="wp_syntax"><div class="code"><pre class="objc" style="font-family:monospace;"><span style="color: #6e371a;">#if TARGETIPHONESIMULATOR</span>
    <span style="color: #11740a; font-style: italic;">//compiler specific code</span>
<span style="color: #6e371a;">#else</span>
    <span style="color: #11740a; font-style: italic;">// device specific code</span>
<span style="color: #6e371a;">#endif</span></pre></div></div>

<p>In my app, I use a <code>UIAlertView</code> in the simulator code, so I can have the email text displayed onscreen. Currently I have a <code>UITextView</code> as its subview, but I plan to use a <code>UIWebView</code>, so I can preview the HTML in the simulator.</p>
<p><em>(Thanks to <a href="http://www.hakbox.com/">Slashzero</a>  for his comment)</em></p>
<h4>Notes</h4>
<ol class="footnotes">
<li id="footnote_0_205" class="footnote">shush shush, too early to talk about it!</li>
<li id="footnote_1_205" class="footnote">Please note that, although the mailto protocol might support attachments, you specify attachment with the sdk. I know, it&#8217;s a shame, but so far we&#8217;re not allowed to send attachments through mail. The alternative is writing your own smtp server, but refrain from doing it, unless the composed mail is sent without any user intervention, otherwise you&#8217;ll also have to write your own mail client. </li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/12/19/iphone-sdk-sending-formatted-email/feed/</wfw:commentRss>
		<slash:comments>24</slash:comments>
		</item>
		<item>
		<title>Wordpress 2.6 is out</title>
		<link>http://davidebenini.it/2008/07/15/wordpress-26-is-out/</link>
		<comments>http://davidebenini.it/2008/07/15/wordpress-26-is-out/#comments</comments>
		<pubDate>Tue, 15 Jul 2008 07:20:44 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[release]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=85</guid>
		<description><![CDATA[The latest release of Wordpress is out, and has a number of new exciting features:

Version control: revert to older saves of your posts
Press this: easily integrate web content into new posts
Image caption
Theme preview
Google Gears support, to speed up your blog with local storage
Fixes and tweaks

&#8217;nuff said, just take a look at the official tour:
 
Ready [...]]]></description>
			<content:encoded><![CDATA[<p>The latest release of Wordpress is out, and has a number of new exciting features:</p>
<ul>
<li>Version control: revert to older saves of your posts</li>
<li>Press this: easily integrate web content into new posts</li>
<li>Image caption</li>
<li>Theme preview</li>
<li>Google Gears support, to speed up your blog with local storage</li>
<li>Fixes and tweaks</li>
</ul>
<p>&#8217;nuff said, just take a look at the official tour:</p>
<p><embed src="http://v.wordpress.com/mARhRBcT/fmt_std" type="application/x-shockwave-flash" width="400" height="250" flashvars="blog_domain=http://wordpress.org/development/2008/07/wordpress-26/&#038;width=400&#038;height=250"> </embed></p>
<p>Ready to upgrade?<br />
Davide</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/07/15/wordpress-26-is-out/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My seven readers&#8230;</title>
		<link>http://davidebenini.it/2008/07/05/my-seven-readers/</link>
		<comments>http://davidebenini.it/2008/07/05/my-seven-readers/#comments</comments>
		<pubDate>Sat, 05 Jul 2008 17:17:07 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Scribblings]]></category>
		<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=77</guid>
		<description><![CDATA[I know there&#8217;s seven of you there waiting for any exciting contribution to the development of mankind that might come out off these humble pages of mine&#8230;
And when I say seven I literally mean seven, for feedburner does not lie.
At any rate, I haven&#8217;t been posting for a while, but I&#8217;m still here; I&#8217;ve been [...]]]></description>
			<content:encoded><![CDATA[<p>I know there&#8217;s seven of you there waiting for any exciting contribution to the development of mankind that might come out off these humble pages of mine&#8230;</p>
<p>And when I say seven I literally mean seven, for feedburner does not lie.</p>
<p>At any rate, I haven&#8217;t been posting for a while, but I&#8217;m still here; I&#8217;ve been developing a new Wordpress plugin, that I&#8217;ll launch in a few days. It&#8217;s about events scheduling and management. So stay tuned, more goodies to come&#8230;<br />
All the best,<br />
Davide</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/07/05/my-seven-readers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Prezzi di iPhone in Italia, un mistero deliberato?</title>
		<link>http://davidebenini.it/2008/06/12/prezzi-di-iphone-in-italia-un-mistero-deliberato/</link>
		<comments>http://davidebenini.it/2008/06/12/prezzi-di-iphone-in-italia-un-mistero-deliberato/#comments</comments>
		<pubDate>Thu, 12 Jun 2008 09:07:05 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Italia]]></category>
		<category><![CDATA[tariffe]]></category>
		<category><![CDATA[Tim]]></category>
		<category><![CDATA[Vodafone]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=76</guid>
		<description><![CDATA[A tre giorni dall'annuncio ufficiale di Apple non è ancora possibile reperire informazioni ufficiali sulle tariffe dei contratti che verranno associati ad iPhone in Italia da Tim e Vodafone. Ignavia o strategia di mercato?]]></description>
			<content:encoded><![CDATA[<p>Da ieri sera è disponibile la <a href="http://iphone.vodafone.it/">pagina di Vodafone dedicata all&#8217;iPhone</a>. Ecco i prezzi riportati: </p>
<blockquote>
<p>Scegliendo un piano Ricaricabile per Privati potrai acquistare direttamente<br />
  sullo Shop online l&#8217;iPhone 3G da 8GB a 499 euro e l&#8217;iPhone 3G da 16GB a 569 euro.</p>
</blockquote>
<p>Prima di correre a conclusioni affrettate sul prezzo spropositato al confronto dei 199$ menzionati da Steve Jobs, ricordiamoci che il mercato telefonico italiano è quantomeno singolare. All&#8217;estero chiunque utilizzi un telefono del genere dà per scontato di acquistarlo con un contratto; da noi invece la modalità &#8220;ricaricabile&#8221; la fa da padrone anche nella fascia business, ma siamo quasi un unicum. Quando Steve Jobs ha annunciato l&#8217;iPhone 3G a 199$ ha dato per scontato, come qualsiasi cittadino americano, che l&#8217;iPhone sarebbe stato venduto assieme a un contratto. In altre parole, AT&amp;T si accolla parte del costo, che recupera con il contratto mensile. È impensabile che il prezzo sia il medesimo senza un contratto: sarebbe un bel regalo, ma Tim e Vodafone non sono babbo natale. I prezzi riportati sul sito di Vodafone sono pertanto quelli relativi al telefono acquistato per un contratto ricaricabile.</p>
<p>Come si legge più sotto, acquistando il telefono con un abbonamento i prezzi sono differenti:</p>
<blockquote>
<p>Con gli abbonamenti iPhone Vodafone Facile avere l&#8217;iPhone è ancora più vantaggioso!<br />
  Chiedi informazioni nei Punti Vendita Vodafone.<br />
  E se hai la Partita IVA, richiedi i dettagli sull&#8217;offerta iPhone Vodafone<br />
  Mio Business Tutto a te dedicata.</p>
</blockquote>
<p>Già, ma quali sono?</p>
<p>Le informazioni possono essere richieste tramite una form Web; quella che vi allego è per i contratti business:</p>
<p><img src="http://davidebenini.it/wp-content/uploads/2008/06/vodafone.png" alt="Vodafone.png" border="0" width="477" height="221" /></p>
<p>Attenzione al dettaglio:</p>
<p><img src="http://davidebenini.it/wp-content/uploads/2008/06/vodafone-1.png" alt="Vodafone-1.png" border="0" width="369" height="93" /></p>
<p>Hmmm.<br />
Ai contratti business è possibile associare solo iPhone da 16GB???<br />
Già, imprenditori e liberi professionisti hanno bisogno di più spazio per&#8230; vedere film e ascoltare musica?<br />
Secondo il principio del rasoio di Ockham, e chiedendoci &#8220;cui iuvat&#8221;, cerchiamo la spiegazione più semplice: dato che il 16GB venderà meno, Vodafone cerca di appiopparlo ai professionisti, non dando loro altra scelta. Inoltre mi viene da pensare che molti professionisti, a differenza del sottoscritto, abbiano il portafoglio facile; se non ferrati su iPhone, potrebbero non accorgersi nemmeno che viene offerto loro il modello più costoso.<br />
Che fuuuuuuurbi i manager di Vodafone, più astuti di Gargamella ed Ezechiele lupo messi insieme!<br />
Altra questione: a cosa serve questo form? A prenotare? La pagina non è chiara, a fronte di una richiesta di informazioni super dettagliate (addirittura il numero di partita IVA) non viene spiegato chiaramente a cosa serva il modulo. Io un&#8217;ideuzza ce l&#8217;ho. Questi moduli servono a fare un&#8217;indagine di mercato, per poi stabilire un prezzo adeguato per i contratti da associare ad iPhone.</p>
<p>E Tim?<br />
Tim sta a guardare, nel vero senso della parola. C&#8217;è un silenzio assordante che buona parte dei suoi utenti, ritiene colpevole.<sup>1</sup> Presumibilmente Tim attende la pubblicazione delle tariffe Vodafone per adeguarsi, o magari per fare un colpo di mano offrendo qualche forma di risparmio.</p>
<p>Considerazioni finali.</p>
<p>Il web è il regno delle informazioni. Vodafone nasconde informazioni importanti, deliberatamente. Se i prezzi non sono ancora stati stabiliti è sufficiente dirlo a chiare lettere. Il meccanismo del modulo da riempire ha il duplice obiettivo di fideizzare il cliente (che effettua già, a livello psicologico, parte dell&#8217;acquisto) e di instaurare una sorta di complicità: &#8220;queste informazioni sono troppo importanti, te le diciamo nell&#8217;orecchio&#8221;. Il fatto che agli utenti con partita IVA venga associato il 16GB in modo quantomeno subdolo è un altro grave peccato di comunicazione.</p>
<p>Su Internet non ci sono alibi per l&#8217;assenza di trasparenza.</p>
<h4>Notes</h4>
<ol class="footnotes">
<li id="footnote_0_76" class="footnote">Almeno nei forum Mac.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/06/12/prezzi-di-iphone-in-italia-un-mistero-deliberato/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The WWDC keynote was actually about OS X, did you notice?</title>
		<link>http://davidebenini.it/2008/06/10/the-wwdc-keynote-was-actually-about-os-x-did-you-notice/</link>
		<comments>http://davidebenini.it/2008/06/10/the-wwdc-keynote-was-actually-about-os-x-did-you-notice/#comments</comments>
		<pubDate>Tue, 10 Jun 2008 15:22:11 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[iPhone 3g OSX mac development mobile]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=73</guid>
		<description><![CDATA[The WWDC 2008 Keynote was, after all, about OS X. Most of the iPhone features and demos were dedicated to the iPhone OS X, the mobile flavour of (Mac) OS X. Will the mac people be disappointed?]]></description>
			<content:encoded><![CDATA[<p>Yesterday&#8217;s keynote has probably been the most predictable ever. All the rumours were dead-on, so accurate that I wonder whether Apple let the keynote program <em>slip</em> by accident.  </p>
<p>Despite the lack of properly called surprises, the keynote address stands out as a very singular one. All of the address, 1h 45m, have been dedicated to the iPhone: its sales, its new features, its SDK, its OS. Wait a minute, did I say OS?</p>
<p>The iPhone is powered by (Mac) Os X. The actual name of the OS is iPhone OS, a mobile version of Os X. The <a href="http://www.crunchgear.com/2008/06/05/os-x-leopardiphone-banners-appear-at-moscone/">banners at the Moscone center</a> contain only <em>OS X Leopard</em> and <em>OS X iPhone</em>. The removal of &#8220;Mac&#8221; might hurt the sensibility old aficionados, but it&#8217;s clearly meant at making the parallel obvious: this is the WWDC, we&#8217;re talking OS X in its two flavours, Leopard and iPhone. </p>
<p>The keynote demos were showing the OS X iPhone; this is quite understandable, for Leopard doesn&#8217;t need any publicity, nor has undergone substantial changes since its release. All the video-games and application demoed were directed to an audience of developers, as if telling them &#8220;hey folks, look at this, this is what you can do!&#8221;.</p>
<p>If you cannot accept the equation iPhone OS = OS X, take a look at what happened in the irc channels during the keynote, before the actual introduction of the hardware product: people were getting crazy, they wanted news about the 3g iPhone, not its OS. The discussion about the new physical model took only a small fraction of the whole presentation. I would say the keynote was atypical, but not, by any standards, off topic. </p>
<p>How will mac developers take this enthusiasm for the new kid on the block? I believe the reaction to Apple&#8217;s interest for mobile computing will be mixed. As Daniel Jalkut and Manton Reece pointed put in the first episode of their <a href="http://coreint.org/">Core Intuition</a> podcast, a number of people will be glad to join the app store bandwagon and make tons of money; other will miss the old mac-only Apple. But that&#8217;s life, any change is bound generate some grudges.</p>
<p>On a broader perspective, will Apple benefit from this news?<br />
Are you joking? I will quote <a href="http://daringfireball.net/2008/06/twice_as_fast">Gruber</a> on this:</p>
<blockquote>
<p>The physical phone is not the story. A year from now, the iPhone 3G will be replaced by another new model. The platform is the story. Platforms have staying power, and, once entrenched, are very hard to displace.</p>
</blockquote>
<p>Apple is quite entrenched, and means to stay.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/06/10/the-wwdc-keynote-was-actually-about-os-x-did-you-notice/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Apple and the corporate market</title>
		<link>http://davidebenini.it/2008/05/29/apple-and-the-corporate-market/</link>
		<comments>http://davidebenini.it/2008/05/29/apple-and-the-corporate-market/#comments</comments>
		<pubDate>Thu, 29 May 2008 07:24:34 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Aside]]></category>
		<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[corporate]]></category>
		<category><![CDATA[fun]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=67</guid>
		<description><![CDATA[Apple's attitude towards the corporate market.]]></description>
			<content:encoded><![CDATA[<p>Aaron Hillegass on Apple&#8217;s attitude towards the corporate world:</p>
<blockquote>
<p>Corporation: Hey, does Cocoa include something to help us write apps that talk to our Oracle database?</p>
<p>Apple: Um, nope. But isn&#8217;t GarageBand cool?</p>
<p>Corporation: Hmm.</p>
</blockquote>
<p>That&#8217;s what I call synthesis.</p>
<p>Via <a href="http://www.informit.com/articles/article.aspx?p=1220319">informIT</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/05/29/apple-and-the-corporate-market/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows 7 multi-touch (but you cannot make phone calls!)</title>
		<link>http://davidebenini.it/2008/05/28/windows-7-multi-touch-but-you-cannot-make-phone-calls/</link>
		<comments>http://davidebenini.it/2008/05/28/windows-7-multi-touch-but-you-cannot-make-phone-calls/#comments</comments>
		<pubDate>Wed, 28 May 2008 13:58:36 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[Add new tag]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=66</guid>
		<description><![CDATA[The new Microsoft OS will bring the multitouch to your desktop. But don't try to stuff it in your pocket or make calls! Believe it or not, it's not an iPhone!]]></description>
			<content:encoded><![CDATA[<p>In 18 months Windows 7 will do exactly what a iPhone can do today. Seeing is believing:</p>
<p>&nbsp;</p>
<p><embed src="http://images.video.msn.com/flash/soapbox1_1.swf" quality="high" width="432" height="364" base="http://images.video.msn.com" type="application/x-shockwave-flash" allowFullScreen="true" allowScriptAccess="always" pluginspage="http://macromedia.com/go/getflashplayer" flashvars="c=v&#038;v=8700c7ff-546f-4e1d-85f7-65659dd1f14f&#038;ifs=true&#038;fr=msnvideo&#038;mkt=en-US&#038;brand="></embed></p>
<p>&nbsp;</p>
<p>The originality of the Redmond folks never ceases to amaze me.</p>
<p>The good news is you won&#8217;t have to carry an iPhone with you to look at maps or pinch and rotate your favourite pics. Your monitor and desktop will do.</p>
<p>Via <a href="http://www.webmonkey.com/blog/Windows_7_Preview%3A_The_Wow_Starts_When_Again_" onclick="javascript:pageTracker._trackPageview ('/outbound/www.webmonkey.com');">WebMonkey</a>.</p>
<p>&nbsp;</p>
<p><strong>Addendum</strong>: apparently Wil Shipley also found this video funny, and linked to <a href="http://www.youtube.com/watch?v=CZrr7AZ9nCY" onclick="javascript:pageTracker._trackPageview ('/outbound/www.youtube.com');">this</a>. Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/05/28/windows-7-multi-touch-but-you-cannot-make-phone-calls/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Context free for decoration: a practical example</title>
		<link>http://davidebenini.it/2008/05/26/context-free-for-decoration-a-practical-example/</link>
		<comments>http://davidebenini.it/2008/05/26/context-free-for-decoration-a-practical-example/#comments</comments>
		<pubDate>Mon, 26 May 2008 18:37:31 +0000</pubDate>
		<dc:creator>Davide</dc:creator>
				<category><![CDATA[Technolalia]]></category>
		<category><![CDATA[Context Free]]></category>
		<category><![CDATA[decoration]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[webdesign]]></category>

		<guid isPermaLink="false">http://davidebenini.it/?p=65</guid>
		<description><![CDATA[In this brief tutorial I will explain the logic behind Context Free through a practical example, my Indian pattern.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.contextfreeart.org/">Context Free</a> is a multiplatform language that allows designer to produce these semi-randomized decorations and animations in a simple way.<sup>1</sup>This is my most successful attempt a Context Free image:</p>
<p><img src="http://davidebenini.it/wp-content/uploads/2008/05/indian-patterncfdg.jpg" alt="indian-pattern.cfdg.jpg" width="502" height="502" /></p>
<p>I&#8217;ve realised this image to decorate <a href="http://www.yogabenessere.it">yogabenessere.it</a>.</p>
<p>In this brief tutorial I will explain how my Indian pattern is composed by Context free.</p>
<p><span id="more-65"></span></p>
<p>First thing, download <a href="http://www.contextfreeart.org/mediawiki/index.php/Download_page">ContextFree</a>. It&#8217;s free, as in free beer, but you can donate some money if you like the product.<br />
Context Free  illustrations are generated by grammars. A grammar is a set of rules. Here is the grammar that generated my illustration:</p>
<pre><code>startshape CANVAS

rule CANVAS {
   8*{ rotate 135 x 33.5 y 10}GHIRIGORI{}
   GHIRIGORI{x 15 y 10}
}

rule GHIRIGORI {
   MULTISPIRAL{}
   MULTISPIRAL{rotate 180 y 4}
}
rule MULTISPIRAL {
   BRANCH_C { x 0 y 3 }
   BRANCH_A { x -0.5 y -2 s 0.23 rotate 210}
   CIRCLE { x -0.8 y -2 s 0.23}
   BRANCH_A {x  4 y 7.3 s 0.4 rotate -30 }
   BRANCH_C {x 4.3 y  8.5 s 0.25 rotate -10 }
   CIRCLE{x 4.24 y  9.1 s 0.25}
   BRANCH_A{ s 0.25 x 6.42 y 1.5 r 230}
   CIRCLE{s 0.25 x 6 y 1.5}

}
rule BRANCH_C {
    10* {y -0.2}CIRCLE{s 0.5}
    SPIRAL_C{}
}
rule BRANCH_A {
    10* {y -0.2}CIRCLE{s 0.5}
    SPIRAL_A{}
}
rule SPIRAL_C {
    CIRCLE { size 0.5 }
    SPIRAL_C { y 0.2
         rotate -3
         size 0.995 }
}
rule SPIRAL_A {
    CIRCLE { size 0.5 }
    SPIRAL_A { y 0.2
         rotate 3
         size 0.995 }
}
</code></pre>
<p>Scary, huh?<br />
Don&#8217;t run away yet! </p>
<p>Let&#8217;s start from the first and most important line:</p>
<pre><code>startshape CANVAS
</code></pre>
<p>This line tells the compiler: &#8220;The first (and only) things you must draw is a <code>CANVAS</code>. And what&#8217;s a <code>CANVAS</code>? Well, look at the following lines:</p>
<pre><code>rule CANVAS {
   8*{ rotate 135 x 33.5 y 10}GHIRIGORI{}
   GHIRIGORI{x 15 y 10}
}
</code></pre>
<p>This is the <code>CANVAS</code> shape definition.<sup>2</sup> Paraphrasing we could say:</p>
<p>To draw a <code>CANVAS</code>:<br />
* Draw 8 <code>GHIRIGORI</code>s; each one will be rotated 135 and shifted x33.5 and y 10<br />
* draw another <code>GHIRIGORI</code></p>
<p>This is what a <code>GHIRIGORI</code> looks like:</p>
<p><img src="http://davidebenini.it/wp-content/uploads/2008/05/ghirigori-1.jpg" alt="ghirigori-1.jpg" width="433" height="428" /></p>
<p>A <code>GHIRIGORI</code> is in turn made of two opposing <code>MULTISPIRAL</code>s, and so on. </p>
<p>The final shape definitions are the most important ones, for they&#8217;re one actually doing most of the drawing:<sup>3</sup></p>
<pre><code>rule SPIRAL_C {
    CIRCLE { size 0.5 }
    SPIRAL_C { y 0.2
         rotate -3
         size 0.995 }
}
rule SPIRAL_A {
    CIRCLE { size 0.5 }
    SPIRAL_A { y 0.2
         rotate 3
         size 0.995 }
}
</code></pre>
<p>They are <em>almost</em><sup>4</sup> the only rules containing a <a href="http://www.contextfreeart.org/mediawiki/index.php/Primitive_shapes">primitive shape</a>, in this case a circle. </p>
<pre><code>CIRCLE { size 0.5 }
</code></pre>
<p>This means: &#8220;draw a circle HALF the previous size&#8221;.</p>
<p>And where all the rest of the magic comes from?<br />
From most important feature of Context Free: <a href="http://en.wikipedia.org/wiki/Recursion">recursion</a>. The fanciest rules of context free are recursive, which means that the call themselves <em>ad infinitum</em>, or rather, as long as they produce visible results. So this is what happens</p>
<ul>
<li>Spiral draws a circle half the previous size</li>
<li>Spiral calls itself</li>
<li>Spiral draws a circle half the previous size</li>
<li>Spiral calls itself</li>
<li>etc etc&#8230;</li>
</ul>
<p>This goes on until the circle becomes a 1px circle. This is our spiral:</p>
<p><img src="http://davidebenini.it/wp-content/uploads/2008/05/spiral-1.jpg" alt="spiral-1.jpg" width="369" height="363" /></p>
<p>Now that we have got to the bottom we climb back to the top: circles form spirals, spirals form branches, branches form multispiral, multispirals form ghirighori, ghirigori form a canvas; the startshape directive calls our canvas, and this is it.</p>
<p>As you see the logic behind Context Free is simple but very powerful. </p>
<p>Context Free exports png and svg images, which can be imported into your editor of choice and greatly enhanced. You can also exports a movie of the image formation. Here&#8217;s a movie of my Indian Pattern, inaugurating my flickr pro account:</p>
<p>&nbsp;</p>
<p><object type="application/x-shockwave-flash" width="400" height="300" data="http://www.flickr.com/apps/video/stewart.swf?v=49235" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"><param name="flashvars" value="intl_lang=en-us&amp;photo_secret=dc5b6bf79a&amp;photo_id=2524481139"></param><param name="movie" value="http://www.flickr.com/apps/video/stewart.swf?v=49235"></param><param name="bgcolor" value="#000000"></param><param name="allowFullScreen" value="true"></param><embed type="application/x-shockwave-flash" src="http://www.flickr.com/apps/video/stewart.swf?v=49235" bgcolor="#000000" allowfullscreen="true" flashvars="intl_lang=en-us&amp;photo_secret=dc5b6bf79a&amp;photo_id=2524481139" height="300" width="400"></embed></object></p>
<p>&nbsp;</p>
<p>Take a look at the <a href="http://www.contextfreeart.org/gallery/">Context free image gallery</a> for a number of beautiful examples. My personal advice is to choose an example and start customising it to get  basic grasp of Context Free. And do not forget to take a look at the <a href="http://www.contextfreeart.org/mediawiki/index.php/CFDG_HOWTO">official documentation</a>. </p>
<p>Enjoy!<br />
Davide</p>
<h4>Notes</h4>
<ol class="footnotes">
<li id="footnote_0_65" class="footnote">It should be noted that, as Loris Zena pointed out, a <a href="http://en.wikipedia.org/wiki/Context-free_grammar">context free grammar</a> is a specific type of grammar.</li>
<li id="footnote_1_65" class="footnote">If you&#8217;re familiar with programming, you can think of shape definitions as functions.</li>
<li id="footnote_2_65" class="footnote">All of the drawing actually, with the exclusion of the small dots positioned at spirals intersections, drawn by <code>CIRCLE{s 0.25 x 6 y 1.5}</code>, defined in the <code>MULTISPIRAL</code> rule.</li>
<li id="footnote_3_65" class="footnote">See the previous note</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://davidebenini.it/2008/05/26/context-free-for-decoration-a-practical-example/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
