欢迎大家赞助一杯啤酒🍺 我们准备了下酒菜:Formal mathematics/Isabelle/ML, Formal verification/Coq/ACL2, C++/F#/Lisp
DocBook
来自开放百科 - 灰狐
(版本间的差异)
第6行: | 第6行: | ||
==Install== | ==Install== | ||
Debian | Debian | ||
+ | #apt-get install xsltproc //XSLT command line processor | ||
#apt-get install rxp // A validating XML parser | #apt-get install rxp // A validating XML parser | ||
#apt-get install docbook | #apt-get install docbook | ||
+ | #apt-get install docbook-utils - Convert Docbook files to other formats (HTML, RTF, PS, man, PDF) | ||
+ | #apt-get install docbook-xsl - stylesheets for processing DocBook XML files to various output formats | ||
+ | 相关包 | ||
+ | docbook-defguide - DocBook: The Definitive Guide - HTML version | ||
+ | docbook-doc - Documentation for the DocBook DTD. | ||
+ | docbook-dsssl - modular DocBook DSSSL stylesheets, for print and HTML | ||
+ | docbook-dsssl-doc - documentation for the DocBook DSSSL stylesheets | ||
+ | docbook-ebnf - EBNF module for the XML version of the DocBook DTD | ||
+ | docbook-html-forms - Extension to DocBook XML for generating html forms | ||
+ | docbook-jrefentry - DocBook XML JRefEntry DTD | ||
+ | docbook-mathml - Extension to DocBook XML for using MathML markup | ||
+ | docbook-simple - Simplified DocBook XML Doctype and css stylesheets. | ||
+ | docbook-slides - XML Slides DTD and XSL Stylesheets | ||
+ | docbook-slides-demo - Demo presentation slides for the docbook-slides package | ||
+ | docbook-to-man - converter from DocBook SGML into roff man macros | ||
+ | docbook-website - XML Website DTD and XSL Stylesheets | ||
+ | docbook-xml - standard XML documentation system, for software and systems | ||
+ | docbook-xsl-stylesheets-ko - Stylesheets for processing DocBook XML files to HTML and FO in korean. | ||
+ | docbook2x - Converts DocBook/XML documents into man pages and TeXinfo | ||
+ | doclifter - Convert troff to DocBook | ||
+ | |||
==Examples== | ==Examples== | ||
http://www.w3.org/XML/Binary/2005/03/test-data/Docbook/examples/ | http://www.w3.org/XML/Binary/2005/03/test-data/Docbook/examples/ | ||
+ | 利用样式表生成单页的html文档,生成文档名为debian.html,生成的文档位于当前目录。 | ||
+ | $ xsltproc --stringparam html.stylesheet docbook.css /usr/share/sgml/docbook/docbook-xsl-1.65.1/html/docbook.xsl | ||
+ | debian.xml>debian.html | ||
+ | 利用样式表生成多页的html文档,每章和每小节都会生成独立的一个html文档,生成文档位于当前目录。 | ||
+ | $ xsltproc --stringparam html.stylesheet docbook.css /usr/share/sgml/docbook/docbook-xsl-1.65.1/html/chunk.xsl debian.xml | ||
+ | 用-o选项可指定生成文档的路径 | ||
*http://docbook.sourceforge.net/ | *http://docbook.sourceforge.net/ | ||
*http://www.docbook.org/ | *http://www.docbook.org/ |
2007年3月9日 (五) 20:27的版本
DocBook is an XML vocabulary that lets you create documents in a presentation-neutral form that captures the logical structure of your content. Using free tools along with the DocBook XSL stylesheets, you can publish your content as HTML pages and PDF files, and in many other formats.
Writing Documentation Using DocBook - http://docs.huihoo.com/xml/using-docbook/
编辑DocBook XML文档 - http://ldp.huihoo.org/linuxfocus/ChineseGB/May2002/article201.shtml
Install
Debian
#apt-get install xsltproc //XSLT command line processor #apt-get install rxp // A validating XML parser #apt-get install docbook #apt-get install docbook-utils - Convert Docbook files to other formats (HTML, RTF, PS, man, PDF) #apt-get install docbook-xsl - stylesheets for processing DocBook XML files to various output formats
相关包
docbook-defguide - DocBook: The Definitive Guide - HTML version docbook-doc - Documentation for the DocBook DTD. docbook-dsssl - modular DocBook DSSSL stylesheets, for print and HTML docbook-dsssl-doc - documentation for the DocBook DSSSL stylesheets docbook-ebnf - EBNF module for the XML version of the DocBook DTD docbook-html-forms - Extension to DocBook XML for generating html forms docbook-jrefentry - DocBook XML JRefEntry DTD docbook-mathml - Extension to DocBook XML for using MathML markup docbook-simple - Simplified DocBook XML Doctype and css stylesheets. docbook-slides - XML Slides DTD and XSL Stylesheets docbook-slides-demo - Demo presentation slides for the docbook-slides package docbook-to-man - converter from DocBook SGML into roff man macros docbook-website - XML Website DTD and XSL Stylesheets docbook-xml - standard XML documentation system, for software and systems docbook-xsl-stylesheets-ko - Stylesheets for processing DocBook XML files to HTML and FO in korean. docbook2x - Converts DocBook/XML documents into man pages and TeXinfo doclifter - Convert troff to DocBook
Examples
http://www.w3.org/XML/Binary/2005/03/test-data/Docbook/examples/
利用样式表生成单页的html文档,生成文档名为debian.html,生成的文档位于当前目录。
$ xsltproc --stringparam html.stylesheet docbook.css /usr/share/sgml/docbook/docbook-xsl-1.65.1/html/docbook.xsl debian.xml>debian.html
利用样式表生成多页的html文档,每章和每小节都会生成独立的一个html文档,生成文档位于当前目录。
$ xsltproc --stringparam html.stylesheet docbook.css /usr/share/sgml/docbook/docbook-xsl-1.65.1/html/chunk.xsl debian.xml
用-o选项可指定生成文档的路径
分享您的观点