*****************************************************************************
******these are the INSTALLation hints for tmview v96.05*********************
*****************************************************************************


Part 1:  linux/svgalib
Part 2:  OS2/PM (experimental)
Part 3:  linux/X (experimantal)

*****************************************************************************
******linux/svgalib**********************************************************
*****************************************************************************

To install tmview on a linux/svgalib system you may follow the steps ...


1. Get svgalib running.

   For the case your svgalib supports standard-vga only, you may want
   to use the 640x480x16 mode. For that case use the compile-time
   option "MECK". This option makes tmview use the mentioned mode only,
   so the -d command-line option will be ignored. It also makes tmview
   a bit slow. So do use "MECK" only if neccersary. See below about
   compiling tmview.

   Since tmview normaly uses 256-color-modes only, and since you want
   more than a 320x200-pixel screen, standard vga won't be very
   usefull. There is a program called vgatest which comes with
   svgalib. It tells you, which modi are available on your system. Make
   sure, that your favorite 256-color-mode works. To make tmview use
   that mode, set the variable $GSVGAMODE or use the
   command-line-option '-dXxY' where X is the width and Y the hight,
   both in pixels. 
   
   NOTE: higher resolutions result in slower viewing. So even if I'm 
   proud off 1024x768x256 running on my old fashioned 14"-screen-
   386SX-machine, it does not make much sence to use this mode with tmview.


2. Use the precompiled binary dvisvga.ELF  

   To do so, just copy the precompiled ./tmview/dvisvga.ELF to a suitable
   directory, that is /usr/bin or /usr/local/bin by my opinion. Since the
   binary is in ELF-format it won't run on a.out systems. So on those systems
   recompiling is neccersary (see step 3.) !
   
   Take some dvi-file and enjoy.  To be sure, try with the '-d320x200' option
   first, which uses only standard (no super) vga capabilities. If you get
   warnings about wrong lib-versions, you have to compile tmview at your site,
   to get linked to your dlls. See step 3. for how to compile tmview. You may
   now find the command-line-options of tmview to go with your TeX-setup,
   i.e. pk-file naming, pk-file-paths and tfm-file-paths. Since tmview saves
   any options to a startup-file (default "~/.dvisvga") just play along until
   you are satisfied, then set the startup-file to read-only and/or copy it
   to somewhere save. See README for details. To be shure, you may want to
   edit the defaults in ./tmview/linux/defsx.h and recompile.


3. Compiling tmview.  

   All compile-time-options can be found in ./tmview/linux/defxs.h. But be
   careful, only change those which are marked therefore. There are some
   options in defsx.h which make tmview going with linux/svgalib in general, so
   they must not be changed.  To compile, copy the file ./tmview/MakeLinux to
   ./tmview/Makefile, make ./tmview the current directory and run 'make'. This
   should result in a new executable binary ./tmview/dvisvga. Like with any
   other program using svgalib, the superuser flag has to be set. The 'make'
   will try to do this for you, so you have to be 'root' at compile-time.




*****************************************************************************
******OS2/PM*****************************************************************
*****************************************************************************


The OS2/PM part of tmview is something less than 'beta'. While the precompiled
executable crashes seldom, the port to the PM is a mess. The OS2/PM stuff is 
just contained for completeness. It may become more usefull at the time I 
implement options not contained in E.Mattes dvipm. What do you think about 
searching with regular expressions and using hyper-links?

 
To install tmview on a OS2/PM system you may follow the steps ...

1. Get emx running.  

   tmview uses the emx-package from E.Mattes (who has writen the nice dvipm,
   well integrated in the OS2/PM environment). If you want to compile
   tmview, you will need the gcc-stuff too. Otherwise the runtime-library
   will do. See the READMEs and DOCs of emx. I did use emx09a and I don't
   know, if tmview goes with earlier versions, cause I did not try.
   The same is about the version of OS2, where only Warp is tested.


2. Use the precompiled binary dvilbfpm.exe

   Find siutable values for the comandline-option. See the ./tmview/README.
   When specifying path-lists for either the -f or the -t option, use
     '\'  backslash to separate directorynames
     'X:' to specify a drive, here X 
     ';'  to separate multiple paths.
   Example:
     -f.\;C:\TEXFONTS\PIXEL.LJ\;
   Recursive directory-scanning does not work for the OS2/PM version of tmview,
   since there is no need for such.
   
   The -d option sets the startup-window-size.

   When running dvilbfpm.exe, be shure to pipe the stdout in a file. Otherwise
   any errormessages will be lost. 
   Example:
     dvilbfpm mydvi.dvi > protocol
   If something goes wrong, take a look at that file (here 'protocol').

   Let a short batch-file do this all for you. 
   

3. Compiling tmview.  
   
   There should be no reason for recompiling, beside you want to do
   major changes, bugfixes or such. For that case you will know
   about the dmake utilitie. Look at the .\tmview\MakeOS2 and
   run dmake on it. Any other make should do too. You will need the
   emx installed, incl. gcc et al. Further the gnu regex library
   is needed. While this is contained in emx09a for cpp, I did not 
   notice a version for ordinary c. I took the files regex.h and
   regex.c from a gnu-CD.  Visiting the file MakeOS2 you will think of
   me not to know too much about makefiles. Clean things up, and send
   me a copy. Thanks.

   Good luck.


*****************************************************************************
******Linux/X****************************************************************
*****************************************************************************


I just found a book about Xlib and played along ... the only possible reason
for you to use tmview with X (instead of xdvi) is "searching with regular
expressions", "setting bookmarks" and such. Do not even think about tmview,
if you are using eps pictures and other postscript stuff. Do not try to
get tmview running under X on a Unix which is not Linux/XFree, unless you are
an expert. If so, let me know and send your patches for a true X support
of tmview.

 
To install tmview on a Linux/X system you may follow the steps ...



1. Compiling tmview.  
   

   Most compile-time-options can be found in ./tmview/linux/defslx.h. But be
   careful, only change those which are marked therefore. There are some
   options in defsx.h which make tmview going with Linux/XFree in general, so
   they must not be changed.  To compile, copy the file ./tmview/MakeLX to
   ./tmview/Makefile, make ./tmview the current directory and run 'make'. This
   should result in a new executable binary ./tmview/dvilx. 


   Note: tmview runs fine, if the depth of your screen is known at 
   compiletime.  Because of my poor equipment (linux on a pc, no fancy 
   X-terminals) this is only tested for 8bit and 16bit screens. 
   See the file ./tmview/lX/writelx.c to set things up for your needs. 
   To watch the what's going on, when tmview tries to find its way to the 
   XServer, setting up colors, asking for fonts and so, set DEBUGX in 
   writelx.c .

      
2. Running tmview  

   Take some dvi-file and enjoy ... for the case it shows up a window at all.
   This will be on the default display/screen, set in the environmente 
   variable DISPLAY. Sorry, for not having a commandline option. This will 
   be done soon.

   If you don't get a tmview-window, use the DEBUGX option in 
   ./tmview/lX/writelx.c (see step 1.) .
   
   The following resources are asked by tmview:

   DviLX.geometry:      standard geometry, f.e. 600x300+10+20
   DviLX.foreground:	dvi foreground, f.e. black
   DviLX.background:	dvi backgrounf, f.e. white
   DviLX.sforeground:	statusline foreground, f.e. tomato4
   DviLX.sbackground:	statusline background, f.e. OldLace
   DviLX.sfont:		statusline font, f.e.
                        -b&h-lucidatypewriter-medium-*-*-*-14-*-*-*-*-*-*-*

   Note: The sfont should be a fixed-width-font.
   
   The file ./tmview/lX/DviLX is an example for tmview app-defaults. 



*******************************************************************************
End of INSTALL*****************************************************************




