Thursday, May 12, 2005

Tiny portable word processing with AbiWord on USB stick

AbiWord is widely known among Linux folks and open source aficionados. It is a free small and feature-rich word processor. Moreover, it is cross-platform and available for Linux, Windows, and MAC. A short, but interesting comparison to MS Word is available here.

I have given AbiWord a try (windows version) a couple of years earlier, but it did not work out for me at the time. The program was uninstalled in favor of OpenOffice.

Recently, though, I decided to assemble a bundle of lightweight applications that would be autonomous when launched from USB keydrive. I still have USB1.1 250Mb stick, therefore launch speed and small footprint are of major importance. I wanted the applications to be fast and stable (don't we all :)) and preferably not to leave any tracks on the guest system.

In my search I came across an interesting tutorial about USB-ing and after reading a nice related blog post here - decided to give AbiWord another try.

What a pleasant surprise that was! Fully functional word processor reading and writing both MS Word *.doc and OpenWriter *.sxw files, installed in just under 12 Mb on USB stick and launching within seconds!

Here is the deal: download the installer (current stable version 2.2.7), run it, select USB drive as installation target, chose "tiny" installation from the list, and uncheck "create desktop shortcuts" option. This gives you a bare bones installation, which is not exactly tiny, but still pretty good with 8.8Mb footprint. The editor supports quite a few text formats: native *.abw and compressed *.zabw, *.doc, *.rtf, *.txt, *.html, and *.mht. The *.doc support might be arguably sketchy, but for my purposes of fast portable app-ing it was just fine - I could perfectly read all the *.docs as well as write baseline documents in the *.doc format.
Note of caution though: in my experience it would not be a good idea to open large and complex MS Word documents with this AbiWord installation. In my case it took several minutes and a lot of system memory to open a 300+ page document. Embedded graphics probably will not show or will be distorted in some way, but that is pretty legit for a baseline installation. On another hand, AbiWord did not crash and did not corrupt the file.

For portability it is convenient to add a launch batch file in the root directory of your USB drive. MS windows shortcuts do not allow to use relative paths. Therefore as soon as you change machines, the USB drive could be assigned a different drive letter and the shortcut will not work (sometimes it does though, when a target machine rescans the drive and finds correct target directory, but it will cost you time). Just create the file e.g. abw.bat and add the following line there (given AbiWord is installed in the e.g. E:\abw\ directory, where E: is the USB drive):
abw\AbiWord\bin\AbiWord.exe

If this is all you need - you are done. Congratulations! It is still almost 9 megs installation, but it certainly beats 90.5Mb of John Haller's () excellent Portable OpenOffice, let alone trying to install MS office on USB drive :). Moreover, the startup time in my case was around 1m20secs for Portable OpenOffice and just a couple of seconds for the AbiWord. Do not forget - this is for USB1.1, therefore the loading speed is really important for my purpose.

In my case I wanted to read OpenOffice writer (*.sxw) files as well. Here things got complicated. There is a special installer for import / export plugins that requires some dependency libraries. If you install a specific plugin that requires the library without choosing the "download-a-library" option - then later your will get a "xyz.dll is not found" error message. An obvious overkill would be to download all the libraries from AbiWord web site (url) and extract all of them into the AbiWord working directory. I, however, wanted a minimal streamlined configuration. Actually in my case, the installer could not download any libraries at all since I was behind the firewall.

The solution was to let the installer (abiword-plugins-impexp-2.2.7.exe) run its course, but select only the needed plugin - OpenWriter *.sxw. Then after the installation you only need to copy required dlls into the abw\AbiWord\bin\ directory. You can download the required libraries individually:


Now you are done.

The plugin adds some overhead, but - hey - you are still at 11.8 Megs and now you have got yourself a VERY functional word processor, which is fast even on USB1.1 stick, AND reads and writes both *.doc and *.sxw files. Enjoy.