2

This is a follow up question to How to change table of content layout for a pdf document created from a web source file?

I input the following commands:

weave tex.web     
pdftex tex.tex

and create a PDF whose appearance depends on the macro file in the 1st line of tex.tex whose content is controlled by weave.

\input pdfwebmac
% This program is copyright (C) 1982 by D. E. Knuth; all rights are reserved.

tex.tex is generated by weave

Alternatively, the first line can also contain \input webmac.

In case of pdfwebmac we have an interactive PDF with hyperlinks in the sections and in the table of content which will be at the bottom of the PDF. (You can get a similar PDF with the command texdoc tex. But there's the table of content at the beginning of the document.)

The TOC is controlled by contents.tex which contains

\Z {\?1] Introduction}{1}{3}
\Z {\?2] The character set}{17}{10}
\Z {\?3] Input and output}{25}{13}
...

contents.tex is generated by a macro from pdfwebmac

  • sequential numbering
  • title of section
  • number of section
  • number of page

Can one now use this contents.tex to insert a 2nd TOC (with hyperlinks) at the beginning of the document? How to do this?

Could the generated PDF be read with the help of a more modern LaTex package (more modern than pdfwebmac) and extended with another table of contents after contents.tex?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.