Index
Go backward to Splitting into nodes and menus
Go up to Controlling Hyperlatex
Go forward to Setting the Html level

Customizing the navigation panels

Normally, Hyperlatex adds a "navigation panel" at the beginning of every HTML node. This panel has links to the next and previous node on the same level, as well as to the parent node. The panel for the top node has a link to the first chapter or section.

The easiest way to customize the navigation panel is to turn it off for selected nodes. This is done using the commands \htmlpanel{0} and \htmlpanel{1}. All nodes started while \htmlpanel is set to 0 are created without a navigation panel.

Furthermore, the navigation panels (and in fact the complete outline of the created HTML files) can be customized to your own taste by redefining some Hyperlatex macros. In fact, when it formats an HTML node, Hyperlatex inserts the macro \toppanel at the beginning, and the two macros \bottommatter and bottompanel at the end. When \htmlpanel{0} has been set, then only \bottommatter is inserted.

The macros \toppanel and \bottompanel take six arguments. These are (in this order) the URL of the previous node, the parent node, the next node; and their titles. If a node has no previous or next node, then the argument is empty. You can test for an empty string using the \IfLink command. Its first argument is a string, it expands the second argument if the string is non-empty, and the third argument otherwise.

The default definitions for the three macros are as follows.

\newcommand{\toppanel}[6]{%
  \IfLink{#1#2#3}{%
    \IfLink{#1}{\xlink{\htmlimage[ALT=""]{\thehtmlicons/previous.xbm}}{#1}}{%
      \htmlimage[ALT=""]{\thehtmlicons/previous.xbm}}
    \IfLink{#2}{\xlink{\htmlimage[ALT=""]{\thehtmlicons/up.xbm}}{#2}}{%
      \htmlimage[ALT=""]{\thehtmlicons/up.xbm}}
    \IfLink{#3}{\xlink{\htmlimage[ALT=""]{\thehtmlicons/next.xbm}}{#3}}{%
      \htmlimage[ALT=""]{\thehtmlicons/next.xbm}}\\
    \IfLink{#1}{\textbf{Go backward to }\xlink{#4}{#1}\\}{}%
    \IfLink{#2}{\textbf{Go up to }\xlink{#5}{#2}\\}{}%
    \IfLink{#3}{\textbf{Go forward to }\xlink{#6}{#3}}{}
    \htmlrule{}}{}}
\newcommand{\bottommatter}{\htmlrule\thehtmladdress\\}
\newcommand{\bottompanel}[6]{%
  \IfLink{#1#2#3}{%
    \IfLink{#1}
      {\xlink{\htmlimage[ALT="Prev"]{\thehtmlicons/previous.xbm}}{#1}}
      {\htmlimage[ALT=""]{\thehtmlicons/previous.xbm}}
    \IfLink{#2}
      {\xlink{\htmlimage[ALT="Up"]{\thehtmlicons/up.xbm}}{#2}}
      {\htmlimage[ALT=""]{\thehtmlicons/up.xbm}}
    \IfLink{#3}
      {\xlink{\htmlimage[ALT="Next"]{\thehtmlicons/next.xbm}}{#3}}
      {\htmlimage[ALT=""]{\thehtmlicons/next.xbm}}}{}}
You can simply redefine them using \newcommand. This manual, for instance, redefines the top panel to include a pointer to the index.

  The command \thehtmladdress returns the string that you had set using \htmladdress, enclosed in HTML address tags. The command \thehtmlicons returns the URL of the directory on your server where the icons reside (assuming the person who installed Hyperlatex at your site did that properly). If necessary, you can set this URL yourself, using the command \htmlicons in the preamble.


otfried@postech.vision.ac.kr

Prev Up Next