Index of /sandbox/html4trans

[ICO]NameLast modifiedSizeDescription

[DIR]Parent Directory  -  
[DIR]docs/22-Mar-2013 08:17 -  
[DIR]tools/22-Mar-2013 08:14 -  
[DIR]data/22-Mar-2013 08:14 -  
[TXT]html4trans.py22-Mar-2013 08:14 8.5K 

HTML writer for lightweight browsers

HTML writer for lightweight browsers

Author: Guenter Milde <>
Date: 2008-03-07



The HTML Writer module, docutils.writers.html4css1 produces XHTML compatible with the XHTML 1.0 specification. Correct rendering of the HTML produced depends on the CSS support of the browser. Browsers without full CSS support (lightweight browsers, older browsers, text-only browsers, help viewers) produce inferior results.

CSS is the state-of-the art technology for styling of html output and provides many advantages. However, correct rendering of HTML+CSS requires considerable resources in form of program code, memory space and computation time.

On older machines or in embedded devices this might pose a serious problem. Another example is a HTML help viewer of a program. It should start up fast ("immediately") and not take too much resources.

Editing and generating documentation with reStructuredText is possible with modest requirements on computer power. Viewing the result should be as well.


A separate HTML-transitional writer producing non-CSS based HTML.

The html4trans writer module subclasses the html4css1.HTMLTranslator and modifies it to remove the dependency on CSS browser support.

The output conforms to the XHTML version 1.0 Transitional DTD and contains enough formatting information to be viewed without a cascading style sheet by a lightweight html browser (e.g. Dillo or the console browser elinks).


Doing without CSS styling comes at a cost.



Place in the binary PATH and in the PYTHONPATH or in the working directory (from where you start


Similar to the standard rst2html front end: [options] [<source> [<destination>]]

The full usage text can be obtained with the --help option.