doc: Use a stylesheet for dblatex
authorIan Abbott <abbotti@mev.co.uk>
Fri, 4 May 2012 15:32:35 +0000 (16:32 +0100)
committerIan Abbott <abbotti@mev.co.uk>
Fri, 4 May 2012 15:32:35 +0000 (16:32 +0100)
Add comedilib_dblatex_config.xsl stylesheet and pass it to dblatex when
producing PDF output.  The current version of the stylesheet doesn't
make much difference to the output, but it's somewhere we can put stuff
later.

We probably want to do something similar for the other PDF backends, but
those are currently broken anyway.

doc/Makefile.am
doc/comedilib_dblatex_config.xsl [new file with mode: 0644]

index 117e11df8b38612a21c7a7ca1aa2c3dde7ba45c5..4b41e6b580fa6017203d5573cd1effa2195a7ee1 100644 (file)
@@ -9,6 +9,7 @@ EXTRA_DIST = $(XML) calibration_funcref.txt command_funcref.txt dio_funcref.txt
        deprecated_funcref.txt error_funcref.txt extensions_funcref.txt \
        funcref mkref drivers.txt mkdr FAQ \
        acq-seq.gif doc_html man comedilib_html_config.xsl \
+       comedilib_dblatex_config.xsl \
        comedilib.css
 
 BUILT_SOURCES = calibration_funcref.xml command_funcref.xml dio_funcref.xml \
@@ -38,12 +39,12 @@ dist_pdf_DATA =
 endif
 
 if BUILD_PDF_USING_DBLATEX
-XMLTO_PDF_WITH = --with-dblatex
+XMLTO_PDF_OPTS = --with-dblatex -p "-p $(abs_srcdir)/comedilib_dblatex_config.xsl"
 else
 if BUILD_PDF_USING_FOP
-XMLTO_PDF_WITH = --with-fop
+XMLTO_PDF_OPTS = --with-fop
 else
-XMLTO_PDF_WITH =
+XMLTO_PDF_OPTS =
 endif
 endif
 
@@ -82,8 +83,8 @@ install_man:
 uninstall_man:
        for each in `find $(srcdir)/man/ -name '*.3'`; do $(RM) $(DESTDIR)$(mandir)/man3/`basename $$each` ; done
 
-$(srcdir)/pdf/comedilib.pdf: $(XML)
-       $(XMLTO) -o $(srcdir)/pdf --skip-validation $(XMLTO_PDF_WITH) pdf $(srcdir)/comedilib.xml
+$(srcdir)/pdf/comedilib.pdf: $(XML) comedilib_dblatex_config.xsl
+       $(XMLTO) -o $(srcdir)/pdf --skip-validation $(XMLTO_PDF_OPTS) pdf $(srcdir)/comedilib.xml
 
 funcref.xml: funcref mkref
        $(srcdir)/mkref $(srcdir)/funcref >$(srcdir)/funcref.xml
diff --git a/doc/comedilib_dblatex_config.xsl b/doc/comedilib_dblatex_config.xsl
new file mode 100644 (file)
index 0000000..33ec45b
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version='1.0'?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+       xmlns:fo="http://www.w3.org/1999/XSL/Format"
+       version="1.0">
+       <xsl:param name="funcsynopsis.decoration" select="1"/>
+       <xsl:param name="funcsynopsis.style">ansi</xsl:param>
+</xsl:stylesheet>