My First Perl Script AGAINST Kingword.

I’ve been loving C for so long and I decide to make some naughty change now. ;-)  I begin to learn Perl, which is designed to be practical (easy to use, efficient, complete) rather than beautiful (tiny, elegant, minimal), exactly opposite to C.  I learned Perl because:
  1. It’s beneficial to the project I’m working on.  My project heavily involves text manipulation, for which Perl was originally developed.
  2. It’s beneficial to a PM.  Perl is efficient at building demo code to show prototypes.

It’s Kingword that pushes me to start my Perl career from such a poor script, a script less than 10 lines.  Before I upgraded from Kingword2005 to Kingword2006, I exported (one feature of Kingword) my NewWord list to a txt file whose format is defined by Kingword2005.  Then, when I tried to import them back to the NewWordPad of Kingword2006, it failed because Kingword2006 can only import txt files in a new format newly defined by Kingword2006.  It feels like the government persuade me to trade my gold for the currency, but some day later, the government issues a new kind of currency and the one I hold can not be used any more.

So I decided to fight against Kingword, by writing a Perl script transforming the old format to the new one.  I did and it works well. :-)

Managing windows.

Here, I’m talking about managing windows, not Windows.  Managing windows under Windows XP.
 
windows distribution
I still remember the time when I coded day and night.  If I didn’t use an IDE, under X Window, I need one console for the editor, one console to compile and debug, one console to edit the config file, one console to generate the test data, one console to run smoke test and check the log……  Luckily, the desktop under X Window seems always big enough, since there are Virtual Desktop Managers available.  I can launch/drag different windows onto different virtual desktops and switch among them quickly using hotkeys.
 
The good news is that there are also similar solutions under Windows XP, while the bad news is that they are not as good.  The Virtual Desktop Manager in PowerToys suite, which should be half-official, sucks in usability.  As always said, if you don’t satisfy the customers, someone else will.  "Deskwin" is the one satisfying me.  It basically has all the features I expected except being able to configure the number of desktops.
 
windows placement
In windows, generally speaking, the window obtaining the focus (active) must be the one on top, while this is not necessarily true in X Window.  So when working under Windows XP, I often run into the boring situdation that I have to resize the windows and drag them around to avoid overlap, so that I can work on one window yet read information on another.
 
Today, I just discovered a considerate feature of Windows XP to help me out.  Try this:
  1. Choose several windows (say 3 windows) on the task bar, by holding the <Ctrl> key and clicking the window buttons.  Once a window is chosen, it appears pressed.
  2. Right click one of the window buttons you chose, choose "Tile Horizontally" or "Tile Vertically".
The windows I want to see are neatly placed by a few clicks.  This feature is important to me, yet I feel sorry that it takes me so long to discover it.  Maybe I’m stupid, but being stupid should not pevent me from discovering a well designed feature, if it’s really well designed.  "No stupid customers, but stupid design".