lol

Merge pull request #37881 from grahamc/doc/svg-callouts

nixpkgs docs: Use SVGs for callouts

authored by

Graham Christensen and committed by
GitHub
63406fa1 83624b97

+24 -13
+8 -4
doc/Makefile
··· 17 17 18 18 out/html/index.html: manual-full.xml style.css 19 19 mkdir -p out/html 20 - xsltproc $$xsltFlags \ 20 + xsltproc ${xsltFlags} \ 21 21 --nonet --xinclude \ 22 22 --output $@ \ 23 23 "$$XSL/docbook/xhtml/docbook.xsl" \ 24 24 ./manual-full.xml 25 25 26 + cp ./overrides.css out/html/ 26 27 cp ./style.css out/html/style.css 27 28 28 29 mkdir -p out/html/images/callouts 29 - cp "$$XSL/docbook/images/callouts/"*.gif out/html/images/callouts/ 30 + cp "$$XSL/docbook/images/callouts/"*.svg out/html/images/callouts/ 30 31 chmod u+w -R out/html/images/ 31 32 32 33 out/epub/manual.epub: manual-full.xml 33 34 mkdir -p out/epub/scratch 34 - xsltproc $$xsltFlags --nonet \ 35 + xsltproc ${xsltFlags} --nonet \ 35 36 --output out/epub/scratch/ \ 36 37 "$$XSL/docbook/epub/docbook.xsl" \ 37 38 ./manual-full.xml 38 39 39 - cp "$$XSL/docbook/images/callouts/"*.gif out/epub/scratch/OEBPS 40 + cp ./overrides.css out/epub/scratch/OEBPS 41 + cp ./style.css out/epub/scratch/OEBPS 42 + mkdir -p out/epub/scratch/OEBPS/images/callouts/ 43 + cp "$$XSL/docbook/images/callouts/"*.svg out/epub/scratch/OEBPS/images/callouts/ 40 44 echo "application/epub+zip" > mimetype 41 45 zip -0Xq "out/epub/manual.epub" mimetype 42 46 rm mimetype
+3 -3
doc/default.nix
··· 16 16 xsltFlags = lib.concatStringsSep " " [ 17 17 "--param section.autolabel 1" 18 18 "--param section.label.includes.component.label 1" 19 - "--param html.stylesheet 'style.css'" 19 + "--stringparam html.stylesheet 'style.css overrides.css'" 20 20 "--param xref.with.number.and.title 1" 21 21 "--param toc.section.depth 3" 22 - "--param admon.style ''" 23 - "--param callout.graphics.extension '.gif'" 22 + "--stringparam admon.style ''" 23 + "--stringparam callout.graphics.extension .svg" 24 24 ]; 25 25 26 26 postPatch = ''
+8
doc/overrides.css
··· 1 + 2 + .programlisting img { 3 + width: 1em; 4 + } 5 + 6 + .calloutlist img { 7 + width: 1.5em; 8 + }
+5 -6
doc/style.css
··· 29 29 } 30 30 31 31 /* Extra space between chapters, appendices. */ 32 - div.chapter > div.titlepage h2, div.appendix > div.titlepage h2 33 - { 32 + div.chapter > div.titlepage h2, div.appendix > div.titlepage h2 33 + { 34 34 margin-top: 1.5em; 35 35 } 36 36 ··· 118 118 margin: 0 0 0 0; 119 119 } 120 120 121 - 122 121 /*************************************************************************** 123 122 Notes, warnings etc: 124 123 ***************************************************************************/ ··· 172 171 173 172 174 173 /*************************************************************************** 175 - Links colors and highlighting: 174 + Links colors and highlighting: 176 175 ***************************************************************************/ 177 176 178 177 a { text-decoration: none; } ··· 209 208 .term 210 209 { 211 210 font-weight: bold; 212 - 211 + 213 212 } 214 213 215 214 div.variablelist dd p, div.glosslist dd p ··· 252 251 div.affiliation 253 252 { 254 253 font-style: italic; 255 - } 254 + }