This Manual (Edition 0.21, last updated at
14. August 2000) describes the texi2html Perl
script which converters
Texinfo
into HTML.
Please send bug reports about this manual to Karl Heinz
Marbaise khmarbaise@gmx.de. Please state exact
version/edition of the manual (can be found at start of
Texinfo source file; use the entry Id under Revisions).
Please note:
This manual is currently under
construction and of course incomplete ;-)
Texinfo is the official
documentation format of the GNU
project. It uses a single source file to produce both
online information and printed output.
It is often proposed to have a way to produce
HTML from Texinfo sources, like the GNU-Info
format. It is much simpler to create one converter instead
of writing all documentation new in HTML, cause
there is so much documentation in Texinfo all over
the world.
A few time ago makeinfo wasn't able to produce
HTML output format, but there are needth to have
HTML. This was the borning hour for
texi2html. The basic purpose of `texi2html'
is to convert Texinfo documents into HTML.
You would like to HTML files out of your Texinfo
files? There exist two ways which you can go.
This first is to use makeinfo itself to produce
HTML output. The second is to use
texi2html.
The basic idea of makeinfo's HTML
output was to get an readable HTML output.
Nothing sophisticated nor good styling just readable.
The current development of texi2html is going into
different direction.
The main purpose is to get better styling, better design
etc. of the created HTML pages. This way is
supported using differnt command line options and of course
possible changings of the initialization file to fit your
own needs.
The main disadvantage of makeinfo's
HTML output is your getting only one big file.
This is of course readable but not very usable. The problem
of this is, while you like to have splitted chapters or
nodes the Texinfo source has to be read at minimum twice
times. This makes it impossible to implement this in
makeinfo. This would result in complete new
implementation of makeinfo's source.
In contrast to the HTML produced by makeinfo
--html (the makeinfo program is part of the
Texinfo distribution), the HTML output of `texi2html'
is highly configurable. Among other differences, with
texi2html allows you to customize your entire
page layout (like headers, footers, style sheets, etc),
split documents at various levels, and use
latex2html to convert @tex sections.
texi2html should reasonably convert all Texinfo
4.0 constructs. If not, please send a bug report to
texi2html@mathematik.uni-kl.de.
Here you can find information about the creation of the
ToC (Table Of content), About--Page
etc. and specialy how to change them to get your own
design.
ToC T2H_DEFAULT_print_toc_frame in
`texi2html.init'
As you can see it is very simple Perl Code, which can
be changed more or less simple to fit you requirements
(see section T2H_DEFAULT_print_page_head).
If you like to read the following section, it is assumed
you are famillar with HTML. If not, you shouldn't
read this, cause you don't know what we are talking about.
Here you can find information how to change the
HTML parts of a document. These are the
header, body etc.
These are the defaults which are
part of the distribution as `texi2html.init'.
How to do changes of the customization...
needed steps.
# text inserted after <BODY ...>
$T2H_AFTER_BODY_OPEN = '';
#text inserted before </BODY>
$T2H_PRE_BODY_CLOSE = '';
# this is used in footer
$T2H_ADDRESS = "by $T2H_USER</I> " if $T2H_USER;
$T2H_ADDRESS .= "on $T2H_TODAY</I>";
# this is added inside <HEAD></HEAD> after <TITLE> and some META NAME stuff
# can be used for <style> <script>, <meta> tags
$T2H_EXTRA_HEAD = '';
The default output into the HTML file.
See section 8.2 DocType.
The following code is produced by
T2H_DEFAULT_print_page_head.
Initialization options are read first from
`/usr/local/etc/texi2htmlrc' (the exact location being
changeable with the `--sysconfdir=dir' option to the
configure script), then from
`$HOME/.texi2htmlrc', then any command-line options
including `-init_file' option; with later settings
overriding earlier ones.
The default initialization options are defined in the
`texi2html.init' file contained in the Texi2html
distribution (which gets included near the beginning of the
texi2html script that gets installed).
To customize `texi2html' it is best if you copy the
appropriate sections from the `texi2html.init'
contents into an appropriate local initialization file,
make the necessary changes there, and then have
texi2html read this initialization file by one of
the means described above.
This section describes in detail all options that can
be used only in the initialization file (`texi2html.init'),
and cannot be specified on the command line.
This means the only way to change those
options is first to copy the original `texi2html.init'
to e.g. `texi2html.init.myown' and make changes to fit
your needs.
if set and menu entry equals menu description, then do not print
menu description. Likewise, if node name equals entry name, do
not print entry name.
$T2H_AVOID_MENU_REDUNDANCY = 1;
if non-empty, and no @..heading appeared in Top
node, then use this as header for top node/section,
otherwise use value of @settitle or
@shorttitle (in that order)
$T2H_TOP_HEADING = "";
`-invisible'
$T2H_INVISIBLE_MARK is the text used to create
invisible destination anchors for index links (you can for
instance use the `invisible.xbm' file shipped with
this program). This is a workaround for a known bug of many
WWW browsers, including Netscape. For me, it
works fine without it -- on the contrary: if there, it
inserts space between headers and start of text (obachman
3/99)
`-top_file'
uses file of this name for top-level file
extension is manipulated appropriately, if necessary.
If empty, `<basename of document>.html' is used.
Typically, you would set this to `index.html'.
`-toc_file'
uses file of this name for table of contents. File extension
is manipulated appropriately, if necessary. If empty,
`<basename of document>_toc.html' is used.
`-split section|chapter|none'
if set to section (resp. chapter) create one
HTML file per (sub)section (resp. chapter) and
separate pages for Top, ToC, Overview, Index, Glossary,
About. Otherwise, create a monolithic HTML file that
contains the whole document.
if set, then navigation panels are printed at the beginning
of each section and, possibly at the end (depending on
whether or not there were more than
$T2H_WORDS_IN_PAGE words on page). This is most useful
if you do not want to have section navigation on
`-split chapter'
`-short_extn'
If this is set, then all HTML files will have extension
`.htm' instead of `.html'. This is helpful when
shipping the document to DOS-based systems.
$T2H_SHORTEXTN = 0;
`-idx_sum'
If value is set, then for each @prinindex $what
`$docu_name_$what.idx' is created which contains lines of the
form $key\t$ref sorted alphabetically (case
matters).
`-lang'
For page titles, use
$T2H_WORDS->{$T2H_LANG}->{...} as title. To add
a new languages, supply list of titles (see
$T2H_WORDS), and use ISO 639 language codes (see e.g.
perl module `Locale-Codes-1.02.tar.gz' for
definitions).
If you don't give a `-lang' then we got it from the
Texinfo source file (@documentlanguage
@xref{documentlanguage,,,Texinfo}). If there is no
@documentlanguage we use the default en for
the language.
`-l2h_tmp'
if set, l2h uses this directory for temporary files. The
path leading to this directory may not contain a dot (i.e.,
a `.'); otherwise, l2h will fail.