Saturday, April 26, 2008

We'll Always Have C

The other day there was an interview in Dr. Dobb's Journal with the managing director of TIOBE Software, who publishes the TIOBE Programming Community Index, a ranking of programming language popularity. It was also discussed on Slashdot.

The methodology used by TIOBE to calculate a language's popularity is basically the good old google hits ad-hoc voodoo index, using "[language] programming" as the query. This measures the "web presence" of a programming language.

First of all, it's obvious to you and me that this measures something, that something being the amount of web pages including the term "[language] programming", obviously. There's nothing wrong with this method, as long as one is aware of what they're measuring. But is it fair to call this the popularity of a language?


Look at this blog, for example. I mostly mention JavaScript and PHP here, just like everyone else. Throw in some Ruby and Python too to max out the buzz factor. There is no mention of relics such as C in this blog. But you know what language I use ten times more than any other? C. I'd love to have a job hacking away in JavaScript, Ruby, and Python all days, but I'd have to settle with half the salary. So here it goes: C programming. Index that. Embedded, heavily multi-threaded, efficient, minimum memory, hardcore badass C programming, that's what I do, and I love doing it.

Most coders can't do C. That's why you see all these Visual This and Dot That and scripting languages on the ranking, because these kids blog about every little insignificant hobby project they manage to cut and paste together, just like I do. But let there be no mistake about it: real programmers can code in C. They do syntactically correct typedefs of function pointers in their sleep. (just kidding that's impossible.)


At work I also hack in Python, Perl, and Makefile. At home it's mostly JavaScript, PHP, Ruby, Python... Lately Python has replaced Ruby as my language of choice for home hacking because of its decent unicode support. (Although I've had to hack the Python standard library in some places where it didn't properly support unicode. I read the next version of Python (2.6?) will use unicode strings by default, which is great, and only ten years late.) I also sold my soul the other day and installed Visual C# 2008 Express Edition for some hobby hacking. Turned out not very fun though, but I haven't given up yet.

At my previous job I used C++ for doing essentially the same thing as I do in C now. I'm completely convinced that C is the right tool for the job. I'm also convinced C does object orientation better than C++, but that is a topic for another post. And I used to be a Java fan, but now I'm considering Java the best examples of software suckiness ever. It's a volatile industry, technologies come and go, but no amount of blogging will convince me that the C programming language is anything but #1.

I'm saying it because it's true: We'll always have C. Because we've got jobs to do.

Labels: , , , , , , ,

Friday, July 13, 2007

Me and The Gimp (and Four-Wheeled Cars)

I use The Gimp to create graphics for my projects. The main reason is because it's free (as in beer) - I usually don't warez software except old games that don't sell any more anyway. That goes doubly for software I use to create software. So Photoshop is out of the question. And The Gimp is a really good application.

But as anyone who uses The Gimp can tell you, its interface sucks. It has always sucked and continues to suck to this day. Interestingly, quite often some discussion pops up regarding this sucky interface, and whether anyone should do anything about it - or whether war is actually peace.

Just the other day there was this article linked on Slashdot about some academic-type dudes who have developed a modified gimp that collects usage data, to analyze how people use it and possible be able to improve the interface.

Ok, it's done at a university so I realize it's just someone's waste of time and government money, but still... Anyone who's ever used gimp can tell you that there's just one simple, outstanding issue that accounts for roughly half of its suckiness: The Windows (imagine that in place of "The Horror" from Apocalypse Now!). The Gimp opens gazillions of windows - and they're not contained in one parent window, like every other application in the world, no - they behave like independent application windows. You don't need academic studies to figure that out. So if you're editing the graphics to a web app for instance, you switch to Firefox to see the result, and then back to The Gimp, and you have to open like 8 separate windows to get your UI back to the state it was before switching to another application. This gets deadly tedious.

If I were tasked with designing a commercial car - and I'm a software engineer, mind you - when I got to the matter of how many wheels to equip the vehicle with, I would go with 4. Just like that - it's a no brainer. Every other car out there has 4 wheels. I think it must make structural sense, and people are used to cars having 4 wheels. A mechanical engineer or a car marketing specialist could probably tell you more. The gods know how many wheels The Gimp's designers would fit on their cars.

Guys! Don't go buying that Photoshop license just yet! I have a solution to the problem! (If you run Linux you can skip the rest of this paragraph.) Just use a virtual desktop manager - like the *nix guys do. I use one called Yod'm 3d. Unfortunately it's been bought up by some suspicious company and made commercial, but the last freeware version, 1.4, works good enough and can be downloaded (legally) for instance from The Pirate Bay. Just run The Gimp on a virtual desktop of its own. Linux people have been doing this for ages, but it's never been habit in the real world, although I heard the next version of Mac OS will have virtual desktops. Anyway, you can have it today, in your Windows. (I used to run only Linux for many years, so I got this habit of using virtual desktops extensively back then.)

There are still a few nuances to work out of The Gimp though. But it doesn't require a Ph.D. to figure them out. If you, like me, never start using Photoshop, then at least you won't be annoyed simply because The Gimp is different - it should be!

I wish it had a line drawing tool though.

Labels: ,