[texhax] Using hevea

Uwe Lueck uwe.lueck at web.de
Thu Sep 15 16:09:02 CEST 2011


"Gordon Haverland" <ghaverla at materialisations.com> wrote 12.09.2011 23:36:47:
> I am trying to learn how to blog, and most things I write about
> emacs in HTML mode is fine. I can then cut and paste from emacs
> to the "editor" the blog has.
>
> This last document started getting complex, and among other things
> I thought a Table of Contents would be useful. Manually making
> the ToC and keeping it in sink with the evolving structure of the
> document got to be a pain. Time to investigate LaTeX to HTML.
>
> I started with tex4ht. It seems to be too interested in
> presentation, and most of the structure seems to be in the
> attributes of tags. And way too many <div> and <span> for me to
> work with. I then tried hevea, and it seems workable.
>
> Hevea doesn't seem to know anything about hyperref. So, I am
> getting warnings about underscores and improper anchors, but that
> is editable. The biggest annoyance seems to be tables. While you
> can define a table in HTML that only has a body, the HTML
> definition allows for HEAD, BODY and FOOTER. And in LaTeX, a
> table only has content. So, every table will need polishing.
> Which is fine, I might even be able to figure out how to get perl
> to rewrite the HTML to do this.
>
> This note is not a complaint. It is an observation. Hopefully it
> helps others. It may be that I haven't found the best solution
> yet. And advice along that line is also welcome.

I would be curious whether somebody else than me finds my blog.sty in

    ctan.org/pkg/morehype

useful. But you must know about its limitations.
There is no typesetting via DVI or PDF,
rather the page source is expanded line-by-line.
Therefore LaTeX commands just work by redefiing them
entirely, and so far in processing the source, no assignments
can be executed. Therefore, optional arguments,
starred commands, or \xspace do not work.
Many macros are new, made just to access HTML elements
or symbols. Many things I use every day are in rather
private files because I still need to make more experiences
with them before I could say that they are useful in general.
I have redefined and used \section only for a special
project because I don't have a general opinion whether
it should use <h1> or <h2>. And anyway, I am unable
to number sections so far (see "assignments" above).
My ToCs are hand-made like: [\,\autref{A} | \autref{B} | ... \,]

I like it for collecting notes, links, and notes on links,
and links to certain notes on certain pages pages of mine.
I can focus on the content more than with ordinary LaTeX,
because I needn't deal with line breaks, page breaks,
messages about fonts.

Hope a little that helps a little -- Uwe.



More information about the texhax mailing list