On 29-12-2009 12:03, Erik Margraf wrote:
Hello all, I wanted to typeset some Python code and stumbled across the pretty printing feature of ConTeXt. So far, I think I've learned the following:
-- There's no pretty printer for python. Neither in MKII nor in MKIV -- The wiki has an example implementation for a python pretty printer for MKII, i guess.
I decided to play a little bit with pretty printing (maybe implement a Python pretty printer on my own) and failed at the start ;-) I tried the following: -- Copied the filename pret-lua.lua to pret-py.lua -- Added a print statement to verify that the respective lua code (pret-lua.lua, pret-py.lua) is actually called. When I ran context on the file below, I could see that "pret-lua.lua" had been called, but "pret-py.lua" had not. I guess, I did wrong something very fundamental.
you need to post all relevant files luigi is the python expert here so i'm sure he'll figure out what's wrong Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------