Usual warning: If you are not interested in computers you won’t find this post informative. If you are interested in computers, there is still a high probability of that. If you are a Wine user, you might be interested.
Before I switched to the new compiler to be able to use zkanji in a Unicode environment, the program worked with only smaller glitches under Wine. Unfortunately the switch brought forth some bugs that made the program freeze under Wine when it was started up. The bugs were not new, but for some reason the program compiled with the old compiler was not that sensitive to them. Non-programmers probably don’t know anything about “calling conventions”, but for those who do, this was for some reason changed between compiler versions, and even though I might have used the incorrect one for one of my functions, it worked fine before the switch. Unfortunately the bad calling convention caused zkanji to freeze under Wine, but also caused random errors on Windows as well.
I don’t know anything about how Wine handles the Windows registry, but it clearly doesn’t allow changing the autorun entries by default, and whenever the settings window was opened and closed, a friendly error message announced an error. I “solved” this bug by disabling the checkbox that is there to change whether zkanji runs automatically on system startup or not, whenever the corresponding entry was unreachable in the registry.
I was surprised that Japanese fonts were included with Wine, but because some fonts are hard-coded into the program (eg. the font for kana input boxes), those only showed up as boxes. I can’t understand why Wine doesn’t automatically map the default “MS Gothic” and “MS Mincho” fonts to their equivalents if they are not found in the system, but as it doesn’t, I had to find a workaround to this problem. First of all, if the default fonts are not found on the system, I select “VL Gothic” and “IPA Mincho” as a replacement, and the curiously called “Droid Sans Fallback” for non-Japanese fonts. If this fails, I can still select the first Japanese font I find. This way I can hopefully avoid problems with fonts in the future, but if that’s not the case, you can notify me about the problem.
Next step: Update Checking. After a long day of testing I found out, that the Unicode version of some winsock functions (mainly GetAddrInfoW) crashes the program running on Wine. It might also be responsible for a bug under XP, which doesn’t crash the program completely, but shows an error message on startup if automatic update checking is enabled (this is just a theory at the moment, but hopefully this is the cause). I don’t want to blame the creators of Wine (it’s an almost impossible feat they achieved by even writing something like that), and it might not be their fault that the Unicode winsocket simply doesn’t work, or maybe it works on almost every machine, but mine is an exception. But whatever the truth is, making a program that works perfectly under Wine is an art.
After yesterday’s release, let me announce zkanji v0.593. The only change is the reverted Update Checking to the non-Unicode implementation. This doesn’t change the functionality in any way, every Unicode improvements are still in the program. If you have already downloaded v0.591 and no error shows up on startup or when you are checking for updates, you don’t need to get the new version. (I haven’t uploaded this new version yet, but I will do it soon.)
I would like to ask the help of any Linux user out there who have Japanese support with SCIM on Linux. I have installed SCIM to be able to type Japanese (the default input method in KDE apparently only works with real Japanese keyboards…) and it worked fine until I decided to update my Firefox to the latest version. Now everything can get Japanese input, except Firefox. (I could write a few entries about my adventures with Linux, but I don’t want to offend anyone.)
Nothing can make me so neurotic as computers and technology, especially when it comes to Linux. (This is probably due to my complete ignorance towards that system, and I admit that it is all my fault, so please don’t get into a flame war here.) After hours of struggling with VirtualBox and Suse, I could finally try zkanji out with Wine. Emulating Windows under a Linux, that itself is emulated under Windows is probably not the best way to test a native Windows program’s compatibility, but this seemed to be the easiest way.
As it turned out, the previous version of zkanji (v0.577) was almost usable, but the latest one causes lots of access violations and crashes. This is probably due to switching to the new compiler and programming environment, and not as much to newly introduced bugs. I will try to fix everything I can, even though they don’t appear as bugs under the program’s native environment, but zkanji will still run under most popular operating systems (with emulation) if I can help it. This is not a promise though. I will simply try to work around the worst problems, but if I can’t get the job done, I will probably give up pretty fast.
Update: I could somehow fix the issue with Wine, so the next version should run fine with it again. What is more, I added some new fonts to be usable with the kana/kanji input boxes, so they won’t show characters as ugly boxes anymore on some systems that don’t have the defaults.