Forte finally released Agent 2.0, a complete rewrite of the IMHO best newsreader for the windows plattform. I’ve just downloaded (and registered – there’s a quite reasonable upgrade fee of $15) the new version and I’m going to have a look at it…
Category: Uncategorized
Programmers Font
When writing code here and then, you usually use a monospaced font for better alignment of the characters. The default in Windows is Courier New which is quite readable, but its characters are a bit wide.
My favourite so far has been Lucida Console which comes with Windows XP and maybe Microsoft Office. The fonts characters are a bit less wide than those in Courier New. This is my default-font in Putty as it’s very readable (for a monospaced font) and doesn’t use as much space as Courier does.
Somewhere on the web, I came across ProFont which is a modified version of Monaco, the mac users have as default monospaced font. ProFont is optimized to be used by programmers, can be set to a very small size (lots of code visible without scrolling) and is very very readable.
On the page you’ll find a bitmap and a truetype version. The latter looks quite badly on Windows XP with ClearType and the former doesn’t work in Java-Applications. Unfortunatly jEdit is indeed written in Java, so I have to use the TT variant.
Then again, Delphi and Putty are not written in Java, so I want to use the bitmap version.
Unfortunatly, it’s not possible to install both fonts at the same time as the are both named the same, so the TT version always wins.
My solution: I’ve opened the bitmap-font with a hex editor and changed all ocurrences of ProFontWindows to something else which finally allowed me to install both fonts at the same time.
Get the hacked version here. Note that I’ve only hacked the fontname. All its copyright belong to the author of the page above.
Omniweb 5
Last monday, OmniGroup has released the public BETA version of OmniWeb 5. The most interesting thing I’ve seen in it (I’m currently writing this entry using OmniWeb) is this text in the EULA:
IMPORTANT – Read this License Agreement carefully before clicking on the “Agree” button. By clicking on the “Agree” button, you agree to be bound by the terms of the License Agreement.
—The document that follows this paragraph is a license agreement. Why do we need such a thing? Well, to be perfectly honest, our lawyers have told us that we need to protect ourselves. We at The Omni Group pride ourselves on our low-key style, but the global nature of the software business means that one lawsuit from one user in a far-flung jurisdiction could put us out of business. It also means that, without this agreement, we might not have protection from people who misuse our software. We do not want to bet our entire company on such possibilities, however unlikely, because we like doing what we do and want to continue to be able to do it. And, so, we require you to read and agree to this license. We think you will find it quite reasonable. Obviously, if you disagree, click “Disagree.” But, don’t just stop there. Let us know. Send some e-mail to <info@omnigroup.com> telling us what you find unacceptable about our license agreement. We can’t promise to change anything, but we will do our best to get back to you.
Nice. It’s their style, so it does not really surprise me, but it’s nice anyway.
What I like is this tab-drawer. I’ve just seen that even the bookmark-window is displayed as a tab. Very nice. Very integrated.

In the stauts bar there are some Icons. I don’t really understand what they are doing and there’s no tooltip, but I’m sure, this will be fixed in a later release.
Very good-looking. I’m going to surf around a bit and will possibly post something more later on.
Just before hitting “submit”, I’ve seen this small plus-sign above the scroll bar on any <textarea>-element. This thing is just great. When you click on it, an extra window will open providing you with a nice large texteditor and the possibility to import any text file. Nice! Very Nice.
I think, I’m going to find a whole lot of nice little things as I continue trying the thing out.
dvdupgrades.ch
When I was looking for a new AV-receiver, I soon found out that my whishes cannot be pleased in common consumer-shops like Media Markt. I found my device by googling.
Where to get it? Although, I am one of those guys that like to go into a store and just take the stuff with me, this was not possible this time as said receiver is quite uncommon (newly on the market and quite expensive [but sounds very nice]), so buying online was my only way to get it.
Browsing around a bit finally lead to dvdupgrades.ch which has the most complicated user interface I’ve ever seen on a website (and runs only on IE as the JavaScript for the menues at the top is somewhat strange), but looked quite ok anyway.
They promised delivery somewhere around February, 10th, but the stuff was here already yesterday. They’ve worked fast and professional. Very nice.
If you live near switzerland and need exotic AV-stuffm especially modified consoles or DVD-players (region code, macrovision, … – they even wrote a new firmware for Pioneer Players from scratch), give them a shot!
Delphi, WinXP and Password Edits
I’m still into making Delphi apps look more “native” when run under Windows XP. Now that I got the IE-Control working, I was looking into the password-edit case.
The Problem: When using the standard way for creating password edits (Drop a TEdit on the Form and set the PasswordChar property to ° ), this may look and work on in Win 9x, NT and 2000, but under XP, some features are missing:
- In XP, password-edits cannot be read from other applications by sending the WM_GETTEXT message. Delphi’s TEdit can.
- In XP, the edits have a nice bullet instead of a * to mark the entered characters
- When CapsLock is active, a balloon-hint appears warning the user that maybe she is not doing what she expects
How to fix this?
Simple: Create a descendant of TEdit, override CreateParams and set the controls style to ES_PASSWORD. Provided you are supplying a valid Manifest for XP, you now have a fully fledged and nice working password-edit:
procedure TPasswordEdit.CreateParams(var Params: TCreateParams); begin inherited; Params.Style := Params.Style or ES_PASSWORD; end;
Oh. One thing is still missing: The dots look wrong. This is because Delphi does not use Windows’ standart font per default but overrides this with “MS Sans Serif” where “Tahoma” is the standard under XP. So Delphi-Apps generally look kind of foreign – even more so, when ClearType is enabled (MS Sans Serif is a bitmap font and cannot be antialiased).
This can be fixed by setting each forms DesktopFont property to true. Note that it’s a protected property, so it must me called from withing the form.
Now the bullets look right and the font’s in your application are proper anti-aliased (provided ParentFont is set to true in every component on the form).

Easier to use? Cheaper because of that? Dream on!
The Exchange Server I already had strange problems [read this and related postings there] with, today had another one of them. I had to give reading-permission to some public folder to some users (although the GUI to do that from within Outlook is really easy to use, some people rely on me doing that for them because that’s even easier).
The Exchange Server Manager threw a strange message at me whenever I tried to expand the folder-list in the tree. The text was useless as ever and nothing was posted to the event-logs – as ever. Why is there a logging-framework if it is not used? (besides, if it would have been used, the message would have been just as un-understandable as the one I was getting).
This time, I was lucky: I got an error number along with the message that was even known to the knowledgebase. The error was 80040e19 and the knowledgebase article was Q328659.
The problem was easy to fix and had something to do with some “security-tool” that got installed alongside the IIS-Lockdown tool which itself got installed alongside the common Windows-Update procedure. Nice to know that just updating the system via such an easy procedure can bring essential functions down without any warning.
Microsoft always emphasises the ease of use of their products and the better support you are getting when using their closed source solutions. Granted: The “ease of use”-thing can sometimes really be true (many things just work out-of-the box with not nearly as much work as I would have when using a common linux distribution), but when something does not work, fixing microsofts server software is much more difficult than fixing equivalent linux software as the fixes are un-obvious and the error messages are unusable.
The level of support for me is just the same as with comparable open-source software: Use google, enter the error message you get and pray someone had a fix for it posted somewhere. If not, I see virtually no solution in Microsoft land (besides paying a lot of money for support) whereas in the open-source land I would be able to fix the problem sometime later as I have readable error-messages and if that does not help I could try to understand the problem by reading the sourcecode.
That’s why I usually prefer open solutions. Or have you ever seen software working flawlessly?
Double double dash
This is what I’ve ever wanted to do, but I have neither enough room, nor enough friends willing to participate nor enough equipement. Maybe later…
Keyboard review
This review of logitechs diNovo wireless desktop was slashdotted today. I wonder why the reviewer does not say anything about the stupid size of the delete key which actually spans both rows of this 2 by three row with the page-up/down, home and end keys. Insert is where you exspect scroll-lock to be which is missing.
You can’t believe how many times I mass-deleted some files in Total Commander instad of just marking them.
Then again, maybe this layout will be the new “standard”: Looking at the other reviewed desktops, the one from Microsoft also has this layout and because of the slashdot-effect I cannot check out the others.
By the way: Besides this delete-problem, the diNovo is the best keyboard I ever had so far: Great typing-feeling, great design and good access-technology (it you can live with this)
Java and native libraries
As you may know, I am working with barcode scanners – actually it’s all about my companies product PopScan which is a software-tool for accessing a nice little barcode scanner which is essentially a barcode scanner and nothing more and thus quite inexpensive.
We have two similar products: One is the enterprise version which is sort of a framework for implementing custom made barcode solutions. Two quite big companies here in Switzerland are already using it (just visit PopScan’s webpage to learn more, I won’t make any more sales-pitches here).
The other product – PopScan SMB – is a out-of-the-box solution for small and medium businesses which allows them to provide a easy to use barcode ordering system to their customers (ok. now I’m really finished sales-pitching. I’m coming to the technical aspects…)
PopScan SMB is largely webbased: On the client side we have a very little application that does nothing but hanging there and wait for a scanner to be connected. When that happens, it reads the scanned codes and displays (using the IE ActiveX control) the webpage with the filled shoppingcart – very nice and simple.
The drawback so far was that we could only support Windows with this solution (written in Delphi – but as a reader of this blog, you may know that already). The point is that we got quite some requests to get this to work on the Mac and additionally we have some ideas involving Linux….
As I wanted to learn Java for quite some time now, I deceided to rework the thing as a Java-Thing (Applet, Webstart, see below).
The first Problem was accessing the serial port where the scanner is connected to. Possible? Yes. Sun has created a specification for accessing serial and paralell ports and provided a sample implementation for Windows and Solaris.
If you want support for all the other OSes and if you want a solution that is acutally working, I propose, you have a look at the library from SerialIO which is what I’m using. Works like a charm and is definitely worth the money.
Next problem: How do we install the thing on the clients and how do we keep it upgraded? Two solutions come to my mind:
- Java WebStart: Just put a JNLP-File somewhere on your server and link to it. The browser downloads it and Java WebStart does the rest, meaning installing and keeping the software updated. The big advantage: The mechanism has explicit support for native libraries (what this blog entry is about) and works quite nicely. The disadvantages: 1) I’m not sure whether java.net.URLConnection does use appropriate preconfigured proxy servers which is a requirement for the solution to be usable (quite a lot of our possible customers have quite strict firewalls and forced proxies) and 2) it does not work on Mac OS < X which has only Java 1.1
- Java Applet: Put it on a wepage which the user opens and that’s it. No installation necessary, Proxy-Support, Java 1.1 support – you name it. The optimal solution if there were not that small little problem: No support for native libraries (which I have to install to access the serial port). Anyhow: The applet is what I did
(actually there is a third solution: Create a “normal” application and a platform-specific installer and let the user install and run it. This would work, but would force me to again create a special auto-update-mechanism and it would require quite a lot of user-intervention.
So it all can be broken down to the one question: How to handle native libraries with Java-Applets?`
The answer is as simple as the question:
- Write your code
- When the library is accessed for the first time and can’t be loaded, a java.lang.UnsatisfiedLinkError is thrown. Catch it and…
- … download the required libraries to the local computer into the correct directory
- Tell the user to restart the browser
Of course your applet has to be signed for this to work, but this can be done quite nicely in a Ant-Task.
Where to download the file to?
Into some directory in java.library.path, where each platform has its preferred location (which is – by the way not what the SerialIO-Documentation suggests):
<table border=0>
Windows {java.home}/bin OS X (Java 1.3) somewhere under /System which is bad OS X (Java 1.4) ~/Library/Java/Extensions (I must check OS 9 later)
Safari uses Java 1.4, where both IE and Mozilla (Camino, Firebird and Mozilla itself) use 1.3.
The problem with MacOS’es 1.3 library path is that it’s never writable by the user currently logged in (not even she’s in the admin group). To put a file there within the Finder, you must authenticate yourself as super-user (which calls sudo somewhere under the hood) which is not possible from within java.
The solution: The current directory “.” is also in java.library.path. On Richards mac, . pointed to the root of the harddrive “Macintosh HD” (/), which is writable by users of the admin group. So for now installing the library under “.” when using the 1.3 VM does work as long as the current user is an administrator, which is the same requirement like under windows and can be explained somewhere in the handbook or on the webpage. Problem solved (Safari users have the advantage of being able to use the applet even without the admin installing the native library first as a directory in the users homedir is in the library path in 1.4)
I really searched the web before writing this entry and I’ve not found anything about applets and native libraries (especially not under Mac OS). Maybe there is a simpler way to do what I am doing. I’d be glad to hear from you!
Fun with Logitech
I recently bought the diNovo Media Desktop from Logitech: I really liked it’s design and the bluetooth-support as this is the only really usable way for wireless equipement (no problems with multiple devices per room, encryption, … you name it)
The problem was: The driver on the CD-ROM installed just another Widcomm Bluetooth-stack which despite being the same piece (down to the version) of software that was installed with my think pad’s internal bluetooth-adaptor (you will have to update to version 1.4 on IBM’s webpage to use the HID-profile), was not compatible with the prior Widcomm-Software (which is a political/legal problem and has no technical reasons at all).
So, when using the diNovo-drivers, the internal bluetooth-adaptor does not work (too bad when trying to use your cellphone to connect to the internet when other means of connectivity are not availabe), and when not using them, I cannot configure the special keys and the media-player support (which is stupid anyway as it does not support Winamp).
My final solution was to revert back to only IBM’s internal driver and pair the logitech devices whith that one (hint: the mouse uses the key 0000). Installing set point which would work perfectly well with IBM’s BT-stack (as it’s the same as logitechs), was not possible beacuse the logitech BT adaptor could not be found. Ergo: No media keys, but at least a really nice keyboard and mouse together with a working BT-support.
Talk about BT-interoperability…
I really look forward to the Windows-integrated BT-stack (which probably will be the widcomm one too – just look at the stack of Windows Mobile 2003)