HTMLFormat Programmers Guide

This package converts from OutputForm, which is a hierarchical tree structure, to html which uses tags arranged in a hierarchical tree structure. So the package converts from one tree (graph) structure to another.

This conversion is done in two stages using an intermediate Tree String structure. This Tree String structure represents HTML where:

This is created by traversing OutputForm while building up the Tree String structure.

The second stage is to convert the Tree Structure to text. All text output is done using:


I have not produced and output to String as I don't know a way to append to a long string efficiently and I don't know how to insert carriage-returns into a String.

Future Developments

There would be some benefits in creating a XMLFormat category which would contain common elements for all xml formatted outputs such as HTMLFormat, MathMLFormat, SVGFormat and X3DFormat. However programming effort might be better spent creating a version of OutputForm which has better syntax information.

metadata block
see also:
Correspondence about this page

Book Shop - Further reading.

Where I can, I have put links to Amazon for books that are relevant to the subject, click on the appropriate country flag to get more details of the book or to buy it from them.

flag flag flag flag flag flag Axiom Volume 1: Tutorial. Documentation is freely availible from:


This site may have errors. Don't use for critical systems.

Copyright (c) 1998-2021 Martin John Baker - All rights reserved - privacy policy.