Package python-module-logilab-mtconverter-0 :: Package 8 :: Package 4 :: Package transforms :: Module python
[frames] | no frames]

Module python

source code


Original code from active state recipe
        'Colorize Python source using the built-in tokenizer'

------------------------------------
     MoinMoin - Python Source Parser
------------------------------------

 This code is part of MoinMoin (http://moin.sourceforge.net/) and converts
 Python source code to HTML markup, rendering comments, keywords, operators,
 numeric and string literals in different colors.

 It shows how to use the built-in keyword, token and tokenize modules
 to scan Python source code and re-emit it with no changes to its
 original formatting (which is the hard part).

Classes
  Parser
Python Source Parser used to get HTML colored python source
  python_to_html
Colorize Python source files