src2fm: Source code to FrameMaker

Last change: 24 Nov 1995

Description:

These programs take source code as input, and produce nicely formatted listings in FrameMaker. They do not indent source code. They do use typefaces, colors, etc. to make a listing easier to read. src2fm is a script that applies an appropriate filter (ada2mif, c2mif, csh2mif) for Ada83, Ada95, or Ansi C source code or C-shell scripts. All aspects of listing style are customizable by editing style sheets in a FrameMaker template document.

See also src2www for producing web documents, and alternatives - a list of FrameMaker filters maintained by Ed W.A. van Leeuwen.

Purpose:

src2fm can be used to prepare small portions of source code for inclusion in presentations, manuals, or technical papers, or it can be used to prepare listings of whole programs, with indices.

Index

  • Features and examples
  • Status of this release
  • Requirements - what you need to run ada2fm and c2fm
  • Availability - downloading source and binaries
  • Bugs and known problems in the current release
  • Plans for further development
  • Contacting the author

  • Features:

    Examples


    Status:

    Fairly stable, but with inadequate documentation. The Ada front end recognizes more constructs (e.g., type definitions) than the C front end. src2fm now accepts some restricted C++ code, but templates and other C++ features will confuse it. Comments on the output (for Ada) have been quite favorable.

    It is reasonably easy to add patterns for language extensions and local conventions, if you are familiar with (f)lex. Extending from Ada83 to Ada95 took about an hour, mainly for testing. On the other hand, syntactically messy languages like C take much longer.

    See also known problems.

    Requirements:

    ada2fm and c2fm run on the Unix operating system; they have been tested on Sun Sparcstations under SunOS (a BSDoid) and Solaris (a SysVoid), and should run under other Unix operating systems. I do not have resources to port src2fm to Mac, Windows/Dos, or other non-Unix platforms at this time.

    It is most convenient if you have the Unix version of FrameMaker. The provided scripts use the fmbatch utility to apply formatting templates automatically.

    If you do have a Unix machine, but you have only the Mac or Windows version of FrameMaker, you can still use src2fm (rather clumsily). You can generate MIF files on your Unix box and then transfer them to your personal computer.

    Hypertext index generation depends on features of FrameMaker version 4 (FrameMaker 5 also works), but other features will work with version 3 as well. The template I distribute is for FrameMaker 4; you'll need a MIF version for FrameMaker 3.


    Availability

    Full source code is available, optionally compiled for a Sun SparcStation. The current version is 0.9e, last changed 24 November 1995.

    Source only, approximately 125k.

    Note: These are compressed tar files. On a Unix system, the decompression is usually performed by your browser (Mosaic or Netscape); otherwise you can use Unix "uncompress" or FSF's "gunzip" utility. After decompression, you still have to untar them. This source code has not been prepared for dos/windows or mac environments, and I do not have resources to port to those platforms in the near future. (I will be happy to help if someone else wants to do the port.)

    Send mail to request a different version or configuration, or to request help.


    Bugs and problems


    Plans and wish list


    Contact me

    If you find this software useful, please drop me a note. If you try it and don't find it useful, please drop me a note to explain why. Please send email to michal@cs.uoregon.edu

    Thanks to the following people for making src2fm better through their constructive criticism, suggestions, bug reports, and fixes:
    Michal Young