<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><description></description><title>Dmitry’s Tumblr</title><generator>Tumblr (3.0; @dmitry-baranovskiy)</generator><link>http://dmitry-baranovskiy.tumblr.com/</link><item><title>Raphaël 1.2.1</title><description>&lt;p&gt;In Raphaël 1.2 release I did two major changes that I want to explain: IE optimisation and animation revamp.&lt;/p&gt;
&lt;p class="not-prime"&gt;For drawing in IE Raphaël uses VML. VML syntax for path is different to SVG: it uses different letters for commands and it doesn’t support floating point numbers. So to insure correct work I have to replace commands and round the numbers. But this not the end, IE doesn’t support quadratic curves and arcs. To work it around I convert everything into cubic curves. Conversion takes time. In IE we facing world slowest JavaScript engine, so on big paths performance could go down to unacceptable level. In 1.2 I optimized it a bit. I convert path to curves only if it has cubic curves or arcs, otherwise I just replace commands and round the numbers. Unfortunately I can’t come with a better solution at the moment, but if you have any, drop me a line.&lt;/p&gt;
&lt;p class="not-prime"&gt;The animation in Raphaël was done not in the best way: for each animation I created separate timer, so in case if you animate multiple objects at the same time, they are moving asynchronously. I unite all animation under the same timer and it made animation smoother in Safari and more accurate in all browsers. But there is still an issue with the fact that when you animate a large group of elements it is impossible to start animation for each element at the same time. The worst JavaScript engine the bigger is the gap between animations and on long run it is quite noticeable. To fight this I introduced new method animateWith, which first argument is an element you wish to stick to. Raphaël uses it internally when you animate set, so I would say the easiest way to animate two elements synchronously is to unite them in set and call animate method on the set.&lt;/p&gt;
&lt;p class="not-prime"&gt;In the &lt;a href="http://vimeo.com/7275179"&gt;video&lt;/a&gt; I created 150 circles and animated them to the same X. You can easily see the difference.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/224268034</link><guid>http://dmitry-baranovskiy.tumblr.com/post/224268034</guid><pubDate>Tue, 27 Oct 2009 10:29:00 +1100</pubDate></item><item><title>The Emperor’s New Clothes</title><description>&lt;p&gt;It was an argument in web standards talks for a while. Tables for layout, style attributes, JavaScript event attributes, inline script tags and even font tags are ok. Take a look at &lt;a href="http://google.com/"&gt;google.com&lt;/a&gt;. Right. Google.com is probably most visited page in the web, so if &lt;code&gt;&lt;font size=-1&gt;blah&lt;/font&gt;&lt;/code&gt; is smaller than correct semantic HTML and CSS, even by one byte, then it worth it. &lt;a href="http://www.youtube.com/watch?v=FPBACTS-tyg"&gt;Because every byte counts&lt;/a&gt;. With such a traffic every byte of home page costs some quite visible money to the company. (I even heard a stories about some guy, who managed to reduce size of the google.com page by couple of characters and received a bonus from the company…) Google just put size of the page as a priority above valid mark up, right?&lt;/p&gt;
&lt;p&gt;Not really.&lt;/p&gt;
&lt;p&gt;If you look at the source code of the google.com home page, you will see that size of it could be decreased a lot. In particular inline JavaScript can be compressed at least by 10%.&lt;/p&gt;
&lt;p&gt;Consider following example&lt;/p&gt;
&lt;p&gt;This is code from google.com:&lt;/p&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;if(window.addEventListener)window.addEventListener("load",a,false);else if(window.attachEvent)window.attachEvent("onload",a);google.timers.load.t.prt=(new Date).getTime();&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is how it can be written:&lt;/p&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;var w=window,e=w.addEventListener,v=w.attachEvent;e&amp;&amp;e("load",a,!1);v&amp;&amp;v("onload",a);google.timers.load.t.prt=+new Date;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I just saved 51 byte! There are more, literally kilobytes of code to be saved, but it looks like nobody cares. Wait, if nobody cares about page size, why we have ridiculous font tags in the page? May be I don’t understand some obvious thing or may be the King is naked.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/201475166</link><guid>http://dmitry-baranovskiy.tumblr.com/post/201475166</guid><pubDate>Thu, 01 Oct 2009 13:58:00 +1000</pubDate><category>google</category><category>javascript</category></item><item><title>Raphaël 1.0 RC1</title><description>&lt;p&gt;Recently I released Raphaël 1.0 RC1. The most noticeable change for users of the library is differences in the API: removing moveTo, lineTo and friends from the path object. Why did I decide to do this? The biggest drawback of these methods is that they apply immediately. That means that if you draw path consisting of three segments, path element is updated three times – each time with increased number of segments, so total number of segments drawn is 1 + 2 + 3 = 6. The more segments your path has, the longer it takes to draw. In geometric progression.&lt;/p&gt;
&lt;p class="non-prime"&gt;To avoid this I could introduce some method “draw” that could be called after you define all segments, but this doesn’t look like an elegant solution and doesn’t suit the library’s name. There is a soluton that is compact, simple and you could easily work with it. Say, you want to change some point on the path. There is no interface for this apart from SVG path, and I can’t think of any elegant and easy to grasp API for this. Manipulating strings is what JavaScript can do very well. So I removed these methods from the library to external plugin, which you could concatenate with the Raphaël if you really rely on them. I suggest you learn SVG path syntax: it is simpler than it looks.&lt;/p&gt;
&lt;p class="non-prime"&gt;Other big thing is adding support for angle in arc. This is very rare thing, and frankly, I haven’t seen it in the wild, but without it SVG path support wasn’t complete. To make it happen I rewrote arcTo for VML completely. Now it converts arc to bezier curve, because VML doesn’t have support for angles in arc segments. The same method is now used in animation (for SVG &amp; VML), which makes animation more smooth. Conversion of the whole path into bezier curves let me do path bounding box calculations more precisely, especially in VML. In fact, Safari doesn’t calculate bounding box for path correctly either.&lt;/p&gt;
&lt;p class="non-prime"&gt; I also worked on improving performance by applying caching and simply optimizing code.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/184258966</link><guid>http://dmitry-baranovskiy.tumblr.com/post/184258966</guid><pubDate>Thu, 10 Sep 2009 14:42:00 +1000</pubDate></item><item><title>Mermaids &amp; Fishermen</title><description>&lt;p&gt;Imagine the ocean. The ocean where live mermaids and lots of fisherman are chasing their luck. If you ask mermaids and fisherman about ocean they will tell you the same story: “I love ocean. Ocean is my home. I live in breath of the ocean only…” etc. But in fact their approach to ocean is very different. Fisherman care only about money they will get for fish. Ocean is just a big reservoir for them. For mermaids it is truly their home. They care about balance and purity of the ocean. Some fishermen don’t even believe that mermaids exist, some haven’t even heard of them. Fishermen can’t see the ocean as mermaids do, some of them tried: put their head under the water, everything is blurred, they can’t breathe. Pull head back. Never did it again. Some mermaids are tempted by the money they could make as a fisherman, but they lost their magic and become just “yet another fisherman”. Fishermen are winning. Huge tankers crossing the ocean and are taking enormous amount of fish from the ocean ruining the balance. Mermaids can’t stop fisherman, because they talk different language and can’t understand each other.&lt;/p&gt;
&lt;p class="not-prime"&gt;This ocean is called “the World Wide Web”.&lt;/p&gt;
&lt;p class="not-prime"&gt;There are web developers, who care about web, standards, semantic, accessibility, etc. They are mermaids. And there are web developers, who care about result only. If the web page is a soup of HTML, inline CSS and inline JavaScript, that’s ok as long as performance tests show us that it is even 0.5 ms faster.&lt;/p&gt;
&lt;p class="not-prime"&gt;Who are you? Fisherman or mermaid?&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/154714451</link><guid>http://dmitry-baranovskiy.tumblr.com/post/154714451</guid><pubDate>Mon, 03 Aug 2009 16:02:37 +1000</pubDate></item><item><title>We need to talk</title><description>&lt;p&gt;
    I am very lucky person. I met personally so many great people, like &lt;a href="http://themaninblue.com/" title="The Man in Blue &gt;  Code &amp; Beauty"&gt;Cameron Adams&lt;/a&gt;, &lt;a href="http://johnfallsopp.com/" title="John Allsopp: My life online"&gt;John Allsopp&lt;/a&gt;, &lt;a href="http://lachstock.com.au/" title="Lachlan Hardy Presents: Lachstock"&gt;Lachlan Hardy&lt;/a&gt;, &lt;a href="http://maxdesign.com.au/" title="Max Design - standards based web design, development and training"&gt;Russ Weakley&lt;/a&gt;, &lt;a href="http://toolmantim.com/" title="Tim Lucas - toolmantim.com"&gt;Tim Lucas&lt;/a&gt; and many more others who, I hope, will forgive my laziness. The problem is, I don’t remember when last time I was talking to any of them (except Lachlan who is my colleague at Atlassian). We proud of our community, we see each other on conferences and other events, but there is no time to talk there. I mean really talk, share ideas, search for advice, etc. This is only possible with some limited amount of people in the room. I know these guys for at least two years and I have never really talk to anyone of them. Ever. This is very sad. What to do about it? The simplest way is to grab the person you want to talk to and invite him for lunch. Most of us are working somewhere near CBD, so we should catch up more frequently. Send an e-mail to person you know for ages and invite him/her for lunch. Everybody will win. Do it today.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/146533789</link><guid>http://dmitry-baranovskiy.tumblr.com/post/146533789</guid><pubDate>Wed, 22 Jul 2009 13:59:26 +1000</pubDate></item><item><title>Objects in JavaScript (part II)</title><description>&lt;p&gt;I will not write about prototypical inheritance in JavaScript today. Instead lets take a look at one misunderstanding:&lt;/p&gt;

&lt;blockquote&gt;“Changing prototype on the constructor will magically update not only new objects, but also all existing ones…”&lt;/blockquote&gt;

&lt;p class="not-prime"&gt;This is totally wrong. Do not trust an author who uses word “magic” while explaining JavaScript (or anything).&lt;/p&gt;

&lt;pre class="javascript code"&gt;&lt;code&gt;function C() {} //constructor
var x = new C();
C.prototype.prop = 2;
var y = new C();
alert(x.prop);
alert(y.prop);&lt;/code&gt;&lt;/pre&gt;


&lt;p class="not-prime"&gt;This code will alert “2” and “2”, which kind of proves quoted concept: object &lt;code&gt;x&lt;/code&gt; gains new property &lt;code&gt;prop&lt;/code&gt; after it was created. Magic? Not at all. Lets look at similar example:&lt;/p&gt;

&lt;pre class="javascript code"&gt;&lt;code&gt;function C() {} //constructor
var x = new C();
C.prototype = {prop: 2};
var y = new C();
alert(x.prop);
alert(y.prop);&lt;/code&gt;&lt;/pre&gt;

&lt;p class="not-prime"&gt;This will alert “undefined” and “2”. Huh?&lt;/p&gt;

&lt;p class="not-prime"&gt;In the first case neither of objects (&lt;code&gt;x&lt;/code&gt; or &lt;code&gt;y&lt;/code&gt;) have property prop. What they have is a hidden reference to prototype. (Hidden, because only interpreter internally can access it.) When you ask for property &lt;code&gt;prop&lt;/code&gt; JavaScript can’t find it in the object itself and look for it in linked prototype object, found it there and return it. So for you, as a programmer, it is no visual difference where property is stored: in the object itself or in its prototype. When you add new property to prototype object &lt;code&gt;x&lt;/code&gt; didn’t change. When you ask for property prop JavaScript finds it in updated prototype.&lt;/p&gt;

&lt;p class="not-prime"&gt;In the second case we assign new object as a prototype. Now object &lt;code&gt;x&lt;/code&gt; still refers to the old prototype, but object &lt;code&gt;y&lt;/code&gt; refers to new. &lt;code&gt;x&lt;/code&gt; and &lt;code&gt;y&lt;/code&gt; do not share prototype anymore. Obviously old prototype doesn’t have property &lt;code&gt;prop&lt;/code&gt;. Even worse, now you lost the only access point to it. Despite these two objects were created with the same syntax they are way different.&lt;/p&gt;

&lt;p class="not-prime"&gt;One more thing. As you know every object by default receives property &lt;code&gt;constructor&lt;/code&gt;, which refers to its constructor (surprise). But just as &lt;code&gt;prop&lt;/code&gt; &lt;code&gt;constructor&lt;/code&gt; property doesn’t exists in object itself, but rather in its prototype. By rewriting prototype we rewrite constructor property as well:&lt;/p&gt;

&lt;pre class="javascript code"&gt;&lt;code&gt;alert(x.constructor); // "function C() {}"
alert(y.constructor); // "function Object() { [native code] }"&lt;/code&gt;&lt;/pre&gt;

&lt;p class="not-prime"&gt;So, when you rewriting prototype you can’t rely on constructor property anymore. But rewriting prototype is a main technique of inheritance in JavaScript.&lt;/p&gt;
&lt;p class="not-prime"&gt;I will write about inheritance next time.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/100478853</link><guid>http://dmitry-baranovskiy.tumblr.com/post/100478853</guid><pubDate>Mon, 27 Apr 2009 11:08:00 +1000</pubDate><category>javascript</category></item><item><title>Objects in JavaScript (part I)</title><description>&lt;p&gt;Recently I was talking to friend of mine about objects in JavaScript. He is writing JavaScript for living and very good at it, however I found that he doesn’t understand some core features of the language. So, in case you have this gap in understanding JavaScript, I’ll try to explain.&lt;/p&gt;
&lt;p class="not-prime"&gt;Friend of mine give cite me one book:&lt;/p&gt;
&lt;blockquote&gt;“The interesting thing about ECMAScript primitive values for Booleans, numbers, and strings is that they are pseudo-objects, meaning that they actually have properties and methods.”&lt;/blockquote&gt;
&lt;p class="not-prime"&gt;I am really sorry, but this doesn’t make any sense.&lt;/p&gt;
&lt;p class="not-prime"&gt;First lets take a look at this example:&lt;/p&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;var a = 5;
a.t = 3;
alert(a.t);&lt;/code&gt;&lt;/pre&gt;
&lt;p class="not-prime"&gt;It will alert “&lt;code&gt;undefined&lt;/code&gt;”. Why? If “&lt;code&gt;a&lt;/code&gt;” is a “pseudo-object” then why it doesn’t keep my property? The thing is, “&lt;code&gt;a&lt;/code&gt;” is not an object. Not even “pseudo-object”. It is primitive number. It doesn’t have properties. As you know JavaScript convert variable from one type to another on the fly:&lt;/p&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;var b = "w" + a + [1, 2, 3];&lt;/code&gt;&lt;/pre&gt;
&lt;p class="not-prime"&gt;In this example number “&lt;code&gt;a&lt;/code&gt;” and array &lt;code&gt;[1, 2, 3]&lt;/code&gt; will be converted to string on the fly. The same is happening with anything before “&lt;code&gt;.&lt;/code&gt;” operator, JavaScript simply converts left hand side parameter to object. So, at the second line of the example JavaScript creates new object Number with value equals to “&lt;code&gt;a&lt;/code&gt;” (5 in our case), then create new property “&lt;code&gt;t&lt;/code&gt;” with value 3. But then this object is not assigned back to variable “&lt;code&gt;a&lt;/code&gt;”, it is just disappear in garbage. Third line will again create new object and will try to read it property “&lt;code&gt;t&lt;/code&gt;”, which is undefined.&lt;/p&gt;
&lt;p class="not-prime"&gt;Primitive types like boolean, number and strings are not objects, they could be converted to objects. What the rule? JavaScript has six built-in types: null, undefined, number, string, boolean and object. The conversion rule is simple: if input is object, leave it as is; if input is null or undefined, throw an exception; otherwise create new object (&lt;code&gt;new Number(input)&lt;/code&gt; or &lt;code&gt;new String(input)&lt;/code&gt; or &lt;code&gt;new Boolean(input)&lt;/code&gt;). Hope this small bit will help somebody to understand objects in JavaScript a bit better. Next type I write about prototype and friends.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/96721628</link><guid>http://dmitry-baranovskiy.tumblr.com/post/96721628</guid><pubDate>Thu, 16 Apr 2009 15:13:00 +1000</pubDate><category>javascript</category></item><item><title>So, you think you know JavaScript?</title><description>&lt;p&gt;
    Quick test for real understanding of JavaScript core beyond closures and scopes. Here five small scripts. Try to answer what will be alerted in each case without running them in the console. Then you could create a test file and easily check your answers. Ready?
&lt;/p&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;if (!("a" in window)) {
    var a = 1;
}
alert(a);&lt;/code&gt;&lt;/pre&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;var a = 1,
    b = function a(x) {
        x &amp;&amp; a(--x);
    };
alert(a);
&lt;/code&gt;&lt;/pre&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;function a(x) {
    return x * 2;
}
var a;
alert(a);
&lt;/code&gt;&lt;/pre&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;function b(x, y, a) {
    arguments[2] = 10;
    alert(a);
}
b(1, 2, 3);
&lt;/code&gt;&lt;/pre&gt;
&lt;pre class="javascript code"&gt;&lt;code&gt;function a() {
    alert(this);
}
a.call(null);
&lt;/code&gt;&lt;/pre&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/91403200</link><guid>http://dmitry-baranovskiy.tumblr.com/post/91403200</guid><pubDate>Tue, 31 Mar 2009 12:09:00 +1100</pubDate><category>javascript</category></item><item><title>Raphaël 0.7</title><description>&lt;p&gt;
    New Raphaël release:
&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Plugins functionality (&lt;code&gt;Raphael.fn.myshape = function () {};&lt;/code&gt;)&lt;/li&gt;
    &lt;li&gt;New method “set” as a replacement for depricated “group”&lt;/li&gt;
    &lt;li&gt;getBBox for text is fixed in IE&lt;/li&gt;
    &lt;li&gt;Added point of origin in rotation&lt;/li&gt;
    &lt;li&gt;Added support for “src” attribute in attr method&lt;/li&gt;
    &lt;li&gt;Added setWindow method for iframes support&lt;/li&gt;
    &lt;li&gt;Added setSize method, so you can resize canvas&lt;/li&gt;
    &lt;li&gt;Provide alternate simple syntax for gradients: &lt;code&gt;“90-#000-#fff”, “‹angle›-‹colour›[-‹colour›[:‹offset›]]*-‹colour›”&lt;/code&gt;
&lt;/li&gt;
    &lt;li&gt;Added multiline text support&lt;/li&gt;
    &lt;li&gt;Added event handlers: &lt;code&gt;Element.click(function), Element.unclick(function)&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/85684984</link><guid>http://dmitry-baranovskiy.tumblr.com/post/85684984</guid><pubDate>Thu, 12 Mar 2009 11:39:22 +1100</pubDate></item><item><title>Washington Post Using Raphaël</title><description>&lt;p&gt;
    &lt;img src="http://ajaxian.com/wp-content/uploads/wp_image1.png" alt="screenshot from washingtonpost.com" class="image-inset"/&gt;
    As stated on &lt;a href="http://ajaxian.com/archives/washington-post-using-svg-and-vml" title="Ajaxian » Washington Post Using SVG and VML"&gt;Ajaxian&lt;/a&gt; &lt;a href="http://www.washingtonpost.com/"&gt;Washington Post&lt;/a&gt; start using Raphaël. Frankly, this is company named &lt;a href="http://www.evri.com/" title="Search less, understand more - Evri"&gt;Evri&lt;/a&gt;, who &lt;a href="http://blog.evri.com/index.php/2009/02/13/washington-post-and-evri/" title="Evri Blog  » Blog Archive   » The Washington Post and Evri announce partnership"&gt;is working for Washington Post&lt;/a&gt; and creates fancy widgets for them, uses Raphaël for drawing purposes. Anyway, Raphaël is on washingtonpost.com and it is time to celebrate. To see it by yourself you can visit &lt;a href="http://www.washingtonpost.com/wp-dyn/content/article/2009/02/23/AR2009022302176.html?hpid=topnews" title="Obama's Job Approval Ratings High, but Poll Finds Bipartisan Support Eroding - washingtonpost.com"&gt;this page&lt;/a&gt;.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/81272504</link><guid>http://dmitry-baranovskiy.tumblr.com/post/81272504</guid><pubDate>Wed, 25 Feb 2009 14:27:03 +1100</pubDate></item><item><title>WSG Talk</title><description>&lt;p&gt;
    On 11 March 2009 I will be presenting Raphaël at &lt;a href="http://webstandardsgroup.org/meetings/index.cfm?event_id=165" title="Web Standards Group - March Sydney WSG meeting"&gt;Web Standards Group meeting&lt;/a&gt;. Come and join me.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/80687400</link><guid>http://dmitry-baranovskiy.tumblr.com/post/80687400</guid><pubDate>Mon, 23 Feb 2009 17:23:00 +1100</pubDate></item><item><title>Raphaël 0.6—Animation and More</title><description>&lt;p&gt;
    Now, when I finally updated the documentation page, I feel ok to introduce you to Raphaël 0.6. So, what is new in this version?
&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Ability to set rotation, translation and scale via &lt;code&gt;attr&lt;/code&gt; method&lt;/li&gt;
    &lt;li&gt;Ability to set path via &lt;code&gt;attr&lt;/code&gt; method. That means now you can change path without redrawing it. The only thing you have to learn how to write path string in &lt;a href="http://www.w3.org/TR/SVG11/paths.html#PathData" title="Paths - SVG 1.1 - 20030114"&gt;SVG documentation for path data syntax&lt;/a&gt;
&lt;/li&gt;
    &lt;li&gt;New method animate, which takes three parameters: new attributes object, milliseconds and optional callback function&lt;/li&gt;
    &lt;li&gt;
&lt;code&gt;rotate&lt;/code&gt; method now has optional &lt;code&gt;isAbsolute&lt;/code&gt; parameter which make it rotate object &lt;strong&gt;to&lt;/strong&gt; specified degree, not &lt;strong&gt;by&lt;/strong&gt; degree.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;
    You could see the &lt;a href="http://raphaeljs.com/0.6.html" title="Raphaël 0.6"&gt;test demo&lt;/a&gt; and &lt;a href="http://raphaeljs.com/chart.html" title="Raphaël 0.6"&gt;chart demo&lt;/a&gt;.
&lt;/p&gt;
&lt;p&gt;
    Also I created &lt;a href="http://groups.google.com.au/group/raphaeljs" title="Raphaël | Google Groups"&gt;the Google group for Raphaël&lt;/a&gt;, so if you need some support or have feedback, please join the group.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/69025310</link><guid>http://dmitry-baranovskiy.tumblr.com/post/69025310</guid><pubDate>Thu, 08 Jan 2009 10:07:06 +1100</pubDate><category>raphael</category><category>javascript</category></item><item><title>Mac Shortcuts Converter</title><description>&lt;p&gt;
    When switched to Mac it was a real disaster to understand all these special symbol OS uses for control keys (⌘, ⌥, etc). After a while I used to them and now I feel sorry for people who have to write “&lt;kbd&gt;Command + Option + P&lt;/kbd&gt;” instead of “&lt;kbd&gt;⌘⌥P&lt;/kbd&gt;”. To solve this little aesthetic issue I wrote a &lt;a href="http://dmitry.baranovskiy.com/work/mackbd/" title="Mac Kbd Converter"&gt;little application&lt;/a&gt;. Use it for good and let force be with you.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/62566353</link><guid>http://dmitry-baranovskiy.tumblr.com/post/62566353</guid><pubDate>Tue, 02 Dec 2008 17:57:39 +1100</pubDate></item><item><title>iPhone Clock Web Application</title><description>&lt;img src="http://dmitry.baranovskiy.com/res/iphoneclock.png" alt="iPhone Clock" class="image-inset" width="320"/&gt;&lt;p&gt;
    Since last year &lt;a href="http://webjam.com.au" title="Webjam brings you the latest in piping hot web"&gt;WebJam&lt;/a&gt;™ I am proud owner of shiny iPod Touch. Yes, still shiny. What I found recently that while I am in the office my iPod just wasting space at my desk. Just for fun I decide to create simple web application that will turn my iPod to digital clock while I am in the office.
&lt;/p&gt;
&lt;p class="not-prime"&gt;
    Just for fun I decide to emulate old LC clock without any images or vector graphics. To make it look like application I have to put special meta tag inside HTML (&lt;code&gt;&lt;meta name="apple-mobile-web-app-capable" content="yes"&gt;&lt;/code&gt;). The problem with this method is that page doesn’t react to device rotation, but benefit of having custom digits is you can rotate them easily. So, don’t be surprised to see clocks rotated 90° in your browser. Here is a &lt;a href="http://dmitry.baranovskiy.com/clock/"&gt;result&lt;/a&gt;.
&lt;/p&gt;
&lt;img src="http://dmitry.baranovskiy.com/res/fig1fig2.png" alt="Fig. 1 &amp; Fig. 2" class="image-inset" width="320"/&gt;&lt;p class="not-prime"&gt;
    The question is, how I did all these fancy shapes without images? I was using borders. Take a look at fig. 1. If you apply wide border to some element and paint one side in different colour browser will solve graphical problem by creating “photo frame corner”. So, on fig. 2 I show idea: two narrow DIVs with wide borders will create a shape I need. Now in CSS I specify display rules depending on the value of the digit. I didn’t specify colour for borders so they could inherit colour from body text. Now to change colour of the clock I just need to change colour of the body. The rest is easy.
&lt;/p&gt;
&lt;p class="not-prime"&gt;
    Hope you could pick up some interesting techniques from this example.
&lt;/p&gt;
&lt;p class="not-prime"&gt;
    &lt;strong&gt;Update:&lt;/strong&gt;
    Since iPhone/iPod software update 2.2 release had to update CSS a bit.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/60596028</link><guid>http://dmitry-baranovskiy.tumblr.com/post/60596028</guid><pubDate>Thu, 20 Nov 2008 11:20:00 +1100</pubDate><category>javascript</category><category>css</category><category>ipod</category><category>iphone</category><category>ipod touch</category></item><item><title>Raphaël Feed</title><description>&lt;p&gt;I’ve created twitter account for Raphaël. All upcoming news and releases will be announced there. Feel free to follow &lt;a href="http://twitter.com/RaphaelJS" title="Twitter / RaphaelJS"&gt;@RaphaelJS&lt;/a&gt; or subscribe to &lt;a href="http://twitter.com/statuses/user_timeline/17180567.atom" title="Twitter / RaphaelJS"&gt;RSS feed&lt;/a&gt;.&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/59618415</link><guid>http://dmitry-baranovskiy.tumblr.com/post/59618415</guid><pubDate>Fri, 14 Nov 2008 17:13:04 +1100</pubDate><category>raphael</category><category>javascript</category><category>twitter</category><category>rss</category></item><item><title>Web Directions South ’08 Wrap Up 2</title><description>&lt;p&gt;
Just want to point out that Web Directions crew finalised work on podcasts and podcast of my talk is available along with my slides at Web Directions web site, so &lt;a href="http://www.webdirections.org/resources/dmitry-baranovskiy-start-using-web-vector-graphics-today/" title="Dmitry Baranovskiy—Start using web vector graphics today | Web Directions"&gt;look and listen&lt;/a&gt; if you feel like this.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/57671637</link><guid>http://dmitry-baranovskiy.tumblr.com/post/57671637</guid><pubDate>Mon, 03 Nov 2008 15:56:44 +1100</pubDate></item><item><title>Pie Chart Madness</title><description>&lt;p&gt;
    With release of Raphaël 0.5.6b building pie charts become very easy task. Before I need to draw path with a hole inside, but now I can really draw every sector of the pie, because Raphaël finally has arcTo method. It was a bit of challenge to create it because VML has absolutely different interface from SVG. Fortunately Erik Dahlström from Opera point me to right direction. After that it was very easy to connect the points and have a good picture. Take a look at the demo of this &lt;a href="http://raphaeljs.com/pie.html" title="Pie chart"&gt;lovely pie chart&lt;/a&gt;.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/55699133</link><guid>http://dmitry-baranovskiy.tumblr.com/post/55699133</guid><pubDate>Wed, 22 Oct 2008 11:58:38 +1100</pubDate><category>raphael</category><category>javascript</category><category>piechart</category></item><item><title>Image rotation on iPod with Raphaël</title><description>&lt;object type="application/x-shockwave-flash" width="400" height="300" data="http://vimeo.com/moogaloop.swf?clip_id=1987967&amp;server=vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=00ADEF"&gt;&lt;param name="quality" value="best" /&gt;&lt;param name="allowscriptaccess" value="always" /&gt;&lt;param name="allowfullscreen" value="true" /&gt;&lt;param name="scale" value="showAll" /&gt;&lt;param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=1987967&amp;server=vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=00ADEF" /&gt;&lt;embed src="http://www.vimeo.com/moogaloop.swf?clip_id=1987967&amp;server=www.vimeo.com&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="400" height="300"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Image rotation on iPod with Raphaël&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/54928229</link><guid>http://dmitry-baranovskiy.tumblr.com/post/54928229</guid><pubDate>Fri, 17 Oct 2008 10:52:46 +1100</pubDate><category>raphael</category><category>iphone</category><category>ipod touch</category><category>ipod</category><category>javascript</category><category>svg</category><category>vml</category></item><item><title>San Francisco</title><description>&lt;p&gt;
    This Saturday (11 of October) I am travelling to San Francisco, California for two weeks. If anyone want to catch up for a coffee or something, feel free to drop me a line, because I probably will be bored after hours. Hope to see you there.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/53416637</link><guid>http://dmitry-baranovskiy.tumblr.com/post/53416637</guid><pubDate>Tue, 07 Oct 2008 17:33:17 +1100</pubDate></item><item><title>My First Interview Ever</title><description>&lt;p&gt;
    Interview I gave to &lt;a href="http://www.sitepoint.com/articlelist/487"&gt;Andrew Tetlaw&lt;/a&gt; from &lt;a href="http://www.sitepoint.com/" title="SitePoint : New Articles, Fresh Thinking for Web Developers and Designers"&gt;SitePoint&lt;/a&gt; at &lt;a href="http://www.webdirections.org/tag/wds08/" title="Wds08 | Web Directions"&gt;Web Directions South&lt;/a&gt; this year. Check it out: &lt;a href="http://www.sitepoint.com/blogs/2008/10/01/dmitry-baranovskiy-talks-about-raphael/" title="SitePoint Blogs » Dmitry Baranovskiy Talks about Raphaël"&gt;Dmitry Baranovskiy Talks about Raphaël&lt;/a&gt;.
&lt;/p&gt;</description><link>http://dmitry-baranovskiy.tumblr.com/post/52671362</link><guid>http://dmitry-baranovskiy.tumblr.com/post/52671362</guid><pubDate>Thu, 02 Oct 2008 10:21:00 +1000</pubDate><category>raphael</category><category>javascript</category><category>sitepoint</category></item></channel></rss>
