Gnome, the Gimp, ICE wm, Utilities

By Christoph Vogelbusch

Gnome runs in XFree86OS/2 on top of a window manager, similarly to the way in which the WPS runs on top of the PM in OS/2. It adds a whole new environment on to the window manager, which requires a lot of libraries based on Gtk, and also adds a lot of specific Gnome apps. Gnome can be used with all window managers, including those detailed here. Gnome has been ported by Platon Fomichev and Asbjørn Petterson.

Required files for Gnome
Simply unzip all these into the root of your XFree86OS/2 drive. These, at the moment, will not produce the same Gnome desktop that you get on Linux, but they provide the basic functionality for Gnome apps to be run.
 * GTK
 * Glib
 * Orbit
 * Gnome libs
 * Lib-XML
 * Shm dll
 * Zlib - note that other z.dll's may not work with Gnome or Gimp
 * TTFlib
 * Intl dll - note that newer versions will not work with Gnome or the Gimp
 * GIFlib
 * PNGlib
 * JPEGlib
 * Imlib

Optional files for Gnome
Other libraries, not required for Gnome itself but which will be required for some of the apps which you will be running on Gnome.
 * GDK-pixbuf - this is needed by xChat
 * Gnome docs - only for programmers
 * GTK engine - needed for GTK themes
 * lib panel - needed by xChat, and some other apps
 * Lesstif - needed for Mosaic (if you want that)

Applications for Gnome
This is only a selection - there are plenty of other apps available as well.
 * Gimp - extremely powerful and useful graphics app
 * Gnotepad - an HTML aware text editor
 * Gedit - Gnome text editor, fairly basic but useful
 * Gnapster
 * Electric Eyes - similar to PMView; can also set an image as your background
 * GTKSee - image and slide/show viewer
 * Gxedit - very versatile editor/IDE/email client/newsreader/file manager ...
 * ImageMagick - another powerful graphics manipulation app
 * Gnome utilities - a variety: calculator, colour selector, font selector, hex editor ...
 * Gnome Midnight Commander - a file manager/desktop (doesn't work on all systems)
 * X downloader - supports 'resume', 'reget'; needs gcc30m.dll

Again, you simply unzip these into the root of your XFree86OS/2 drive. You can then run them from an xterm. You can also add them to, for example, the ICE menu and run them with a single mouse click.

The Gimp
The Gimp is quite well known as being an extremely good graphics app, rivalling Photoshop in some ways. On OS/2, it runs very well under XFree86 and most window managers (the default TWM being an exception - don't use this for the Gimp). Installation is very simple and straightforward.

Required and Optional files for the Gimp
Other libs from the list for Gnome are also required: zlib, giflib, pnglib, jpeglib, intldll.
 * Gimp base files - required
 * Gimp data files - required; the rest below are optional
 * Gimp extra data files
 * Scanimage - there should be a newer version of this
 * Programming - only needed by programmers
 * Plug-in source
 * Gimp manual - in HTML, but the Gnome help browser is needed to read it

The manual and other info is also available at Gimp.org, in PDF format

Installation is simply a matter of unzipping everything into the root of your XFree86OS/2 drive, and then adding set emxopt=-c -n -h2048 to config.sys and rebooting. You can then start gimp***.exe from an xterm (where *** is the version number). This assumes of course that you have added :\xfree86\bin to your path, and :\xfree86\lib to your libpath, as mentioned in Installing XFree86OS/2.

Some of the frequent uses for the Gimp are: making bumpmapped and shadowed web titles, making transparent gifs, making 'collages' of superimposed images, altering various colour and brightness or contrast values, etc etc. The rest is down to the user's imagination.

Installing the Ice window manager

Installation is simplicity itself: get Icewm.zip and unzip into the root of your XFree86OS/2 drive. Add two .dll's: Intl.dll and xpm.dll. Edit xinitrc.cmd (x:\XFree86\lib\X11\xinit\xinitrc.cmd) and find these lines near the bottom: /* 'startx/min/n "Xterm 1" xterm -sb -geometry 80x50+494+51' */ /* 'startx/min/n "Xterm 2" xterm -sb -geometry 80x20+494-0' */ 'twm' EXIT and change the last lines to look like this: /*'twm'*/ 'icewm' EXIT This comments out 'twm' (so that you can easily use it again if you want) and activates 'icewm' as the window manager which will be invoked on 'startx'. Note that these are "C" style comments and you must use the trailing */ to close the comment.

Now when you invoke 'startx', you will boot XFree86 into Icewm. The default "look" is for Warp4 - if you want to change this or other aspects of Ice, then you need to edit the files in XFree86\lib\X11\icewm: these are 'menu', 'preferences', 'winoptions'. You will also find HTML documents starting in XFree86\doc\icewm.html.

The file 'preferences' contains the choice of "look" - it's obvious where to change this to another one if you want to. It also contains ShowXButton=1, which turns out to be the OS/2 'kill' button at the top right of each window. If you want to change the ugly red X at the top left, then you need to change the graphic: XFree86\lib\X11\icewm\taskbar\start.xpm to something else (or make one in the Gimp). You could try changing the default colours if you were really adventurous (don't forget to make a backup first). You will see at the bottom of this file the four default 'virtual desktops' - this is where you would add others or change the names of the existing ones, as you wish.

The file 'menu' is the main one to edit - this contains all the apps which will show in a list when you left-click on the desktop. At the top of this file you will find: menu Applications folder { menu Editors folder { and then various programme names. Add whatever you have installed, eg prog Gnotepad gnp gnp in the 'Editors folder', or prog ImageMagick display in the 'Graphics folder', or prog Mozilla mozilla mozilla in the 'Browsers folder'. And so on.

The file 'winoptions' is one I've never touched, but it looks as though you could set the default icons at the top left of each window with this, so that only those apps which are not mentioned in here would take the ugly red X as their default.

If you don't like the background set by default, then you could try some of the others in the bitmap directory in line 37 of xinitrc.cmd: 'xsetroot -bitmap 'xbitmapdir'\xos2', or you could just load an image into Electric Eyes - including those from your \OS2\bitmaps directory used for your OS/2 desktop - and set one to be your XFree86 desktop.

True Type Font Server
By default, XFree86 is unable to use true type fonts. This would be a severe limitation, as most people have these as the majority of their font collections, but there is a simple solution. Just grab xfsttos2.zip and unzip into the root of your XFree86OS/2 drive. The readme will tell you to use inetd to run this and serve fonts, but you will probably find it better to use the 'tt.cmd' to run it as a stand-alone server. (If that zip does not include 'tt.cmd' then get it here) Put 'tt.cmd' into x:\XFree86\bin and start it before starting any apps, such as the Gimp, which need to use true type fonts. You need to put the following line into your %etc%\services file: ffst 7103/tcp # TrueType X fontserver and also you will need a fonts.dir and a fonts.scale in your new true type directory. My two files are like this, both the same, and in fact this is Type1 'fonts.scale'. For whatever reason, the true type server works just fine with these, but this may not always be the case for all systems. If you do find that you need to include a genuine one, then each entry in the file is found by opening the relevant font in a text editor and finding the values at the beginning of the file. Just use this as a sample to guide you. Your new true type directory should go with the existing directories for other fonts, in: x:\XFree86\lib\Xll\fonts\truetype and should be filled up with your existing true type fonts.

Troubleshooting
The usual trouble you will encounter when installing any of these applications concerns incompatibilities between various versions of *dlls and the particular app calling functions from that *dll. In fact, this problem is one of the driving forces motivating the team which is now building UnixOS/2 as a successor to EMX.

If you try to start an app from an xterm and get the message FOO not found, where FOO can be anything like INTL, XM or GDKPIX to quote a few likely suspects, then this means that that particular .dll could not be found in your libpath. Check this with the GNU tool 'which', by issuing which -l foo at a CLI (again 'foo' is the name in the message), and the response will tell you the first instance of this dll in your libpath.

If you have the relevant dll but still get crashes, check your 'popuplog.os2' in the root of your boot drive (for this to be written, you need to have suppresspopups=d:\ (where 'd:\;' is your boot drive) in your 'config.sys'). You may then see messages similar to this: 09-10-2001 23:29:53 SYS2070 PID 0362 TID 0001 Slot 00af F:\XFREE86\LIB\X11\.GIMP-1.2\PLUG-INS\PNG.EXE PNG->Z.42 This means that the PNG plug-in being used by the Gimp is relying on a call to z.dll which fails, due to this particular version of z.dll using an ordinal (42) for a particular function which does not correspond to the same function in png.exe. The solution is to dump that version of z.dll and replace it with the correct version. Do the same for other dll's which appear in this kind of error message.