1
0
forked from GitHub/gf-rgl

Add a Quick Links menu to the Libary Synopsis web page.

The menu is generated dynamically by JavaScript functions defined in
quicklinks.js, by traversing the Detailed Table of Contents in the 
generated synopsis.html.
This commit is contained in:
hallgren
2017-06-01 18:21:52 +00:00
parent 9c995e8592
commit 06aa7948da
3 changed files with 139 additions and 1 deletions

View File

@@ -45,6 +45,8 @@ main = do
append "%!postproc(html): '(SRC=\"categories.png\")' '\\1 USEMAP=\"#categories\"'"
append "%!postproc(html): '#LParadigms' '<a name=\"RParadigms\"></a>'"
append "%!postproc(tex): '#LParadigms' ''"
append "%!postproc(html): '#quicklinks' '<script src=\"quicklinks.js\"></script>'"
append "%!postproc(tex): '#quicklinks' ''"
delimit $ addToolTips cs
include "synopsis-intro.txt"
title "Categories"
@@ -95,6 +97,8 @@ main = do
space
append "%%toc"
space
append "#quicklinks"
space
let format = if isLatex then "tex" else "html"
system $ "txt2tags -t" ++ format ++ " " ++ " --toc " ++ synopsis
if isLatex then (system $ "pdflatex synopsis.tex") >> return () else return ()