Systeme D

9 November 2006

Jack's CPC doesn't have a dodgy SHIFT key

Joel Spolsky has a theory that the most productive languages to work in are those which do all your memory management for you.

I disagree. I reckon the most productive languages are those where the inventor has taken the simple decision to make all keyword names lower-case (Perl) or case-insensitive (ActionScript). Not those where the language definition was written by some klutz with a malfunctioning SHIFT key (hello, JavaScript). I have lost approximately one day of my life, including several hours today, to not being able to remember the gOatFuck which is getElementById. And I'd like it back please, W3C, if you don't mind.

(Equally heinous capitalisation: CSS - Cansei de Ser Sexy, not, well, you know - have a marvellous song called "Let's make love and listen to death from above", which sounds a bit like New Order remixing a Blondie cover of Barbie Girl. Uncapitalised as per above it's quite a cool title. When you realise that Death From Above is actually a Canadian grunge band, or something, it loses a bit of its lustre.)

On Tuesday a very friendly dentist spent 1hr45 fixing my teeth (despite the fact that West Oxfordshire District Council clearly believe all dental appointments only take 30 minutes, judging by the parking spaces outside). In order to take my mind off what was going on a few inches below it, I tried to work out "where next?" with various bits of web programming I'm doing at the moment.

As a result, I can now confidently pronounce that:

  • ActionScript 1 is much less painful than having your teeth pulled.
  • Perl is also less painful. Even regular expressions with zero-width look-ahead assertions are less excruciating than having your teeth pulled. Plus you can reassure yourself with the thought "it'll all be over before Perl 6 is released".
  • Internet Explorer's implementation of JavaScript and the DOM is significantly more painful than intense dental work, to the point where I opened my eyes again and frantically tried to concentrate on what the dentist was doing in an effort to take my mind off the reason why setAttribute("name") doesn't work in WinIE.
  • Approximately three seconds after I started to think about PHP, my head was gripped by searing pain. I don't know whether this was a result of the PHP or of something the dentist did. Just to be on the safe side I have resolved not to think about PHP again.

Anyway.

Apart from shouting at WinIE so that the marketing people can use our work CMS (I know, I know), I'm doing a whole bunch of ActionScript programming at the moment. This is for Potlatch, the Flash editor for Openstreetmap.

Most of the base logic is done now and I'm working on the UI... but have encountered an (entirely foreseeable) problem. All my Flash development is done using Ming, not least because I actually find it a whole load easier than the palette-o-rama which is the Macromedia Flash user interface. Ming, however, is sufficiently bare-bones that it doesn't support Flash 'components' - pre-built combinations of ActionScript and Flash primitives to provide commonly used functionality such as menus and checkboxes.

So I'm taking a bit of time to build Ming-friendly equivalents for these, starting with checkboxes, menus, and a rich text editor. Half the world seems to be looking for a Flash rich-text editor, and there are 8bn commercial ones but only (as yet) one open-source component. This is a bit surprising, because ActionScript's TextField and TextFormat objects actually make it dead easy to build a rich text editor in Flash.

They're all working at a very raw, unpolished level thus far. When they're a bit more polished I'll release them separately.

Add a comment

Your name:

E-mail address: 

Comment:

your comment. (E-mail addresses will not be visible, but a server-based mail link will be provided. To guard against spam, no comments which include 'http' or 'www' will be published.)