<?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>Borgar.net</title>
	<atom:link href="http://borgar.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://borgar.net</link>
	<description>All the wisdom of the rainbow.</description>
	<lastBuildDate>Thu, 05 Nov 2009 12:27:39 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=3.0-alpha</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>CSS :target</title>
		<link>http://borgar.net/s/2009/08/css-target/</link>
		<comments>http://borgar.net/s/2009/08/css-target/#comments</comments>
		<pubDate>Wed, 05 Aug 2009 23:24:23 +0000</pubDate>
		<dc:creator>Borgar</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://borgar.net/?p=1455</guid>
		<description><![CDATA[jQuery (or Sizzle) supports :target in browsers where it runs querySelectorAll to handle the work. In older browsers, it doesn&#8217;t offer fallback support. I guess that this is simply because :target is such an uncommon selector?
I have no idea why you would want to use it, but because I have this selector extension and nowhere [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://docs.jquery.com/Selectors">jQuery</a> (or <a href="http://sizzlejs.com/">Sizzle</a>) supports <code>:target</code> in browsers where it runs <a href="http://www.w3.org/TR/selectors-api/">querySelectorAll</a> to handle the work. In older browsers, it doesn&#8217;t offer fallback support. I guess that this is simply because <code>:target</code> is such an uncommon selector?</p>
<p>I have no idea why you would want to use it, but because I have this selector extension and nowhere to put it, here it is:</p>
<pre><code>jQuery.expr[':'].target = function ( a, h ) {
  return (a.id &#038;&#038; (h = document.location.hash) &#038;&#038; h === '#' + a.id)
};</pre>
<p></code></p>
<p>Updated 6. aug. 2009: <a href="http://twitter.com/maranomynet/status/3156396467">Optimized by @maranomynet</a></p>]]></content:encoded>
			<wfw:commentRss>http://borgar.net/s/2009/08/css-target/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Sōkoban</title>
		<link>http://borgar.net/s/2009/07/sokoban/</link>
		<comments>http://borgar.net/s/2009/07/sokoban/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 22:57:14 +0000</pubDate>
		<dc:creator>Borgar</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[game]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[release]]></category>

		<guid isPermaLink="false">http://borgar.net/?p=1427</guid>
		<description><![CDATA[A few days without internet do strange things to a computer addict. In my case I start to rummage frenetically though old projects to see if there is anything I can finish, polish, or do something with that doesn&#8217;t require internet access.

So I found my old Sokoban game. Originally a Windows application, I though it [...]]]></description>
			<content:encoded><![CDATA[<p>A few days without internet do strange things to a computer addict. In my case I start to rummage frenetically though old projects to see if there is anything I can finish, polish, or do something with that doesn&#8217;t require internet access.</p>
<p><img title="Sokoban for windows" src="http://borgar.net/wp-content/uploads/sokoban.png" alt="sokoban" align="right" width="210" height="178" /></p>
<p>So I found my old Sokoban game. Originally a Windows application, I though it could be fun to try to remake it in JavaScript. <a title="Sokoban in jQuery" href="http://borgar.net/programs/sokoban/">So that&#8217;s what I did.</a></p>
<p>I wrote the bulk of it in about an evening, and spent a few more evenings applying spit and polish until I was satisfied that it worked the way I wanted. The <a href="http://borgar.net/programs/sokoban/js/sokoban.js">whole thing</a> is about  300 lines of mostly uncommented code running on top of jQuery &mdash; well, actually as a jQuery plugin.</p>
<h3>The interresting bits</h3>
<p>There are a few characteristics that make this implementation interesting. The first is that the game uses progressive enhancement methodology. The script runs through marked items on the webpage and makes valid Sokoban levels playable. If you don&#8217;t have JavaScript you can still read the level codes, which are normally written in a standard like this:</p>
<pre>####
# .#
#  ###
#*@  #
#  $ #
#  ###
####</pre>
<p>The <code>@</code> is the worker, <code>#</code> are walls, <code>.</code> are docks, <code>$</code> are boxes, and so on&#8230; </p>
<p>The symbols are image-replaced with <acronym title="Cascading Style Sheets">CSS</acronym> when the level is live, but the whole thing works without <acronym title="Cascading Style Sheets">CSS</acronym>. You can disable the styles if you desire to play the levels in pure ASCII.</p>
<p>This also means that the game is printable. At any moment in gameplay you can grab a hardcopy of your status and frame it. I am hard pressed to think of other printable games. Copying the level onto the clipboard also works just as it would any other text. Not really useful features for a game, but interesting side-effects nonetheless.</p>
<p>Because parsing all the levels immediately as the game loads up &mdash; especially on level collections that have very many levels &mdash; is quite labour intensive, I am applying a recent jQuery plugin of mine, <a href="http://borgar.net/svn/public/trunk/javascript/jquery.processEach/jquery.processEach.js">.processEach()</a>, to prevent the browser from locking up. In short, it works like <em>.each()</em> but yields the process every iteration to allow the browser some time to do other things. It&#8217;s perhaps a subject of another entry.</p>
<h3>Have fun</h3>
<p>Have fun with <a href="http://borgar.net/programs/sokoban/">the game</a> and the source (which are released under the <acronym title="GNU General Public License">GPL</acronym> v3). I suspect that it might one day be exactly what a Sokoban level blog is looking for, but for now it mostly remains a curiosity rather than a spectacular reproduction of the game, </p>]]></content:encoded>
			<wfw:commentRss>http://borgar.net/s/2009/07/sokoban/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Gecko &amp; Webkit</title>
		<link>http://borgar.net/s/2009/07/gecko-and-webkit/</link>
		<comments>http://borgar.net/s/2009/07/gecko-and-webkit/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 15:46:22 +0000</pubDate>
		<dc:creator>Borgar</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[history]]></category>
		<category><![CDATA[internet]]></category>

		<guid isPermaLink="false">http://borgar.net/?p=1404</guid>
		<description><![CDATA[I stumbled over Zeldman&#8217;s opening statement:
When Apple chose Webkit rather than Mozilla Gecko as the basis for its Safari browser, some of us in the web standards community scratched our heads. Sure, Webkit was open-source and standards-compliant.
Really? People were puzzled by this? This always seemed the obvious choice to me. 
First of all, Apple didn&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>I stumbled over <a href="http://www.zeldman.com/2009/07/12/web-standards-secret-sauce-webkit-in-iphone/">Zeldman&#8217;s opening statement</a>:</p>
<blockquote><p>When Apple chose Webkit rather than Mozilla Gecko as the basis for its Safari browser, some of us in the web standards community scratched our heads. Sure, Webkit was open-source and standards-compliant.</p></blockquote>
<p>Really? People were puzzled by this? This always seemed the obvious choice to me. </p>
<p>First of all, Apple didn&#8217;t choose WebKit, they chose KHTML to become WebKit. And while Firefox may have been more mature as a browser, the Gecko engine was not mature in ways that mean &#8220;sophisticated&#8221;.</p>
<p>At the time (7-8 years ago today) the Gecko codebase was a notorious mess and the rewrite work only so far along the way. It was such as mess that it was a running joke on Slashdot and cited as a perfect example of the code equivalent of spaghetti. Gecko still needed a completely new text layout handler to do things like &#8216;<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=9458">inline-block display</a>&#8216; and &#8216;<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=9101">hyphenation</a>&#8216;. </p>
<p>Additionally, the Mozilla developers&#8217; <q>&#8220;if you want this feature so much then you are welcome to implement it yourself&#8221;</q> vitriol towards web developers wasn&#8217;t much better than the apathy Microsoft had. And while it was certainly technically right, it was neither reasonable nor to their credit. But that may not have been so much a factor for Apple.</p>
<p>KHTML, on the other hand, was in heavy development with a much fresher codebase and had nice things that only <acronym title="Internet Explorer">IE</acronym> supported, like right-to-left language text. Things that are important to corporations that intend to sell computers to the millions of non-english speakers of the world.</p>
<p>From a purely technical point of view KHTML was a much better choice. Dave Hyatt, who probably had a large say in the selecting KHTML to become WebKit, knew this all to well having worked with, and written some of, the mess Gecko was at the time. </p>
<p>Time passes and we may not remember all of this so clearly or, as things change, these things cease to matter. I am a bit surprised to hear that web developers, even heavy weights like Zeldman, were unaware of the state of the browsers they worked on. Are they still?</p>]]></content:encoded>
			<wfw:commentRss>http://borgar.net/s/2009/07/gecko-and-webkit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Islenska.org opin almenningi</title>
		<link>http://borgar.net/s/2008/11/opin-ordabok/</link>
		<comments>http://borgar.net/s/2008/11/opin-ordabok/#comments</comments>
		<pubDate>Sun, 16 Nov 2008 22:17:39 +0000</pubDate>
		<dc:creator>Borgar</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[icelandic]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[open content]]></category>
		<category><![CDATA[opin ordabok]]></category>

		<guid isPermaLink="false">http://borgar.undraland.com/?p=1045</guid>
		<description><![CDATA[Á þessum annars ágæta sunnudegi íslenskrar tungu hef ég opnað fyrir notkun á nýrri rímorðabók, orðskiptu, og niðurhali á frumstæðri orðskiptilýsingu sem ég hef haft í smíðum um nokkurt skeið.
Þetta er allt að finna á slóðinni islenska.org, en það er lén sem hefur staðið autt í nokkur ár, eða síðan að ég fékk þá hugmynd [...]]]></description>
			<content:encoded><![CDATA[<p>Á þessum annars ágæta <a href="http://www.menntamalaraduneyti.is/malaflokkar/Menning/dit">sunnudegi íslenskrar tungu</a> hef ég opnað fyrir notkun á nýrri rímorðabók, orðskiptu, og niðurhali á frumstæðri orðskiptilýsingu sem ég hef haft í smíðum um nokkurt skeið.</p>
<p>Þetta er allt að finna á slóðinni <a href="http://islenska.org/">islenska.org</a>, en það er lén sem hefur staðið autt í nokkur ár, eða síðan að ég fékk þá hugmynd að ég gæti framleitt stafræna orðabók.</p>
<p>Hugmyndin er að fleiri tól og virkni færist þarna inn með tímanum. Næstu verkefni verða að auka sjálfvirkni á ýmsum hlutum þarna, ss. útgáfu á gagnagrunninum sem á bakvið þetta liggur (þeas. orðabókinni sjálfri). Mig langar t.d. til þess að varpa orðabókinni yfir í stafsetningarorðabækur fyrir <acronym title="Macintosh Operating System 10">OS X</acronym>, Ispell, Aspell, og Firefox.</p>
<p>Mér fannst þó vera kominn tími til þess að opna fyrir eitthvað af þessu, enda er enginn ávinningur fólginn í því að þetta liggi dögum saman óhreift á einkatölvunni minni.</p>
<p>Verði ykkur að góðu.</p>]]></content:encoded>
			<wfw:commentRss>http://borgar.net/s/2008/11/opin-ordabok/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Opin gögn og endurnýtanleg</title>
		<link>http://borgar.net/s/2008/09/opin-gogn-og-endurnytanleg/</link>
		<comments>http://borgar.net/s/2008/09/opin-gogn-og-endurnytanleg/#comments</comments>
		<pubDate>Thu, 04 Sep 2008 19:48:40 +0000</pubDate>
		<dc:creator>Borgar</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[open content]]></category>
		<category><![CDATA[politics]]></category>

		<guid isPermaLink="false">http://borgar.undraland.com/?p=1031</guid>
		<description><![CDATA[Við félagarnir tókum okkur til og opnuðum vef, opingogn.net, til þess að reyna að gera upplýsingar um opin gögn á Íslandi aðgengileg miðlægt. Hver sem er má bæta sinni vitneskju inn, og eitthvað er þegar farið að tínast inn.
Það leið ekki langur tími þangað til að ég fékk ábendingu í pósti um áhugaverða klausu í [...]]]></description>
			<content:encoded><![CDATA[<p>Við <a href="http://mar.anomy.net">félagarnir</a> tókum okkur til og <a href="http://hjalli.com/2008/09/01/opin-gogn-nytt-vefsvæði/">opnuðum vef,</a> <a href="http://opingogn.net/">opingogn.net</a>, til þess að reyna að gera upplýsingar um opin gögn á Íslandi aðgengileg miðlægt. Hver sem er má bæta sinni vitneskju inn, og eitthvað er þegar farið að tínast inn.</p>
<p>Það leið ekki langur tími þangað til að ég fékk ábendingu í pósti um áhugaverða klausu í landslögum:</p>
<blockquote><p>Stjórnvöld skulu birta á heimasíðu sinni lista yfir þær skrár sem hafa að geyma upplýsingar í þeirra vörslum sem heimilt er að endurnota, svo og þau skilyrði sem slík endurnot eru bundin.<br />
<cite><a href="http://www.althingi.is/lagasofn/135a/1996050.html#G27M2">Upplýsingalög, 1996 nr. 50 24. maí</a></cite>
</p></blockquote>
<p>Þetta er úr <a href="http://www.althingi.is/altext/stjt/2006.161.html">lögum um breytingu á upplýsingalögum, nr. 50/1996</a> sem tóku gildi 1. janúar 2007. Eitthvað er þessu ennþá ábótavant, eins og við er að búast. Það er rétt að benda á að stjórnvöldum er sjálfsagt að endurnýta þær upplýsingar sem safnast á opingögn.net, þær eru jú opnar.</p>
<p>Það er mikilvægt að gera sér grein fyrir því að þótt heimilt sé <acronym title="samkvæmt">skv.</acronym> upplýsingalögum að endurnýta tiltekin gögn, þá er ekki þar með sagt að það sé hægt. Fyrst þarf jú að komast í gögnin. Þeir þættir upplýsingarlaga sem opna fyrir endurnýtingu gagna stofnanna sem ekki fá undanþágu frá þeim, gefa þó engan rétt til aðgengi að þeim.</p>
<p>Glöggt dæmi um þetta er að finna í úrskurði Úrskurðarnefndar um upplýsingamál frá <a href="http://ursk.forsaetisraduneyti.is/urskurdir/nr/2834">21. desember 2007</a>:</p>
<blockquote><p>Í 1. mgr. 24. gr. laganna segir að markmið kaflans sé að auka endurnot opinberra upplýsinga til hagsbóta fyrir samfélagið í heild. Samkvæmt 3. mgr. 24. gr. hefur umræddur kafli þó ekki bein áhrif á rétt til aðgangs að gögnum samkvæmt upplýsingalögum. Þar segir að ákvæði kaflans gildi einvörðungu um endurnot fyrirliggjandi upplýsinga sem séu í vörslum stjórnvalda og almenningur eigi rétt til aðgangs að á grundvelli 3. gr. laganna eða annarra ákvæða sem veita almenningi slíkan rétt. Í skýringum við þessa málsgrein í frumvarpi því sem varð að lögum nr. 161/2006 er áréttað að ákvæði kaflans gildi <q>&#8220;einungis um endurnot upplýsinganna en mæli ekki á neinn hátt fyrir um rétt til aðgangs að opinberum upplýsingum.&#8221;</q>
</p></blockquote>
<p>Þetta þarf að laga. Það þarf að fjarlægja þessar undanþágur skóla, bóka- og skjalasafna, rannsóknastofnanna, ríkisútvarpsins, menningarstofnanna; Það þarf að fjarlægja ákvöður um upprunatilgreiningar og ábyrgðaryfirlýsingar; Það þarf að takmarka leyfi til gjaldtöku við einhver sértilfelli (ef einhver eru); Og það þarf að afnema ákvæði um vernd og gjaldtöku þeirra stofnanna sem rekin eru samkvæmt sérlögum.</p>
<p>Þannig breytum við þessari vannýttu skúffuauðlind í hagvöxt og kreppumeðal. Ég hvet lesendur sem þekkja ekki málið að <a href="http://opendefinition.org/">lesa sér til</a>, og kynna sér <a href="http://hjalli.com/2008/08/28/the-case-for-open-access-to-public-sector-data/">málstaðinn</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://borgar.net/s/2008/09/opin-gogn-og-endurnytanleg/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.724 seconds -->
<!-- Cached page generated by WP-Super-Cache on 2010-03-12 13:04:50 -->
<!-- Compression = gzip -->