<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-US"><title type="html">Ralph Sommerer's Budget Wisdom</title><subtitle type="html">Cheap rants on technology nobody ever asked for - nor anyone really cares to read</subtitle><id>http://blogs.msdn.com/sompost/atom.xml</id><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/default.aspx" /><link rel="self" type="application/atom+xml" href="http://blogs.msdn.com/sompost/atom.xml" /><generator uri="http://communityserver.org" version="2.1.61025.2">Community Server</generator><updated>2005-09-30T00:24:00Z</updated><entry><title>Tales of Mystery and Evaluation</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2009/10/26/tales-of-mystery-and-evaluation.aspx" /><id>http://blogs.msdn.com/sompost/archive/2009/10/26/tales-of-mystery-and-evaluation.aspx</id><published>2009-10-26T10:05:00Z</published><updated>2009-10-26T10:05:00Z</updated><content type="html">Updated below For reasons that I don't want to talk about right now I've read the JavaScript specification (ECMA-262, 3rd edition) when I stumbled upon a small mystery. It'd be more of a challenge than a mystery if the major Web browsers and their JavaScript engines didn't totally disagree on what is the correct answer. Here's the problem. If you want to compile JavaScript to native code (see one of my earlier blog posts on why you would want to do this) you need at one point to decide where to put...(&lt;a href="http://blogs.msdn.com/sompost/archive/2009/10/26/tales-of-mystery-and-evaluation.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9912887" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="Google Chrome" scheme="http://blogs.msdn.com/sompost/archive/tags/Google+Chrome/default.aspx" /><category term="Firefox" scheme="http://blogs.msdn.com/sompost/archive/tags/Firefox/default.aspx" /></entry><entry><title>On JavaScript performance in IE8</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2008/09/26/javascript-performance-in-ie8.aspx" /><id>http://blogs.msdn.com/sompost/archive/2008/09/26/javascript-performance-in-ie8.aspx</id><published>2008-09-26T11:41:00Z</published><updated>2008-09-26T11:41:00Z</updated><content type="html">Although I'm not technically a Microsoft employee anymore (I left Microsoft Research, Cambridge, at the end of 2006), I still consider myself friendly with Microsoft and have, for various reasons (including stock), a certain residual interest in the well-being of the company. Also, to be honest, while I didn't regret leaving Microsoft Research all too much (it wasn't quite the MSR I joined in 1998), I liked being with Microsoft, and would, if the circumstances were right, return without too much...(&lt;a href="http://blogs.msdn.com/sompost/archive/2008/09/26/javascript-performance-in-ie8.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=8940325" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="Google Chrome" scheme="http://blogs.msdn.com/sompost/archive/tags/Google+Chrome/default.aspx" /><category term="Firefox" scheme="http://blogs.msdn.com/sompost/archive/tags/Firefox/default.aspx" /></entry><entry><title>Target JavaScript: GWT, Script# and Oberon Script</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2006/06/02/614230.aspx" /><id>http://blogs.msdn.com/sompost/archive/2006/06/02/614230.aspx</id><published>2006-06-02T16:47:00Z</published><updated>2006-06-02T16:47:00Z</updated><content type="html">The paper on Oberon Script that I submitted to the Joint Modular Languages Conference ( JMLC 2006 ), and that I wrote about in my last post was accepted. Thank you! In the mean time, two toolkits were announced to the public that allow developing AJAX-style Web Client Applications (WCAs) in a high-level language which is then compiled to JavaScript as a high-level object code. The two are Google's Web Toolkit ( GWT ), based on Java , and ASP.NET architect Nikhil Kothari's Script# , based on C# (snappy...(&lt;a href="http://blogs.msdn.com/sompost/archive/2006/06/02/614230.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=614230" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="Web Development" scheme="http://blogs.msdn.com/sompost/archive/tags/Web+Development/default.aspx" /><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="AJAX" scheme="http://blogs.msdn.com/sompost/archive/tags/AJAX/default.aspx" /></entry><entry><title>JavaScript = Portable Object Code</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2006/04/24/582197.aspx" /><id>http://blogs.msdn.com/sompost/archive/2006/04/24/582197.aspx</id><published>2006-04-24T17:26:00Z</published><updated>2006-04-24T17:26:00Z</updated><content type="html">A few days ago I submitted a short paper to a small conference on modular programming languages and systems describing a small experiment that I did in my series of "Cool Things You Can Do With JavaScript". I was just about leaving my office before heading to .ch , and before finally closing my Web browser and locking my PC I entered the name of said conference into Google. Perhaps I shouldn't say that. I should be using MSN Search, but unfortunately "goo" + autocomplete is just too convenient. Maybe...(&lt;a href="http://blogs.msdn.com/sompost/archive/2006/04/24/582197.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=582197" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="AJAX" scheme="http://blogs.msdn.com/sompost/archive/tags/AJAX/default.aspx" /></entry><entry><title>Google innovates</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2006/04/11/573511.aspx" /><id>http://blogs.msdn.com/sompost/archive/2006/04/11/573511.aspx</id><published>2006-04-11T20:06:00Z</published><updated>2006-04-11T20:06:00Z</updated><content type="html">Google have just released ExplorerCanvas , an innovative way of bringing the canvas tag familiar from Firefox, Safari and Opera 9 to Internet Explorer that doesn't natively support it. Apparently, all you have to do is add a script tag into Web pages that use the tag. Now, who on earth would've ever thought of that! I'm certain that at this very moment computing history is being written! Or re-, rather....(&lt;a href="http://blogs.msdn.com/sompost/archive/2006/04/11/573511.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=573511" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author></entry><entry><title>IE Can what? Canvas Element for Internet Explorer</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2006/02/22/536967.aspx" /><id>http://blogs.msdn.com/sompost/archive/2006/02/22/536967.aspx</id><published>2006-02-22T18:14:00Z</published><updated>2006-02-22T18:14:00Z</updated><content type="html">&lt;p&gt;I've just finished a simple implementation of a &lt;a href="http://developer.mozilla.org/en/docs/Drawing_Graphics_with_Canvas"&gt;&lt;font color="#000080" face="Courier New" size="2"&gt;canvas&lt;/font&gt; element&lt;/a&gt; for Microsoft Internet Explorer using &lt;a href="http://www.w3.org/TR/1998/NOTE-VML-19980513"&gt;VML&lt;/a&gt;. I needed a way to do simple line graphics for a project I'm working on, and that I want to run in both IE and Firefox. While I could have used either Java or Flash to do line graphics, now that we’re in Web 2.0 (or &lt;a href="http://labs.live.com/manifesto.aspx"&gt;World 2.0&lt;/a&gt;, rather) and &lt;a href="http://en.wikipedia.org/wiki/AJAX"&gt;Ajax&lt;/a&gt; is the word, both seem a bit ... obsolete.&lt;/p&gt;
&lt;p&gt;Here's a &lt;a target="_blank" href="http://research.microsoft.com/users/som/blog/canvas-test.htm"&gt;demo page&lt;/a&gt; showing what works and what doesn't. As I’ve implemented what I need and very little more, there's more of the latter than the former. Still, most of the basic stuff works:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Outlining and filling of paths work fine. Clipping is not supported. Quadratic curves are implemented but VML does not draw them unless they are closed. There’s a lot that VML doesn’t do right.&lt;/li&gt;
&lt;li&gt;VML does not support gradients the way they are defined by the canvas feature. I have spent only very little time trying to simulate them, and have mostly failed. It does &lt;em&gt;something&lt;/em&gt;, but wrong. Patterns work better, but only a little.&lt;/li&gt;
&lt;li&gt;Transformations work for line figures but not for patterns and images. Arcs degrade if you rotate and scale them but you may not always notice (work-around because VML is rubbish).&lt;/li&gt;
&lt;li&gt;Image drawing works if the source is an image. I have contemplated doing canvas sources but then didn't do them because I don't need them. That's not to say that they're difficult (*), they're just unnecessary (to me, for now).&lt;br&gt;&lt;font size="1"&gt;(*) You can copy the children of the source canvas into a &lt;font color="#000080" face="Courier New"&gt;div&lt;/font&gt; and insert that into the destination canvas.&lt;/font&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;To use it, you only need to add a call to the global &lt;font color="#000080" face="Courier New" size="2"&gt;__initCanvas()&lt;/font&gt; function in the document's &lt;font color="#000080" face="Courier New" size="2"&gt;onload&lt;/font&gt; event handler, preferably before you use any of the canvas functions. It'll do no harm in Firefox, but in IE, it will replace all &lt;font color="#000080" face="Courier New" size="2"&gt;canvas&lt;/font&gt; elements in the document by &lt;font color="#000080" face="Courier New" size="2"&gt;div&lt;/font&gt; elements with the same id and size (and all other attributes). You can then request a drawing context using &lt;font color="#000080" face="Courier New" size="2"&gt;getContext&lt;/font&gt; the same way you would in Firefox.&lt;/p&gt;
&lt;p&gt;Implementing the &lt;font color="#000080" face="Courier New" size="2"&gt;canvas&lt;/font&gt; element using VML poses a few problems (in addition to those that VML poses on its own). A canvas is a &lt;em&gt;pixelmap&lt;/em&gt;. A VML figure, however, is a &lt;em&gt;data structure&lt;/em&gt;. As long as you’re doing "shapes" you're fine, but if you start doing "pixels" - and lots of them - you get yourself into trouble quite rapidly. On a pixelmap you can keep painting the same spot over and over, and it'll still be "one pixel deep", if you know what I mean. On a VML figure, however, you just pile shapes on top of each other until IE explodes (Literally! Believe me, I've done it). Because of VMLs anti-aliasing feature IE needs to inspect &lt;em&gt;all&lt;/em&gt; shapes underneath the last shape added to compute its proper color -- even if you don't use transparency. That's o(n&lt;sup&gt;2&lt;/sup&gt;) if there ever was. You could, of course, optimise the figure by deleting all shapes that are completely obscured by a newly added non-transparent shape. I didn't do it, though. Only the &lt;font color="#000080" face="Courier New" size="2"&gt;clearRect&lt;/font&gt; function of my canvas implementation clears the figure by deleting shapes, but only if the full canvas is cleared (otherwise, more stuff is actually added). If you're doing animations you may want to clear the full canvas sooner rather than later.&lt;/p&gt;
&lt;p&gt;A final note: I'm aware that whatever you do, someone on the vast expanses of the Internet will have done it already, so don't bother telling me. There are reasons why I don't (indeed, mustn't) even look too closely at stuff lying about on the Internet. To comfort anyone's hurt feelings (or rub salt in their wounds, whichever): It &lt;em&gt;is&lt;/em&gt; a pretty obvious idea, once you inspect the canvas feature and also happen to know VML.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=536967" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="Web Development" scheme="http://blogs.msdn.com/sompost/archive/tags/Web+Development/default.aspx" /><category term="MSN Experience" scheme="http://blogs.msdn.com/sompost/archive/tags/MSN+Experience/default.aspx" /><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="AJAX" scheme="http://blogs.msdn.com/sompost/archive/tags/AJAX/default.aspx" /></entry><entry><title>I've switched to Linux, and it's never been so easy!</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2005/10/30/487006.aspx" /><id>http://blogs.msdn.com/sompost/archive/2005/10/30/487006.aspx</id><published>2005-10-30T18:57:00Z</published><updated>2005-10-30T18:57:00Z</updated><content type="html">&lt;P&gt;&lt;IMG title="Linux Detergent" src="http://research.microsoft.com/users/som/blog/linux.jpg" align=right&gt;I've had enough! This weekend, I've finally made the switch, and I'm now one of the many thousands of satisfied Linux users. I know I shouldn't say this so frankly -- and I won't apologize for this -- but the other crap can stay on the shelves for good! My only regret is not having switched sooner! Right now, my machine is doing its cycles with Linux, and it's never been so easy and less troublesome in my life. No more sitting in sweaty shirts trying to figure things out! Mine will be fresh and clean with Linux! I'm doing all my &lt;A href="http://www.roesch-swiss.ch/?id=1159&amp;amp;cat_id=19"&gt;laundry&lt;/A&gt; with it!&lt;/P&gt;
&lt;P&gt;&lt;SMALL&gt;Some people with a major software company got slightly irritated about this post. For their benefit and everybody else's who needs it rubbed into his/her face here comes a ...&lt;/SMALL&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=monospace size=1&gt;DISCLAIMER: THIS IS A JOKE! EACH AND EVERY INSTANCE OF THE TERM "LINUX" MENTIONED IN THIS POST REFERS TO A LAUNDRY DETERGENT ("VOLLWASCHMITTEL") MANUFACTURED BY RÖSCH COMPANY IN SWITZERLAND. ALL OTHER POSSIBLE MEANINGS OF THE TERM "LINUX" ARE PURELY COINCIDENTAL AND ARE HEREWITH STRICTLY BANNED WITH RESPECT TO THIS POST. IF ANY OF THEM KEEPS RESURFACING IN READERS' MINDS A BRAINWASH IS URGENTLY ADVISED.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=487006" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author></entry><entry><title>At las(t)</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2005/10/01/476040.aspx" /><id>http://blogs.msdn.com/sompost/archive/2005/10/01/476040.aspx</id><published>2005-10-01T19:25:00Z</published><updated>2005-10-01T19:25:00Z</updated><content type="html">&lt;P&gt;I haven't checked out all the details of the new &lt;A href="http://atlas.asp.net/"&gt;Atlas&lt;/A&gt; Web Client Framework yet, therefore I don't know whether I like it or not. What I certainly like is that -- finally -- there has been some progress in the field of interactive Web services since I built my first Web service in 1995 and shook my head in astonishment that it was necessary to reload a complete Web page when all you wanted was to swap an image. Not anymore! Since Google's GMail (if you're faith-based) or MSDN's left-hand navigation bar (if you're closer to the reality-based community) Web pages are truly interactive!&lt;/P&gt;
&lt;P&gt;So, at last, there's Altas! Besides all the bells and whistles required to build graphical Web UIs the framework also simulates non-JavaScript language features such as namespaces, classes, and interfaces. I'd have to play with it (build a small Weblication) to experience myself whether these extensions make life easier or only the framework more complex. But so far I haven't.&lt;/P&gt;
&lt;P&gt;However, I &lt;EM&gt;have&lt;/EM&gt; (like on &lt;A href="http://spaces.msn.com/members/sompost"&gt;similar occasions&lt;/A&gt; before) provided pretty-printed, color coded and InScript™-enhanced listings of some of the the various Atlas files drawn from the &lt;A href="http://atlas.asp.net/quickstart"&gt;Atlas Quickstart Guide&lt;/A&gt;. To that end, I have extended (as in "hacked") the &lt;EM&gt;InScript Code Listing Enhancer&lt;/EM&gt; technology &lt;B&gt;:-)&lt;/B&gt; to "recognize" namespaces, and to allow folding and unfolding of the various classes.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasCompat.htm"&gt;AtlasCompat.js&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasCore.htm"&gt;AtlasCore.js&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasUI.htm"&gt;AtlasUI.js&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasUIDragDrop.htm"&gt;AtlasUIDragDrop.js&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasControls.htm"&gt;AtlasControls.js&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://research.microsoft.com/users/som/blog/AtlasRuntime.htm"&gt;AtlasRuntime.js&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;&lt;SMALL&gt;&lt;EM&gt;If you can't guess from the names above what's likely to be found in the various files there's perhaps little point in your going there anyway (and my telling you, for that matter).&lt;/EM&gt;&lt;/SMALL&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;There's some overlap in the various code files. In particular the &lt;EM&gt;AtlasRuntime&lt;/EM&gt; contains parts of the &lt;EM&gt;AtlasCore&lt;/EM&gt;. As I said, I don't know in detail what's in all the files but that doesn't mean that you shouldn't have the tools to find out yourself. Hence this post!&lt;/P&gt;
&lt;P&gt;You may also want to see the video of MSN Web Experience architect Scott Isaac unveiling the &lt;A href="http://channel9.msdn.com/showpost.aspx?postid=118319"&gt;MSN DHTML Foundation&lt;/A&gt; over on &lt;A href="http://channel9.msdn.com/"&gt;Channel 9&lt;/A&gt;.&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=476040" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author><category term="Web Development" scheme="http://blogs.msdn.com/sompost/archive/tags/Web+Development/default.aspx" /><category term="JavaScript" scheme="http://blogs.msdn.com/sompost/archive/tags/JavaScript/default.aspx" /><category term="AJAX" scheme="http://blogs.msdn.com/sompost/archive/tags/AJAX/default.aspx" /></entry><entry><title>Who put the mob in mobile phones?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/sompost/archive/2005/09/30/who-put-the-mob-in-mobile-phones.aspx" /><id>http://blogs.msdn.com/sompost/archive/2005/09/30/who-put-the-mob-in-mobile-phones.aspx</id><published>2005-09-30T01:24:00Z</published><updated>2005-09-30T01:24:00Z</updated><content type="html">&lt;P&gt;&lt;IMG style="WIDTH: 59px; HEIGHT: 130px" height=130 hspace=4 src="http://farm3.static.flickr.com/2148/2439656962_d9d3bfaabe.jpg?v=0" width=59 align=right vspace=4 mce_src="http://farm3.static.flickr.com/2148/2439656962_d9d3bfaabe.jpg?v=0"&gt; Last time I was in Switzerland I bought one of the stylish new &lt;A href="http://www.m-budget-mobile.ch/" mce_href="http://www.m-budget-mobile.ch/"&gt;M-Budget Mobile&lt;/A&gt; phones by &lt;A href="http://www.migros.ch/" mce_href="http://www.migros.ch/"&gt;Migros&lt;/A&gt;, the biggest retailer in Switzerland. Not that I particularly needed another one, but when I heard that the two biggest retailers (Migros and &lt;A href="http://www.coop.ch/" mce_href="http://www.coop.ch/"&gt;Coop&lt;/A&gt;) were each about to offer a budget mobile phone service I couldn't resist.&lt;/P&gt;
&lt;P&gt;Also, Migros' line of budget products with its cheap(ish) styling has become sort of a cult in Switzerland. Affluent people used to shy away from those products because buying Budget might make them look poor but now it's hip. There are even rumours that the Budget style is being pilfered to style Web sites and Blogs.&lt;/P&gt;
&lt;P&gt;Anyway, so I went with the mob and bought an M-Budget Sony Ericsson T290i with SIM card and &lt;SPAN title="€6.67 £4.40 $8.00"&gt;CHF 10.-&lt;/SPAN&gt; worth of calls for only &lt;SPAN title="€39.20 £25.90 $47.04"&gt;CHF 58.80&lt;/SPAN&gt;. Calls cost &lt;SPAN title="€0.29 £0.19 $0.35"&gt;CHF 0.44&lt;/SPAN&gt; per minute, and an SMS only &lt;SPAN title="€0.07 £0.04 $0.08"&gt;CHF 0.10&lt;/SPAN&gt;. &lt;FONT size=1&gt;&lt;I&gt;Hover for currency conversion&lt;/I&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;The whole launch business, by the way, was quite funny because the two retailers announced their intentions about the same time, however Coop's rate was initially lower than that of Migros, so the latter had to lower theirs in turn before the ink on their adverts was even dry. So there you go. I've got two mobile phones now when I rarely need even one.&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=475527" width="1" height="1"&gt;</content><author><name>sompost</name><uri>http://blogs.msdn.com/members/sompost.aspx</uri></author></entry></feed>