Found and reported a small bug with localization of Licq

Licq bug

I have found and reported (via #licq@freenode to emostar) a small bug with localization of Licq. Not all fields on the tooltip are using the localization. The translated strings are surely available, because one can see them on the similar fields. Probably, this is reproducable with any other language.

Licq version 1.3.0 built from sources today.

Update (2005/01/07 05:24): Posted to Licq bug tracker here.

On smartphones in general and Motorolla A780 in particular

Via this post in Hazard’s blog I found this reivew of Motorolla A780.

It looks like Motrolla A780 is indeed a decent smartphone. If I was to buy my first smartphone, Motorolla A780 would be a perfect choice for me (nevermind the fact that I still cannot buy it anywhere). But, I already had my first smartphone – Sony Ericsson P800. Getting and using one for more than a year slightly altered my requirements list. Things that I care about now are:

  • FM Radio. It turns out I can spend a lot of time listening to FM radio rather than to silence or mp3s on the memory card. MP3s eat up a lot of space, and listening to them eats battery like a car with no petrol. FM radio reciever must be built-in into my next smartphone. It is a good option anyway, since it is cheap and small, but with a lot of use for many people. It seems that Motorolla A780 does not provide it.
  • Recoding and playback of voice calls. I never thought that I would want this feature in the first place, but in the course of the last two years I foud myself in the situation where I badly needed it more than once. Luckily, Motorolla A780 has it.
  • CompactFlash memory. Although I am yet to see any good phone with CompactFlash, I still want it. CompactFlash is the best memory option for a smartphone I can see out there. It is cheap. It is open. And it is huge. CompactFlash cards and microdrives are in the GByte area already and not only that, but they are relatively cheap too. Memory Stick Pro 1 GB is roghly 3 times more expensive than a 1 GB Compact Flash card.
  • High level of integration in PIM. Personal Information Manager is an important part of the smartphone. I, therefor, expect it to be properly done. Sony Ericsson P800 has an average one. It provides all the important functions for calendaring, addressbook keeping, TODOs and notes. What it lacks is a good integration between this parts. For example, when I creat an appointment or a reminder for a phone call in the calendar, I cannot use contacts from the addressbook. I have to retype everything. Similarly, I cannot attach notes from the notepad to the contacts in the addressbook. Addressbook allows one to type in a single note for the contact but that’s it. I cannot attach any graphics (like a map of how to find someone’s house) except for one single photograph. P800 has a photocamera, but I cannot organize my photos properly with contacts or notes attached to them. All of these require user to dump all data to the computer and do all the organization there. Bad. Unfortunately, I don’t know how good Motorolla A780 in this regard. But in the worst case scenario, I guess, the same solution as for P800 will work – install a third party organizer.
  • GPS. Global Positioning System allows one to always know exactly where he is. Not only that, but it can provide this information to all sorts of software. When taking pictures, location coordinates might be saved into the image. This way you will always know where you took the picture. Alarms and reminders can use the coordinates to go off only when you are in the area. Coordinates can be used with a number of mapping services to suggest a better route through the city or to help you find your way back to civilization. Or to the nearest petrol station. Or hotel. Or good restaurant.

One of the things that I have noticed in the review is that Motorolla A780 does allow you to have both a ringtone and a vibrating alert. This is really odd and I don’t see any reason of why did they make it like this. I hope they will fix the behavior in the next generation of this phone.

One thing that I stopped worrying about is battery life. If the phone can live one a single battery through the day, I am satisfied enough. I realized that there is no way that I will find myself away from power for longer than a day. As long as the device can be recharged from a socket, or a car, or a USB of a computer, it is good enough for me.

Kopete saga

I have spent a good part of today trying to configure Kopete to my likings. Kopete is an instant messaging client that supports a number of protocols – ICQ, IRC, Yahoo, MSN, Jabber, and others. It is also integrated into KDE, which I am using for a few years now.

Out of all the IM protocols I mainly use only two – ICQ and IRC, and have a registered account in another one – Yahoo. Before my today’s saga with Kopete I was using Licq for ICQ and XChat for IRC. Both of these programs work fine, but lack any serious integration with KDE. So I decided to try Kopete 0.9.1, the one that was shipped with updates for my distribution – Fedora Linux Core 3.

So, I fired up Kopete and configured my ICQ, Yahoo, and IRC accounts. Account configuration dialog is pretty straight forward so this part was fast and easy. The moment I asked Kopete to change status of all accounts to ‘Online’ I found the first problem. IRC account couldn’t connect to the server. It was repeating that I was ‘marked as Offline’. Fortunately, I knew about this problem which was related to small socket timeouts settings. To fix this problem, start kcontrol, select Internet & Network menu and click on Preferences. There you will find four timeout settings: Socket read, Proxy connect, Server connect, and Server response. Probably you need only the Server connect option, but I went as far as increased all four of them to the value of 1800 seconds. After that my IRC account started working just fine.

Now I was ‘Online’ with all three accounts. It was time to look closer at what I get. Immideately I found the second problem. My ICQ contact list wasn’t syncronized with the server. I searched the web for a bit and browsed through all the menu items, but for no avail. I have about 30 people in my contact list and I almost thought of importing them manually. Not with my hands, of course, but with a script which could read Licq format (a bunch of plain text files) and write Kopete format (XML file). But the problem is that I also use ICQ from my mobile sometimes and there is no way I can syncronize the ICQ contacts with that device. Also, why should I do it when it is supported by the protocl itself? Anyway, I decided to deal with this later and imported about 5 contacts by hand just to play with Kopete.

I sent a few messages in Englinsh to the friend of mine who was online and it was working just fine. Than I tried to use Russian with another friend of mine. Somehow, he could read my messages fine, but I was recceiving garbage when he was writing to me. I played with fonts and encodings a bit, but nothing helped. I decided to leave this out for some time and continued with other things.

While playing with encodings, I was also going online and offline back and forth. I also closed Kopete a few times. And there I go with another misbehavior. Kopete couldn’t determine the status of my ICQ contacts correctly, showing a small error icon near all of them and marking all of them as ‘Not Available’. That was bad. I messaged one of the contacts asking if he was available and he said that he was Online. I double checked it with Licq and indeed he was. A bug. A really bad one, driving the whole ICQ support to unusable.

Fine. I proceeded with IRC. IRC worked good, but I wanted to configure it to look and behave like I wanted it too. Basically, I wanted something very similar to what XChat offers. The XChat theme was shipped together with Kopete so I tried it. It was good but not perfect. I tried to play with colors, but it wasn’t enough. So I copied the XChat theme to Leonid and tried to Edit

At this time I was pretty disappointed with Kopete and there was only a small chance that I would continue to use it. The last thing that I tried to configure was notification management. What I tried to do is not to have any notifications for IRC, but have immidate focus switch and raised window for ICQ. That proved to be impossible. The best I could do is no notifications for IRC and a ‘New message’ ballon from the taskbar for ICQ.

That was enough. I closed Kopete, fired up Licq and XChat back again and decided that I will not touch Kopete for another couple of years, until it will get much better. Sad but true.

How To Write Unmaintainable Code

In many places Perl is called an unmaintainable language. People with brains know that you can write unmaintainable code in any programming language what-so-ever. People who are familiar with Perl know that it can be used to write the uglies code ever, or the most beautiful code ever.

Aside from Perl discussion, here is an excellent document that shows how to write totally unmaintainable code in Java. Most of the rules are generic enough to be applied to any language.

I just hope you will never, for the sake of the humanity, follow any of the rules described.