LGRIND(1) User Commands 1996-Aug-04 NAME LGrind - a source pretty printer for LaTeX DESCRIPTION This is an Amiga port of a Unix utility which makes pretty LaTeX documents of source code. Actually, it is a bit more than just a port since I have rewritten and redesigned parts of the code. DISTRIBUTION My predecessors handed it out for free to everyone, and I don't see why I shouldn't do the same. Use it or abuse it... AUTHORS Van Jacobson, Lawrence Berkeley Laboratory (based on vgrind by Dave Presotto & William Joy of UC Berkeley), the original written for TeX Jerry Leichter of Yale University, modifications for LaTeX. George V. Reilly of Brown University, renamed to lgrind Michael Piefel, Humboldt-University Of Berlin, for LaTeX. Henrik Wetterström, University of Växjö, for additions and Amiga port. The above people have nothing to do with my Amiga port. I just give them the full credit for the previous work. CHANGES * The ' character is now translated correctly. * Support for Ada added to lgrindefs. * Support for Java added to lgrindefs. * Support for O2C added to lgrindefs. * Support for Agda added to lgrindefs. * Added new LISP support since I didn't like the mlisp conversion table. * Better support for international characters (at least swedish ones :-) * Bug up when filenames contained the '_' character fixed. * Builtin help can now be shown by the -help argument and not just -?. This because the '?' is treated as a wildcard character in some Unix:s. REQUIREMENTS A LaTeX 2e document preparation system. Available at any CTAN archive, i.e. ftp.funet.fi/pub/TeX/CTAN Well, you can 'lgrind' your files without a LaTeX system installed, but you can't do very much with the LaTeX files alone... SUPPORTED LANGUAGES 68000 assembler Ada Agda asm68 assembler Bourne Shell C C++ CSH Fortran Icon ISP Java LDL Linda Lisp Metafont MLisp MODEL Modula-2 O2C Pascal Perl PostScript Prolog RATFOR Russell TeX VMS assembler Yacc It is quite easy to add more languages to the lgrindefs file if you need more languages. INSTALLATION Just copy the 'lgrindefs' description file to your S: directory and move the 'lgrind' executeable to a directory in your search path. Move the style files in the sty files to the appropriate location in your LaTeX installation. You could also do your personal additions/changes to the LaTeX prolog and epilog in the s/lgrindefs file, but for the common user will the default settings do just fine. USAGE lgrind [-i] [-l] infile -i Used if you want the result be intended for inclusion in another LaTeX document rather than a standalone document. Use "\lgrindfile{ outfile.tex }" in your LaTeX document to include a such file. -l Specifies which language to process the input fie as. If omitted will it process input file as a C source code. Currently known languages listed below: C -lc (default) C++ -lc++ or -lCC Pascal -lp Modula-2 -lm2 Fortran -lf RATFOR -lr Yacc -ly PostScript -lps Prolog -lprolog MLisp -lmlisp Icon -lI TeX -ltex Metafont -lmf Perl -lperl CSH -lcsh Bourne Shell -lsh assembler -lasm 68000 assembler -la68 asm68 -lasm68 VMS assembler -lvmsasm ISP -lisp LDL -lldl Linda -llinda MODEL -lm Russell -lrussell Java -ljava Agda -lagda Ada -lada O2C -lo2c Lisp -llisp -help Show usage. -d Use other than default langauge description file. -h
specifies text to go on the left side of every output page (default is none). -e process a LaTeX file for embedded code. -n don't boldface keywords. V2LG A filter command 'v2lg' was distributed with the lgrind archive. I haven't got any use for it, but include it if someone might need it. Filter a LaTeX file into an lgrind file. Convert \begin{verbatim}-\end{verbatim} pairs into %[ - %] pairs. Tabify the former verbatim environments. Convert \verb|stuff| into @stuff@. CONTACT ME henke@tufvan.hv.se or Procyon on IRC #amiga or #AmigaSWE. SEE ALSO man/lgrind.man and man/lgrindefs.man HISTORY 1996-Aug-04 Initial release 1996-Aug-11 Some people told me about mising style files (lgrind.sty and fancyheadings.sty) so I decided to make a new archive including these. The lgrindefs file was set to swedish babel, which created a problem for some. I don't think you will need any localized styling at all, so I removed this line from the lgrindefs file. However, it could be useful when you put LaTeX code into your source code. Thanks to everyone that told me about these problems. The documentation, doc/lgrind.ltx was renamed to doc/lgrind.dtx to fix a mistake of mine. Sorry for messing things up like this. The LaTeX system I use is a very complete one, and I forgot the importance of checking out what in included in a standard system and what is not. Won't happen again, promise. :-)