Anyone Interested in a C++ to HTML pretty printer?

I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries? The pretty printer recognizes and colors keywords, identifiers, string literal, character literals, number literals, macros and comments. It does so by using <span class="xxx"></span> tags around the elements. This means that italics / style / coloring can be controlled by a separate CSS file. There are some future enhancements which could be interesting as well such as: - automated hyper-linking of #include directives - javsascript open / close of code blocks { } Anyone interested? Christopher Diggins http://www.cdiggins.com http://www.heron-language.com

* christopher diggins <cdiggins@videotron.ca> [2004-12-30 15:00]:
I am nearly finished a public domain C++ to HTML tool with syntax coloring.
The pretty printer recognizes and colors keywords, identifiers, string literal, character literals, number literals, macros and comments. It does so by using <span class="xxx"></span> tags around the elements. This means that italics / style / coloring can be controlled by a separate CSS file.
There are some future enhancements which could be interesting as well such as:
- automated hyper-linking of #include directives - javsascript open / close of code blocks { }
See? Look how people think of their applications in terms of *documents* these days. -- Alan Gutierrez - alan@engrm.com

I'd use it. On Thu, 30 Dec 2004 14:41:16 -0500, christopher diggins <cdiggins@videotron.ca> wrote:
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
The pretty printer recognizes and colors keywords, identifiers, string literal, character literals, number literals, macros and comments. It does so by using <span class="xxx"></span> tags around the elements. This means that italics / style / coloring can be controlled by a separate CSS file.
There are some future enhancements which could be interesting as well such as: - automated hyper-linking of #include directives - javsascript open / close of code blocks { }
Anyone interested?
Christopher Diggins http://www.cdiggins.com http://www.heron-language.com
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
-- Cory Nelson http://www.int64.org

christopher diggins wrote:
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
We already have something like that built into quickdoc/quickbook, which is Spirit-based. -- Dave Abrahams Boost Consulting http://www.boost-consulting.com

David Abrahams wrote:
christopher diggins wrote:
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
We already have something like that built into quickdoc/quickbook, which is Spirit-based.
Also, see cpp_to_html here: http://spirit.sourceforge.net/repository/applications/show_contents.php Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net

christopher diggins wrote:
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
how does it compare to 'enscript' ? Regards, Stefan

----- Original Message ----- From: "Stefan Seefeld" <seefeld@sympatico.ca>
christopher diggins wrote:
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
how does it compare to 'enscript' ?
What I have is a far more primitive and specialized tool, it simply converts a C++ source file to html formatted output on the standard output stream starting with a <pre> tag and ending with </pre>. Christopher Diggins http://www.cdiggins.com http://www.heron-language.com

-----Original Message----- From: boost-bounces@lists.boost.org [mailto:boost-bounces@lists.boost.org] On Behalf Of christopher diggins Sent: Thursday, December 30, 2004 12:41 PM To: Boost mailing list Subject: [boost] Anyone Interested in a C++ to HTML pretty printer?
I am nearly finished a public domain C++ to HTML tool with syntax coloring. This is primarily intended as a demonstration of the YARD parser, but with practicial applications. I am wondering if anyone in the Boost community be interested in using the tool for sprucing up the code examples for the documentation to their libraries?
The pretty printer recognizes and colors keywords, identifiers, string literal, character literals, number literals, macros and comments. It does so by using <span class="xxx"></span> tags around the elements. This means that italics / style / coloring can be controlled by a separate CSS file.
There are some future enhancements which could be interesting as well such as: - automated hyper-linking of #include directives - javsascript open / close of code blocks { }
Anyone interested?
Sure, that sort of thing is always useful, when well done. Have you considered leveraging the codebase to a straight C++ formatter? There really isn't one out there that's up to the task. I've been hacking GNU Indent for years to get something that sort of handles C++ and has the options I like; be nice to actually have a good free product out there that's designed to handle C++ with a good spread of options. If you had any interest, I could send you my annotated option file for Indent (obviously, I can't send the code, since it's copy-lefted). But the option file would show what's present (including some things that aren't in Indent's docs) and what I thought worth adding. Or not, if you prefer; I'm perfectly aware of the magnitude of such a piece of code. <g> Reid

----- Original Message ----- From: "Reid Sweatman" <drunkardswalk@earthlink.net>
Sure, that sort of thing is always useful, when well done. Have you considered leveraging the codebase to a straight C++ formatter? There really isn't one out there that's up to the task. I've been hacking GNU Indent for years to get something that sort of handles C++ and has the options I like; be nice to actually have a good free product out there that's designed to handle C++ with a good spread of options. If you had any interest, I could send you my annotated option file for Indent (obviously, I can't send the code, since it's copy-lefted). But the option file would show what's present (including some things that aren't in Indent's docs) and what I thought worth adding.
Or not, if you prefer; I'm perfectly aware of the magnitude of such a piece of code. <g>
I might be able to get the ball rolling on a code formatter, but I definitely wouldn't be able to follow through with maintenance / support / evolution. Please send me your options file to begin with, and I will try to gauge the scope of it and see whether I can do anything significant in my spare time. Would you have any interest in contributing to or helping maintain such a tool, if I did get it started? Christopher Diggins http://www.cdiggins.com
participants (7)
-
Alan Gutierrez
-
christopher diggins
-
Cory Nelson
-
David Abrahams
-
Joel de Guzman
-
Reid Sweatman
-
Stefan Seefeld