ew (Examine Wad) v1.02 by Tormod Tjaberg (tormod@sn.no)

ew is free software, distributed under the terms of the
GNU General Public License. ew comes with no warranty at
all. For details see the file COPYING.

This file is written by Hans Peter Verne. It describes 
the UNIX peculiarities of ew.

unix
====

UNIX is a trademark owned by somebody, but is here used about
anything that feels, smells or looks like unix, such as linux. 
So sue me!

ew
==

Read the file ew.txt for general information about ew. It mostly 
applies except where it doesn't :-).  This file tries to describe
the discrepancies.

ini file
========

On unixes, you don't want to use ini files lurking around in $PATH.
So the ini file is only searched for in your home directory, $HOME.
Tormod insisted on calling the ini file "ew.ini" (DOS would choke
on a filename like ".ewini"), but accepted the preprocessor 
#define DOT_INI to assume the file is called ".ewini"
instead (see "compiling ew"). I recommend you use this.

Copy the ew.ini to your home directory (as .ewini if you prefer),
and edit it. You must most certainly change the entries, there
are some comments there suggesting what to use under linux:

  WAV play %s

"play" is simply the sound conversion utility sox under a different name, 
it will dump the sound on /dev/dsp. You can find sox or other wav-players
at your favourite linux archive, such as ftp://sunsite.unc.edu/pub/Linux/ 
or a mirror (look in apps/sound/convert/ or apps/sound/players/)
If you don't have a soundcard you can take a look at 
ftp://ftp.informatik.hu-berlin.de/pub/os/linux/hu-sound/

  MUS qmus2mid %s tmp.mid -nodisp ; xplaymidi tmp.mid ; rm tmp.mid 

I know of no native mus-player for linux. qmus2mid is a utility for 
(surprise!) converting musfiles to midi. Then, playmidi (or xplaymidi) 
can play the midi-file, which is finally deleted. This actually goes 
reasonably quick. You can get playmidi from sunsite or mirrors, look in 
apps/sound/midi. qmus2mid is originally a dos-program, ported to unix 
by yours sincerely. If you can't find it on sunsite/mirrors or 
ftp.cdrom.com email me at hpv@kjemi.uio.no.

  PCX xv %s

xv comes with most linux distributions I believe, but it is unreasonably 
slow to spawn xv for every single image. I suppose there are some 
viewers for svgalib out there that may be quicker?

using ew
========

The keystroke handling in the unix version of ew is done by curses
or ncurses, and is quite a bit of ad-hockery. It leaves a lot to
be desired. For starters, the keys End, PageUp, etc. are received as
escape sequences, and simply exits the program (ouch!). Feel free 
to fix this! The arrow keys work for me, and you can use the numbers
(perhaps on your nummeric keypad) as Home, End, etc. 

compiling ew
============

There are five defines:

MS_DOS - this is actually the default if nothing is defined
UNIX   - uses curses/ncurses for screen navigation
NCURSE - uses ncurses under UNIX, no effect under MS_DOS
CURSE  - uses curses under UNIX, no effect under MS_DOS
DOT_INI- The ini file name becomes: ".ewini" instead
         of "ew.ini", no effect under MS_DOS

ew has been tested with the following UNIX compilers:

gcc on a Linux box, DEC and an Alpha

ew currently only works on litte-endian machines (i86, alpha,...). 
If you compile it on a big-endian machine it will exit with a fitting
remark when you run it.

If the int is anything but 32 bits on your machine you have to change
the typedef's of Int4 and Uint4 accordingly. (Please remember that
a long on the alpha is 64 bits) 

I use the following command to compile on my linux bux (slackware 3.0) :

  gcc -o ew ew.c -DUNIX -DDOT_INI -DNCURSE -I/usr/include/ncurses -lncurses

And on the alpha :

  gcc -o ew ew.c -DUNIX -DDOT_INI -DCURSE -lcurses

You may have to fiddle a bit to find the right include-files and libraries.
Check out the -I, -L and -l options on your compiler.  But don't complain
to me if you can't fix it, I certainly can't either!

Have fun,
--
Hans Peter Verne ( hpv@kjemi.uio.no )












