April 2008


About 1 week ago, Mauritius hosted the SADC Conference on Poverty with delagates staying in 5 star hotels, eating at banquets, travelling in limos, … Hopefully something good will come out of this; at least there was a buzz last week but it has quickly died out.

The really good thing that was set up is the Empowerment fund which is trying to help people start their own business or train people.

Give a man a fish and you feed him for a day. Teach a man to fish and you feed him for a lifetime.

An anime about an Afro Samurai – wow that original!

Afro Samurai is an anime from GONZO studio. In terms of story, it’s not so different from the usual anime stuff – basically it’s a samurai seeking revenge. In the world of Afro Samurai, samurais faight to be the number 1 in which they attain a “God like” status. But only the number 2 samurai can challenge the number 1. So the life of number 2 is a one of constant fights.

The story starts with Afro as a kid seeing his dad, the number 1, die killed by the number 2. After that, he leads a life of revenge and … eventually attains the status of number 1 after a number of fights.

Quite an ordinary anime – the point to note is Afro is accompanied by “Ninja Ninja” completely at the opposite of Afro.

Since some time now, I’ve noticed something quite “dangerous” that’s starting to happen in Mauritius. When person A from a certain community X accuses person B of community Y and latter doesn’t know what to answer, he immediately accuses person A of be a racist! It’s so easy and … so lame.

I’m going to be blunt here: If you are being criticized and can’t defend yourself, it’s either because you really did something wrong or are too lame to defend yourself! Hiding behind, “sa blanc la”, “sa malbar la”, “sa lascar la”, … doesn’t help! That’s especially true in the local political arena.

Last week-end, we had the annual chinese festival in Chinatown, Mauritius. As usual, I wanted to go have a look (with Bertrand and Pawan) and buy some salted plums (salangis) and while walking I saw a shop selling DVDs and I managed to get hold of Grave of the Fireflies (now the ones missing on my wishlist are: My neighbour Totorro, Castle in the sky and Porco Rosso)

Grave of the fireflies is a war movie that depicts the story of two kids Setsuko and Seita during the second world war in Japan.

grave01

At the start of the movie, they are living in Japan with their mum while their dad is in the navy. But after an intense fire bombing in Kobe, they lose their mum (and house) and go to live with their aunt. Initially, all is well but as the family is pressured by lack of food (during the war), they soon find Setsuko and Seita a burden. As a result, the kids leave and find a new “home” in an old abandoned shelter by a river.

Grave of the fireflies

As they don’t have any light at night, they watch firelies and there starts their struggle to stay alive – trading stuff, stealing food from fields, raiding houses during firebombing – until eventually … they die of hunger.

Critics
Grave of the fireflies is widely recognized as one of the best war-movies (it’s rated at around 200 on IMDB top 250 movies). It does not try to turn anyone into a devil, it just shows how people behaved when pressed by war – would you be able to blame the aunt for making Setsuko and Seita feel undesired if she is not having enough food for herself?

One of my must-see movies.

Have you ever tried driving by looking in your rear mirror only? If you’ve not tried yet, I’m sure there’s a good reason why!

In Mauritius, we govern not by looking forward but by looking back, apart from the fact that our Prime Minister likes to continuously refer to his dad ;) , all we talk about is what has happened. For example, one year ago we were all focussing on tsunamis (who knew that word 5 years back – now even 5 year old kids know about it) and we were wondering how to protect Mauritius. Now everyone is just talking about flooding (and we’re putting the blame on climate change – it’s so much nicer compared to putting it on some minister…). But what are the odds that these will re-occur anytime soon? I might be wrong but statistically the chances are low.

We’ve been shattered by natural calamities and we saw that we were not prepared at all. What we need to do is to reassess our ability at dealing with threats (those we’ve faced and those we’ve not faced yet) and prepare ourselves for future calamities that might fall on us. Just imagine that in one year, a tanker sinks near our coast and there’s a massive oil spill. Are we prepared for that? We’ve never faced such a calamity and if this happens the tourism industry is a goner.

We really need to start thinking of the future and stop focussing on past events. We need to analyse past events and learn from them. Enough with this firefighting policy!

So you want an easy life; you want to make PHP forms as if you are working with access? It’s possible. There are loads of such programs available but the best I’ve seen is PHPmaker5.

How it works
To start with, you need to have your database ready (in MySQL for example). PHPMaker5 will connect to your database and get the tables you are using. For each of these tables, you can create a form (PHPMaker5 will make a form out of it) that will allow you to add data to your database – of course all databasse connection scripts will be created for you.
Exploring the software a bit more will allow you to create forms with one to many relationships (master-child) and combo boxes can even retreive from tables!

Favourite Features

  • It just works – it connects to your database and allows you to create forms just like that. In a few mins, you’ll have a decent application alive and kicking
  • Customization – the code generated is clear and it can be easily customized to cater for additional stuff. In addition to that, the CSS can be easily changed
  • It’s free – this amazing software is free. You only have to pay and register if you want support

If you don’t believe me, go to their site and you’ll see that PHPMaker5 has got no less than 21 awards! The only criticism I can make is that there’s no Linux version unfortunately.

Qt logo

Yesterday I decided to investigate Qt from Trolltech and get something working with it.

Very briefly, Qt is a library that allows you to create interfaces. Lots of programs use it (a lot of KDE programs do) and i’ve heard a lot of good things about it but alway thought naaa, this is too complicated. So yesterday i downloaded all the libraries of Qt4 (Qt4 is free for open-source development) and tired a tutorial and … it wouldn’t work – I got some error messages saying that it wouldn’t recognise some libraries (qapplication.h: No such file or directory)!

What the hell had I got wrong?
Actually I don’t know. I had installed most of the Qt4 stuff in adept I deemed necessary but it seems that I had not installed all Qt4 stuff (in my foolishness I tried removing some Qt3 stuff – somethin not to do – and it removed amarok as a result. Had to reinstall it).
After installing all (or most) of the Qt4 stuff it worked and I was really surprised as to how easy it is to create interface code.

qt adept

The best tutorial is I think on the Qt website.

Getting started

First of all get all (or most) of the Qt4 stuff in adpet installed.

Then type the following code that is available from tutorial 1:

 #include <QApplication>
#include <QPushButton>

int main(int argc, char *argv[])
{
QApplication app(argc, argv);

QPushButton hello("Hello world!");
hello.resize(100, 30);

hello.show();
return app.exec();
}

Then save the file as (for example) main.cpp.

Next at the prompt type:

$qmake -project (creates a .pro file)
$qmake (creates a platform specific makefile)
$make (calls the makefile and produce the exe)

Run the exe to get your first app working. It’s really easy.

Have Fun and Tranks Trolltech!