Hi Drew, Thanks for taking the time to read some of the WHIFF docs and for commenting. You bring up a lot of points many of which indicate that the documentation is confusing and unclear in many places and I will try to address that in the documentation and by renaming some components.
You are also correct that I'm not entirely sure that other solutions wouldn't work just as well or better. This may be because of my ignorance or because I found *their* docs confusing and unclear. Let's take one example you mention: On Apr 23, 8:21 pm, Drew Smathers <[email protected]> wrote: > There's nothing special about being able to use pygments. I can use > pygments easily in any python web framework. You haven't convinced me > that WHIFF makes this easier somehow. Please consider the following whiff test page (simplified) which formats python code using pygments inside an html document: 1 {{env whiff.content_type: "text/html", 2 whiff.filter: false 3 /}} 4 5 <html> 6 <head> 7 <title>pygments test</title> 8 <style> 9 {{use-url "whiff_middleware/pygmentsCss"/}} 10 </style> 11 </head> 12 <body> 13 14 <h1>Some colorized python code</h1> 15 16 {{use-url "whiff_middleware/pygmentsColorize" pygmentsCss.lexer: "python"}} 17 # python code 18 19 def test(): 20 app = pygmentsCss("className") 21 print "test output", app({}, misc.ignore) 22 23 if __name__=="__main__": 24 test() 25 {{/use-url}} 26 27 </body> 28 </html> The key action is lines 9-25 which delegate the colorization formatting to the pygments middleware. [unsimplified source at: http://aaron.oirt.rutgers.edu/myapp/root/showText?path=./misc/pygmentsTest formatted output at: http://aaron.oirt.rutgers.edu/myapp/root/misc/pygmentsTest ] To add a page to colorize code in any way supported by Pygments using WHIFF drop a file like this changing python to java or whatever into a WHIFF directory (after installing Pygments). How do you do it in other approaches? -- Aaron Watters === "I want to achieve immortality by not dying" -- Woody Allen --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pocoo-libs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/pocoo-libs?hl=en -~----------~----~----~----~------~----~------~--~---
