nixpkgs docs: Use SVGs for callouts
This commit is contained in:
parent
2b3ba40c03
commit
a80856cec5
10
doc/Makefile
10
doc/Makefile
|
@ -17,7 +17,7 @@ validate: manual-full.xml
|
||||||
|
|
||||||
out/html/index.html: manual-full.xml style.css
|
out/html/index.html: manual-full.xml style.css
|
||||||
mkdir -p out/html
|
mkdir -p out/html
|
||||||
xsltproc $$xsltFlags \
|
xsltproc ${xsltFlags} \
|
||||||
--nonet --xinclude \
|
--nonet --xinclude \
|
||||||
--output $@ \
|
--output $@ \
|
||||||
"$$XSL/docbook/xhtml/docbook.xsl" \
|
"$$XSL/docbook/xhtml/docbook.xsl" \
|
||||||
|
@ -26,17 +26,19 @@ out/html/index.html: manual-full.xml style.css
|
||||||
cp ./style.css out/html/style.css
|
cp ./style.css out/html/style.css
|
||||||
|
|
||||||
mkdir -p out/html/images/callouts
|
mkdir -p out/html/images/callouts
|
||||||
cp "$$XSL/docbook/images/callouts/"*.gif out/html/images/callouts/
|
cp "$$XSL/docbook/images/callouts/"*.svg out/html/images/callouts/
|
||||||
chmod u+w -R out/html/images/
|
chmod u+w -R out/html/images/
|
||||||
|
|
||||||
out/epub/manual.epub: manual-full.xml
|
out/epub/manual.epub: manual-full.xml
|
||||||
mkdir -p out/epub/scratch
|
mkdir -p out/epub/scratch
|
||||||
xsltproc $$xsltFlags --nonet \
|
xsltproc ${xsltFlags} --nonet \
|
||||||
--output out/epub/scratch/ \
|
--output out/epub/scratch/ \
|
||||||
"$$XSL/docbook/epub/docbook.xsl" \
|
"$$XSL/docbook/epub/docbook.xsl" \
|
||||||
./manual-full.xml
|
./manual-full.xml
|
||||||
|
|
||||||
cp "$$XSL/docbook/images/callouts/"*.gif out/epub/scratch/OEBPS
|
cp ./style.css out/epub/scratch/OEBPS
|
||||||
|
mkdir -p out/epub/scratch/OEBPS/images/callouts/
|
||||||
|
cp "$$XSL/docbook/images/callouts/"*.svg out/epub/scratch/OEBPS/images/callouts/
|
||||||
echo "application/epub+zip" > mimetype
|
echo "application/epub+zip" > mimetype
|
||||||
zip -0Xq "out/epub/manual.epub" mimetype
|
zip -0Xq "out/epub/manual.epub" mimetype
|
||||||
rm mimetype
|
rm mimetype
|
||||||
|
|
|
@ -16,11 +16,11 @@ pkgs.stdenv.mkDerivation {
|
||||||
xsltFlags = lib.concatStringsSep " " [
|
xsltFlags = lib.concatStringsSep " " [
|
||||||
"--param section.autolabel 1"
|
"--param section.autolabel 1"
|
||||||
"--param section.label.includes.component.label 1"
|
"--param section.label.includes.component.label 1"
|
||||||
"--param html.stylesheet 'style.css'"
|
"--stringparam html.stylesheet 'style.css'"
|
||||||
"--param xref.with.number.and.title 1"
|
"--param xref.with.number.and.title 1"
|
||||||
"--param toc.section.depth 3"
|
"--param toc.section.depth 3"
|
||||||
"--param admon.style ''"
|
"--stringparam admon.style ''"
|
||||||
"--param callout.graphics.extension '.gif'"
|
"--stringparam callout.graphics.extension .svg"
|
||||||
];
|
];
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
|
|
|
@ -118,6 +118,14 @@ div.example pre.programlisting
|
||||||
margin: 0 0 0 0;
|
margin: 0 0 0 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.programlisting img {
|
||||||
|
width: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.calloutlist img {
|
||||||
|
width: 1.5em;
|
||||||
|
}
|
||||||
|
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
Notes, warnings etc:
|
Notes, warnings etc:
|
||||||
|
|
Loading…
Reference in New Issue