Article View: comp.editors
Article #3934auto generate HTML from syntax-highlighted buffer?
From: Matt Garman
Date: Thu, 28 Mar 2002 04:07
Date: Thu, 28 Mar 2002 04:07
30 lines
2358 bytes
2358 bytes
Today I was writing some rather verbose comments in a C++ class header
file. Both vim and emacs do a nice job of nicely formatting/indenting
my code as well as beautifully syntax highlighting (font locking if
you like that term :) my code.
I thought it sure would be nice if my editor could (automatically)
write an HTML version of the file, complete with the syntax
highlighting colors. In theory, this doesn't sound like it would be
too hard---the text is already there, and the editor already knows how
it's coloring things (which implies that it knows how to parse the
language). It's just a matter of writing out the file padded with the
right html tags.
I suppose that technically this is out of the realm of an editor's
function, so maybe it's not for vim---but it screams emacs! <grin>
Anyway, I am aware that there are tools that do this to some extent
(javadoc and her cousins). But I haven't seen a tool that both
doesn't require specially formatted comments and looks as pretty as
vim and emacs' syntax highlighting. Perhaps I haven't looked hard
enough though.
Any thoughts, comments, ideas, etc?
Matt
--
Matt Garman, matt@raw-sewage.net
``I ain't never seen no whiskey, the blues made my sloppy drunk!''
-- Sleepy John Estes, ``Leaving Trunk''
Technical Details
Message-ID:
<slrnaa55sr.n2u.garman@news-proxy.cso.uiuc.edu>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!vixen.cso.uiuc.edu!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103b8b,ca539ea9a21a3cf9,start X-Google-Attributes: gid103b8b,public X-Google-Thread: 107393,ca539ea9a21a3cf9,start X-Google-Attributes: gid107393,public X-Google-ArrivalTime: 2002-03-27 20:10:16 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!vixen.cso.uiuc.edu!not-for-mail Newsgroups: comp.editors,gnu.emacs.help From: Matt Garman <garman@raw-sewage.net> Subject: auto generate HTML from syntax-highlighted buffer? Reply-To: matt@raw-sewage.net Followup-To: comp.editors Message-ID: <slrnaa55sr.n2u.garman@news-proxy.cso.uiuc.edu> User-Agent: slrn/0.9.7.3 (Linux) X-Proxy-Client: garman@uiuc.edu from generic237.infoave.net Lines: 30 Date: Thu, 28 Mar 2002 04:07:58 GMT NNTP-Posting-Host: 128.174.5.27 X-Complaints-To: abuse@uiuc.edu X-Trace: vixen.cso.uiuc.edu 1017288478 128.174.5.27 (Wed, 27 Mar 2002 22:07:58 CST) NNTP-Posting-Date: Wed, 27 Mar 2002 22:07:58 CST Organization: University of Illinois at Urbana-Champaign