From 0b3a50f9e36077dd56b449624ddf7c3a1c800410 Mon Sep 17 00:00:00 2001 From: "arseny.kapoulkine" Date: Sat, 10 Jul 2010 19:36:50 +0000 Subject: docs: Added custom navigation bar, moved table of contents to separate section git-svn-id: http://pugixml.googlecode.com/svn/trunk@585 99668b35-9821-0410-8761-19e4c4f06640 --- Jamfile.jam | 2 +- Jamrules.jam | 21 +++++++++---- docs/manual.qbk | 11 +++++-- docs/manual.xsl | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 120 insertions(+), 9 deletions(-) create mode 100644 docs/manual.xsl diff --git a/Jamfile.jam b/Jamfile.jam index b636025..9bba987 100644 --- a/Jamfile.jam +++ b/Jamfile.jam @@ -105,7 +105,7 @@ for CONFIG in $(CONFIGURATIONS) } # documentation -Documentation docs/manual.html : docs/manual.qbk ; +Documentation docs/manual.html : docs/manual.qbk : docs/manual.xsl ; Alias docs : docs/manual.html ; diff --git a/Jamrules.jam b/Jamrules.jam index 1efd90c..202d583 100644 --- a/Jamrules.jam +++ b/Jamrules.jam @@ -486,9 +486,12 @@ actions QuickbookAction %QUICKBOOK_PATH%\bin\quickbook.exe --output-file $(<) --input-file $(>) >nul } -actions XSLTProcAction +actions response XSLTProcAction { - %QUICKBOOK_PATH%\bin\xsltproc.exe --path$(SPACE)$(XSLPATH:C) --stringparam$(SPACE)$(XSLPARAM) --output $(<) $(XSL) $(>) + %QUICKBOOK_PATH%\bin\xsltproc.exe --path$(SPACE)$(XSLPATH:C) --stringparam$(SPACE)$(XSLPARAM) --output $(<) @( + + + ) $(>) } rule MakeFileDir TARGET @@ -616,7 +619,13 @@ rule QuickbookImport SOURCE : IMPORT Includes $(SOURCE) : $(SOURCE:D)/$(IMPORT) ; } -rule Documentation TARGET : SOURCE +rule FullPath FILE +{ + local PWD = [ Subst [ Shell "cd" ] : "%c" : "" ] ; + return "$(PWD)/$(FILE)" ; +} + +rule Documentation TARGET : SOURCE : STYLESHEET { # escape colon with %3A because colon is a path list separator local XSLDIR = [ Subst $(QUICKBOOK_PATH) : ":" : "%%%%3A" ] ; @@ -635,7 +644,7 @@ rule Documentation TARGET : SOURCE # boostbook -> docbook local DOCBOOK = $(BUILD)/$(SOURCE:S=.db.xml) ; - XSL on $(DOCBOOK) = $(XSLDIR)/boostbook/xsl/docbook.xsl ; + XSL on $(DOCBOOK) = $(QUICKBOOK_PATH)/boostbook/xsl/docbook.xsl ; XSLPATH on $(DOCBOOK) = $(XSLDIR)/boostbook/dtd $(XSLDIR)/docbook-xml ; XSLTProcAction $(DOCBOOK) : $(BOOSTBOOK) ; Depends $(DOCBOOK) : $(BOOSTBOOK) ; @@ -643,7 +652,7 @@ rule Documentation TARGET : SOURCE # docbook -> html local HTML = $(TARGET) ; - XSL on $(HTML) = $(XSLDIR)/boostbook/xsl/html.xsl ; + XSL on $(HTML) = $(QUICKBOOK_PATH)/boostbook/xsl/html.xsl [ FullPath $(STYLESHEET) ] ; XSLPATH on $(HTML) = $(XSLDIR)/docbook-xml $(XSLDIR)/docbook-xsl/html $(XSLDIR)/docbook-xsl/lib ; XSLPARAM on $(HTML) = @@ -657,5 +666,5 @@ rule Documentation TARGET : SOURCE ; XSLTProcAction $(HTML) : $(DOCBOOK) ; - Depends $(HTML) : $(DOCBOOK) ; + Depends $(HTML) : $(DOCBOOK) $(STYLESHEET) ; } diff --git a/docs/manual.qbk b/docs/manual.qbk index f110503..5b7b5f9 100644 --- a/docs/manual.qbk +++ b/docs/manual.qbk @@ -1,4 +1,4 @@ -[article pugixml +[book pugixml [quickbook 1.5] [version 0.9] @@ -23,7 +23,7 @@ pugixml enables very fast, convenient and memory-efficient XML document processi This is the complete user manual for pugixml, which describes all features of the library in detail. If you want to start writing code as quickly as possible, you are advised to [@quickstart.html read the quick start guide first]. -[note No documentation is perfect, neither is this one. If you encounter a description that is unclear, please file an issue as described in [sref manual.overview.feedback]. Also if you can spare the time for a full proof-reading, including spelling and grammar, that would be great! Please send me an e-mail; as a token of appreciation, your name will be put into the corresponding section of this documentation.] +[note No documentation is perfect, neither is this one. If you encounter a description that is unclear, please file an issue as described in [sref manual.overview.feedback]. Also if you can spare the time for a full proof-reading, including spelling and grammar, that would be great! Please [link email send me an e-mail]; as a token of appreciation, your name will be included into the [link manual.overview.thanks corresponding section] of this documentation.] [endsect] [/introduction] @@ -1996,3 +1996,10 @@ Functions: * [link set_memory_management_functions] [endsect] [/apiref] + +[section:toc Table of contents] + +toc-placeholder + +[endsect] [/toc] + diff --git a/docs/manual.xsl b/docs/manual.xsl new file mode 100644 index 0000000..60e99b2 --- /dev/null +++ b/docs/manual.xsl @@ -0,0 +1,95 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + user manual | + | + | + Document: + + &middot; + + &middot; + + &middot; + + &middot; + | + | + | + + + + + + + + + + + + +
+ + + + + + + +
+
+
+ + + + + + +
+ + + + +
+ + + + + + + +
+
+ + + + + + + + + +
+ -- cgit v1.2.3