Added output.html and output.print as parameter entities to freebsd.dtd.
Default to "IGNORE", you should set them to "INCLUDE" by whatever mechanism your SGML parser supports as necessary (i.e., Jade's -i flag). Added redefinitions for some ISO entities that aren't understood by most web browsers. Since this is for HTML output only, wrap it in a %output.html; marked section. Use these marked sections to put both print and HTML stylesheets in one .dsl file (freebsd.dsl). The print stylesheet now understands about the elements that have been added to DocBook (and won't try and render them in red). Updated Makefile to use output.html and output.print on the command line to Jade, instead of the earlier "html" and "print. Note: producing .tex (and thence .ps and .pdf) versions of the Handbook is broken. The Handbook tickles several bugs in the JadeTeX macros. Sebastian Rahz, the JadeTeX author, knows about this, and is working on fixing them.
This commit is contained in:
parent
b6b695e6fc
commit
dd921ed279
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=3950
5 changed files with 110 additions and 68 deletions
en/handbook
en_US.ISO8859-1/books/handbook
en_US.ISO_8859-1/books/handbook
sgml
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# $Id: Makefile,v 1.6 1998-12-10 20:42:26 nik Exp $
|
||||
# $Id: Makefile,v 1.7 1998-12-20 20:33:49 nik Exp $
|
||||
#
|
||||
# Build the FreeBSD Handbook. Will eventually split in two, a generic .mk
|
||||
# file which can be used by many Makefiles, and a much smaller Makefile
|
||||
|
@ -140,23 +140,21 @@ CLEANFILES+= ${DOC}.${_curformat}
|
|||
all: ${_docs}
|
||||
|
||||
index.html: ${SRCS}
|
||||
${JADE} -ihtml ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
./conv.pl *.html
|
||||
${JADE} -ioutput.html ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
tidy -i -m -f /dev/null *.html
|
||||
|
||||
${DOC}.html: ${SRCS}
|
||||
${JADE} -ihtml -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
./conv.pl ${DOC}.html
|
||||
${JADE} -ioutput.html -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
tidy -i -m -f /dev/null ${DOC}.html
|
||||
|
||||
${DOC}.txt: ${DOC}.html
|
||||
lynx -nolist -dump ${DOC}.html > ${DOC}.txt
|
||||
|
||||
${DOC}.rtf: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
|
||||
${DOC}.tex: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
|
||||
${DOC}.dvi: ${DOC}.tex
|
||||
@echo "==> TeX pass 1/3"
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# $Id: Makefile,v 1.6 1998-12-10 20:42:26 nik Exp $
|
||||
# $Id: Makefile,v 1.7 1998-12-20 20:33:49 nik Exp $
|
||||
#
|
||||
# Build the FreeBSD Handbook. Will eventually split in two, a generic .mk
|
||||
# file which can be used by many Makefiles, and a much smaller Makefile
|
||||
|
@ -140,23 +140,21 @@ CLEANFILES+= ${DOC}.${_curformat}
|
|||
all: ${_docs}
|
||||
|
||||
index.html: ${SRCS}
|
||||
${JADE} -ihtml ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
./conv.pl *.html
|
||||
${JADE} -ioutput.html ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
tidy -i -m -f /dev/null *.html
|
||||
|
||||
${DOC}.html: ${SRCS}
|
||||
${JADE} -ihtml -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
./conv.pl ${DOC}.html
|
||||
${JADE} -ioutput.html -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
tidy -i -m -f /dev/null ${DOC}.html
|
||||
|
||||
${DOC}.txt: ${DOC}.html
|
||||
lynx -nolist -dump ${DOC}.html > ${DOC}.txt
|
||||
|
||||
${DOC}.rtf: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
|
||||
${DOC}.tex: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
|
||||
${DOC}.dvi: ${DOC}.tex
|
||||
@echo "==> TeX pass 1/3"
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# $Id: Makefile,v 1.6 1998-12-10 20:42:26 nik Exp $
|
||||
# $Id: Makefile,v 1.7 1998-12-20 20:33:49 nik Exp $
|
||||
#
|
||||
# Build the FreeBSD Handbook. Will eventually split in two, a generic .mk
|
||||
# file which can be used by many Makefiles, and a much smaller Makefile
|
||||
|
@ -140,23 +140,21 @@ CLEANFILES+= ${DOC}.${_curformat}
|
|||
all: ${_docs}
|
||||
|
||||
index.html: ${SRCS}
|
||||
${JADE} -ihtml ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
./conv.pl *.html
|
||||
${JADE} -ioutput.html ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml
|
||||
tidy -i -m -f /dev/null *.html
|
||||
|
||||
${DOC}.html: ${SRCS}
|
||||
${JADE} -ihtml -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
./conv.pl ${DOC}.html
|
||||
${JADE} -ioutput.html -V nochunks ${JADEFLAGS} -d ${DSLHTML} -t sgml ${DOC}.sgml > ${DOC}.html
|
||||
tidy -i -m -f /dev/null ${DOC}.html
|
||||
|
||||
${DOC}.txt: ${DOC}.html
|
||||
lynx -nolist -dump ${DOC}.html > ${DOC}.txt
|
||||
|
||||
${DOC}.rtf: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t rtf ${DOC}.sgml
|
||||
|
||||
${DOC}.tex: ${SRCS}
|
||||
${JADE} -iprint ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
${JADE} -ioutput.print ${JADEFLAGS} -d ${DSLPRINT} -t tex ${DOC}.sgml
|
||||
|
||||
${DOC}.dvi: ${DOC}.tex
|
||||
@echo "==> TeX pass 1/3"
|
||||
|
|
110
sgml/freebsd.dsl
110
sgml/freebsd.dsl
|
@ -1,36 +1,80 @@
|
|||
<!DOCTYPE style-sheet PUBLIC "-//James Clark//DTD DSSSL Style Sheet//EN" [
|
||||
<!ENTITY dbstyle PUBLIC "-//Norman Walsh//DOCUMENT DocBook HTML Stylesheet//EN" CDATA DSSSL>
|
||||
<!ENTITY % output.html "IGNORE">
|
||||
<!ENTITY % output.print "IGNORE">
|
||||
<![ %output.html; [
|
||||
<!ENTITY docbook.dsl PUBLIC "-//Norman Walsh//DOCUMENT DocBook HTML Stylesheet//EN" CDATA DSSSL>
|
||||
]]>
|
||||
<![ %output.print; [
|
||||
<!ENTITY docbook.dsl PUBLIC "-//Norman Walsh//DOCUMENT DocBook Print Stylesheet//EN" CDATA DSSSL>
|
||||
]]>
|
||||
]>
|
||||
|
||||
<style-sheet>
|
||||
<style-specification use="docbook">
|
||||
<style-specification-body>
|
||||
|
||||
<!-- Configure the stylesheet using documented variables -->
|
||||
<!-- HTML only .................................................... -->
|
||||
|
||||
<![ %output.html; [
|
||||
<!-- Configure the stylesheet using documented variables -->
|
||||
|
||||
(define %stylesheet%
|
||||
"handbook.css")
|
||||
(define %stylesheet%
|
||||
"handbook.css")
|
||||
|
||||
(define %gentext-nav-use-tables%
|
||||
;; Use tables to build the navigation headers and footers?
|
||||
#t)
|
||||
(define %gentext-nav-use-tables%
|
||||
;; Use tables to build the navigation headers and footers?
|
||||
#t)
|
||||
|
||||
(define %html-ext%
|
||||
;; Default extension for HTML output files
|
||||
".html")
|
||||
(define %html-ext%
|
||||
;; Default extension for HTML output files
|
||||
".html")
|
||||
|
||||
(define %shade-verbatim%
|
||||
;; Should verbatim environments be shaded?
|
||||
#f)
|
||||
(define %shade-verbatim%
|
||||
;; Should verbatim environments be shaded?
|
||||
#f)
|
||||
|
||||
(define %use-id-as-filename%
|
||||
;; Use ID attributes as name for component HTML files?
|
||||
#t)
|
||||
(define %use-id-as-filename%
|
||||
;; Use ID attributes as name for component HTML files?
|
||||
#t)
|
||||
|
||||
(define %root-filename%
|
||||
;; Name for the root HTML document
|
||||
"index")
|
||||
(define %root-filename%
|
||||
;; Name for the root HTML document
|
||||
"index")
|
||||
|
||||
<!-- This replaces the existing mechanism for showing verbatim
|
||||
blocks of text (programlistings, screens, and so forth.
|
||||
|
||||
Norm's stylesheet renders these in a table, with optional
|
||||
shading if %shade-verbatim% is set. Previous practice for
|
||||
the LinuxDoc DTD (and John Fieber's stylesheet) was to
|
||||
indent them using <blockquote>. Stick with previous practice.
|
||||
|
||||
Norm says he will introduce a tweakable knob to affect this
|
||||
in the future. -->
|
||||
(define ($verbatim-display$ line-numbers?)
|
||||
(let ((content (make element gi: "BLOCKQUOTE"
|
||||
attributes: (list
|
||||
(list "CLASS" (gi)))
|
||||
(make element gi: "PRE"
|
||||
(if line-numbers?
|
||||
($verbatim-content-with-linenumbers$)
|
||||
($verbatim-content$))))))
|
||||
(if %shade-verbatim%
|
||||
(make element gi: "TABLE"
|
||||
attributes: ($shade-verbatim-attr$)
|
||||
(make element gi: "TR"
|
||||
(make element gi: "TD"
|
||||
content)))
|
||||
content)))
|
||||
]]>
|
||||
|
||||
<!-- Print only ................................................... -->
|
||||
<![ %output.print; [
|
||||
|
||||
]]>
|
||||
|
||||
<!-- Both sets of stylesheets .................................... -->
|
||||
|
||||
<!-- Slightly deeper customisations -->
|
||||
|
||||
<!-- I want things marked up with 'sgmltag' eg.,
|
||||
|
@ -88,34 +132,8 @@
|
|||
/usr/local/share/sgml/docbook/dsssl/modular/html/dblist.dsl is
|
||||
enough to bring me out in cold, Lisp induced sweats. . . -->
|
||||
|
||||
<!-- This replaces the existing mechanism for showing verbatim
|
||||
blocks of text (programlistings, screens, and so forth.
|
||||
|
||||
Norm's stylesheet renders these in a table, with optional
|
||||
shading if %shade-verbatim% is set. Previous practice for
|
||||
the LinuxDoc DTD (and John Fieber's stylesheet) was to
|
||||
indent them using <blockquote>. Stick with previous practice.
|
||||
|
||||
Norm says he will introduce a tweakable knob to affect this
|
||||
in the future. -->
|
||||
(define ($verbatim-display$ line-numbers?)
|
||||
(let ((content (make element gi: "BLOCKQUOTE"
|
||||
attributes: (list
|
||||
(list "CLASS" (gi)))
|
||||
(make element gi: "PRE"
|
||||
(if line-numbers?
|
||||
($verbatim-content-with-linenumbers$)
|
||||
($verbatim-content$))))))
|
||||
(if %shade-verbatim%
|
||||
(make element gi: "TABLE"
|
||||
attributes: ($shade-verbatim-attr$)
|
||||
(make element gi: "TR"
|
||||
(make element gi: "TD"
|
||||
content)))
|
||||
content)))
|
||||
|
||||
</style-specification-body>
|
||||
</style-specification>
|
||||
|
||||
<external-specification id="docbook" document="dbstyle">
|
||||
<external-specification id="docbook" document="docbook.dsl">
|
||||
</style-sheet>
|
||||
|
|
|
@ -7,9 +7,19 @@
|
|||
|
||||
The FPI for this DTD is "-//FreeBSD//DTD DocBook V3.0-Based Extension//EN"
|
||||
|
||||
$Id: freebsd.dtd,v 1.2 1998-11-03 23:38:43 nik Exp $
|
||||
$Id: freebsd.dtd,v 1.3 1998-12-20 20:33:49 nik Exp $
|
||||
-->
|
||||
|
||||
<!-- ..................................................................... -->
|
||||
<!-- Parameter entities .................................................. -->
|
||||
|
||||
<!-- These parameter entities have specific meanings, and default to
|
||||
"IGNORE". The SGML parser is free to redefine them to "INCLUDE" to
|
||||
cause special processing. -->
|
||||
|
||||
<!ENTITY % output.html "IGNORE"> <!-- HTML output is being generated -->
|
||||
<!ENTITY % output.print "IGNORE"> <!-- Print output is being generated -->
|
||||
|
||||
<!-- ..................................................................... -->
|
||||
<!-- Entities for element classes and mixtures ........................... -->
|
||||
|
||||
|
@ -20,6 +30,25 @@
|
|||
<!-- Character level classes -->
|
||||
<!ENTITY % local.tech.char.class "|HostID|Username|Devicename|MakeTarget|MakeVar">
|
||||
|
||||
<!-- Altered general entities ............................................
|
||||
|
||||
The HTML 4.0 DTD includes some new ISO entities. Most browsers don't
|
||||
support them yet. Change the definition of some of these entities to
|
||||
character strings that the browsers will support.
|
||||
|
||||
This does not apply when generating printed output, so these are
|
||||
contained within a %output.html; marked section.
|
||||
|
||||
As browser technology improves, these definitions can be removed. -->
|
||||
|
||||
<![ %output.html; [
|
||||
<!ENTITY ldquo "``">
|
||||
<!ENTITY rdquo "''">
|
||||
<!ENTITY mdash "---">
|
||||
<!ENTITY ndash "--">
|
||||
<!ENTITY hellip "...">
|
||||
<!ENTITY dollar "$">
|
||||
]]>
|
||||
|
||||
<!-- Pull in the original DTD -->
|
||||
<!ENTITY % orig-docbook PUBLIC "-//Davenport//DTD DocBook V3.0//EN">
|
||||
|
@ -107,3 +136,4 @@
|
|||
|
||||
<!ENTITY prompt.root "<prompt>#</prompt>">
|
||||
<!ENTITY prompt.user "<prompt>%</prompt>">
|
||||
|
||||
|
|
Loading…
Reference in a new issue