From owner-help-octave at bevo dot che dot wisc dot edu Wed May 1 09:41:04 1996 Subject: LaTeX style for octave programs ? From: Jarle Brinchmann To: Ferdinand Schinagl Cc: "John W. Eaton" , help-octave@bevo.che.wisc.edu Date: Wed, 1 May 1996 15:35:56 +0100 John W. Eaton writes: > Ferdinand Schinagl wrote: > > : does anybody know about a style file for LaTeX to include octave > : programs and have them typeset in a nice fashionable way? > > I don't know of anything that will help with this in the short term, > but I have thought a little bit about how I might be able to modify > Octave to allow people to write add-on code to walk Octave's parse > trees and generate anything they want, given the information available > in the tree. I never got around answering this before, but the standard way to do this for any computer language is to use either lgrind of vgrind. I personally recommend lgrind, but it's not much of a difference. If you don't have it on your computer, you can get it on the CTAN machines (ie. http://www.tex.ac.uk/tex-archive/support/lgrind/ in England, change to www.dante.de in Germany and www.SHSU.edu in the US) This is a pretty printer that is general for a lot of different languages. The newest version of lgrind includes support for MATLAB, the clue is an entry in the lgrindef file that contains definitions for the language. There are also precompiled versions for PC/OS-2 available at the above site. Check it out! Jarle.