<?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>david winter &#187; apps</title>
	<atom:link href="http://davidwinter.me.uk/articles/tag/apps/feed/" rel="self" type="application/rss+xml" />
	<link>http://davidwinter.me.uk</link>
	<description>you were expecting someone else?</description>
	<lastBuildDate>Mon, 28 Jun 2010 20:37:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Graphviz&#8211;for drawing directed graphs</title>
		<link>http://davidwinter.me.uk/articles/2007/03/14/graphviz-for-drawing-directed-graphs/</link>
		<comments>http://davidwinter.me.uk/articles/2007/03/14/graphviz-for-drawing-directed-graphs/#comments</comments>
		<pubDate>Wed, 14 Mar 2007 20:11:56 +0000</pubDate>
		<dc:creator>David</dc:creator>
				<category><![CDATA[apps]]></category>
		<category><![CDATA[drawing]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[uni]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://davidwinter.me.uk/articles/2007/03/14/graphviz-for-drawing-directed-graphs/</guid>
		<description><![CDATA[This semester at University, I&#8217;m taking &#8216;Compiler Design &#38; Techniques&#8217; as a module. The second coursework involves drawing Finite State Machines diagrams that represent regular expressions. Rather than using a word processor to draw these diagrams with a rather untidy look about them, I went in search of a tool that&#8217;d help me produce high [...]]]></description>
			<content:encoded><![CDATA[<p>This semester at University, I&#8217;m taking &#8216;Compiler Design &amp; Techniques&#8217; as a module. The second coursework involves drawing <a href="http://en.wikipedia.org/wiki/Finite_state_machines">Finite State Machines</a> diagrams that represent regular expressions. Rather than using a word processor to draw these diagrams with a rather untidy look about them, I went in search of a tool that&#8217;d help me produce high quality drawings. I&#8217;d heard that Latex was good for mathematical diagrams, but that seemed like overkill as I only wanted the diagrams, not a whole new document syntax to learn.</p>

<p><span id="more-61"></span></p>

<p>I come across <a href="http://www.graphviz.org/">Graphviz</a>. Open source and available on near enough all platforms&#8211;<a href="http://www.ryandesign.com/graphviz/">Mac</a>, <a href="http://www.graphviz.org/Download_linux.php">Linux</a> and <a href="http://www.graphviz.org/Download_windows.php">Windows</a>. Using a very simple syntax, you create <code>dot</code> files and then using the <code>dot</code> tool, you can generate PNG images of your diagrams.</p>

<p>Here is an example <code>dot</code> script:</p>

<pre><code>digraph my_fsm {
    label = "ab*(cd)+|b";
    rankdir = LR;
    node [shape = doublecircle]; 3 4;
    node [shape = circle];
    0 -&gt; 1 [label = "a"];
    1 -&gt; 1 [label = "b"];
    1 -&gt; 2 [label = "c"];
    2 -&gt; 3 [label = "d"];
    3 -&gt; 2 [label = "c"];
    0 -&gt; 4 [label = "b"];
}
</code></pre>

<p>Following is an explanation of the above script:</p>

<ol>
<li>I&#8217;m declaring the graph as a directed graph with <code>digraph</code>.</li>
<li><code>my_fsm</code> is just the name I&#8217;ve given the graph. This can be anything.</li>
<li>I add a label to the graph which holds the regular expression that I&#8217;m drawing. This isn&#8217;t required, but just helps by giving it a title.</li>
<li><code>rankdir</code> specifies the direction of the diagram. I&#8217;m specifying &#8216;left to right&#8217; with <code>LR</code>.</li>
<li>So that I can differentiate between accepting states and normal states, I&#8217;m declaring that nodes 3 and 4 will have a double circle around them.</li>
<li>For all other nodes, I just want to use the normal <code>circle</code> shape.</li>
<li>Lastly, I declare the nodes and their edges. Also, I add a label to each edge.</li>
</ol>

<p>Once you save the file, you can run it through the <code>dot</code> program using the following command:</p>

<pre><code>dot my_file.dot -Tpng -o my_fsm.png
</code></pre>

<p>You&#8217;ll need to check where <code>dot</code> was installed. With the Mac installer package it is installed to <code>/usr/local/graphviz-2.12/bin/dot</code>, so you&#8217;ll need to modify the above command to reflect the correct location.</p>

<p>The outputted file, <code>my_fsm.png</code> in this example, should result in something that looks like the one below.</p>

<p><img src="http://davidwinter.me.uk/wp-content/uploads/2007/03/my_fsm.png" alt="Finite State Machine Example" /></p>

<p>A very handy tool indeed. There is a <a href="http://www.graphviz.org/Documentation/dotguide.pdf">PDF guide</a> on all the commands available. Of which, I&#8217;m next going to look for how to space the graph out a bit more as it&#8217;s a little squashed at the moment.</p>

<p>Hope this helps.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidwinter.me.uk/articles/2007/03/14/graphviz-for-drawing-directed-graphs/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Mac &#8220;Hot Corners&#8221; for Ubuntu</title>
		<link>http://davidwinter.me.uk/articles/2006/12/29/mac-hot-corners-for-ubuntu/</link>
		<comments>http://davidwinter.me.uk/articles/2006/12/29/mac-hot-corners-for-ubuntu/#comments</comments>
		<pubDate>Fri, 29 Dec 2006 19:56:44 +0000</pubDate>
		<dc:creator>David</dc:creator>
				<category><![CDATA[apps]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://davidwinter.me.uk/articles/2006/12/29/mac-hot-corners-for-ubuntu/</guid>
		<description><![CDATA[I&#8217;ve had a bit more time recently to play around with Ubuntu and am finding the &#8216;Ubuntu versions&#8217; of apps that I&#8217;ve grown to love on Mac OS X. One of which being Hot Corners which I always use to lock my screen when moving away from it. Brightside is the Ubuntu app to do [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve had a bit more time recently to play around with Ubuntu and am finding the &#8216;Ubuntu versions&#8217; of apps that I&#8217;ve grown to love on Mac OS X. One of which being Hot Corners which I always use to lock my screen when moving away from it.</p>

<p><a href="http://packages.ubuntulinux.org/dapper/gnome/brightside">Brightside</a> is the Ubuntu app to do the job.</p>

<pre><code>sudo apt-get install brightside
</code></pre>

<p>Once installed, go to System, Preferences, Screen Actions. I then checked the &#8220;Bottom right corner&#8221; and then chose &#8220;Start screensaver&#8221;. Works a charm.</p>

<p>Be sure that in your Screensaver settings to check the &#8220;Lock screen when screensaver is active&#8221; option.</p>
]]></content:encoded>
			<wfw:commentRss>http://davidwinter.me.uk/articles/2006/12/29/mac-hot-corners-for-ubuntu/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>CSSEdit 2 Released</title>
		<link>http://davidwinter.me.uk/articles/2006/11/07/cssedit-2-released/</link>
		<comments>http://davidwinter.me.uk/articles/2006/11/07/cssedit-2-released/#comments</comments>
		<pubDate>Tue, 07 Nov 2006 21:30:24 +0000</pubDate>
		<dc:creator>David</dc:creator>
				<category><![CDATA[apps]]></category>
		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://davidwinter.me.uk/articles/2006/11/07/cssedit-2-released/</guid>
		<description><![CDATA[I was very lucky to be able to help out in beta testing CSSEdit 2. I&#8217;d be totally lost without this app as I&#8217;m constantly using it for all my web design projects. It helped build the designs for this blog and countless others, as well as my James Bond site, CommanderBond.net. It really speeds [...]]]></description>
			<content:encoded><![CDATA[<p>I was very lucky to be able to help out in beta testing <a href="http://macrabbit.com/cssedit/">CSSEdit 2</a>. I&#8217;d be totally lost without this app as I&#8217;m constantly using it for all my web design projects.</p>

<p>It helped build the designs for this blog and countless others, as well as my <a href="http://commanderbond.net">James Bond site, CommanderBond.net</a>.</p>

<p>It really speeds up development for me compared to writing the CSS rules out.</p>

<p>Congratulations to Jan for a great release!</p>
]]></content:encoded>
			<wfw:commentRss>http://davidwinter.me.uk/articles/2006/11/07/cssedit-2-released/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
