Monday, October 20, 2008

gHotkey


This is a little Python program I wrote. It lets you set the 12 Metacity (the gnome window manager) hotkeys for the applications you like.
Set any command you like in the left entry field of a row and the corresponding hotkey in the right entryfield.
The format for the hotkeys looks like "<Control>a" or "<Shift><Alt>F1".
The parser is fairly liberal and allows lower or upper case, and also abbreviations such as "<Ctl>" and "<Ctrl>". If you set the option to the special string "disabled", then there will be no keybinding for this action.
Download

Wednesday, October 15, 2008

How To Learn Programming And Which Programming Language To Choose?

In this Article I want to comment on how I tried to learn programming and which mistakes I made.

To clarify things, I am not a top notch programmer that could roll out a new operating system in a few days or nights. I can do some Web programming and have the knowledge to write plug ins, text processing programs and little GUIs.
I did some mistakes in my path to learn programming and think I got some insights about it on the way. On the other hand I think it could be interesting for an aspiring programmer to listen to some experiences from an average guy and not only to tips from top Open Source contributors.

Mistakes I made


  1. C as first language

    Of course like every kid, I wanted to learn some game programming. At that time everybody was saying: For game programming you need C. I tried C and failed.
  2. Use Wing Commander as my first project :)

    As I said before, I wanted to do game programming and i was inspired by the games I played at the time. Of course I never produced something usable.
  3. Not focused enough

    I was never committed to one project. I was changing my ideas of what to learn all the time.

What I learned on the way


  1. Use a scripting language to learn programming

    I strongly recommend to use a scripting language to learn programming, this means Python, Ruby, PHP, Perl and JavaScript. The big advantage of scripting languages is that you get instant results. Type in:

    print "Hello World"

    and you have your important Hello World program. If you compare that to a Hello World in Java:

    class HalloWorld {

    public static void main(String[] args) {

    String message="Hallo World!";

    System.out.println(message);
    }
    }


    and you know what I mean. Java frustrated even a lot of my fellow students in an MBA program.
    I personally would recommend you Python as your first language, it has a very clear syntax and I lets you do a lot of things from GUI to Web programming.
    If you just want to do some web programming maybe PHP or JavaScript are best for you (remember the instant results).
    Later you could learn Scheme/Lisp, it teaches you a different kind of thinking and should make you a better programmer. Therefore it is often used by college level "Introduction To Programming" books. After that, if you grasped the basic concepts of programming, you should learn C, because it is the mother of your operating system that every good programmer should know. From that time on you learned enough to decide what language/technology is next.

  2. Learn with a small project


    This should be obvious, but I did wrong. That's why I mention it. If you want to see instant results I think simple web programming is easy and rewarding.

  3. Concentrate on one project at a time


    Don't start several projects simultaneously. The result will be that you don't finish any.


I hope my advice will help somebody on her path to learn programming and helps you to stay motivated. If anybody has comments on this, I would love to hear them.