]> git.unchartedbackwaters.co.uk Git - francis/relativity.git/commitdiff
Increase resolution of generated formulae.
authorFrancis Russell <francis@unchartedbackwaters.co.uk>
Tue, 29 Nov 2011 11:23:19 +0000 (11:23 +0000)
committerFrancis Russell <francis@unchartedbackwaters.co.uk>
Tue, 29 Nov 2011 11:23:19 +0000 (11:23 +0000)
convert_tex4ht
tex4ht.env [new file with mode: 0644]

index b645b4e61b89be05f48610b04c2cddb3887699e1..3e30efd1cb13dbddf53dfa70b32e11eb1221c7db 100755 (executable)
@@ -6,7 +6,7 @@ OPTIONS1="xhtml,charset=utf-8"
 
 # Yes, that first whitespace character is meant to be there.
 # unicode support, generate unicode characters instead of escape codes, environment file.
-OPTIONS2=" -cunihtf -utf8"
+OPTIONS2=" -cunihtf -utf8 -e./tex4ht.env"
 
 mk4ht xhlatex ./relat10.tex "${OPTIONS1}" "${OPTIONS2}"
 ebook-convert relat10.html "Einstein - Relativity.mobi"
diff --git a/tex4ht.env b/tex4ht.env
new file mode 100644 (file)
index 0000000..cd55ba5
--- /dev/null
@@ -0,0 +1,336 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% tex4ht.env / .tex4ht (unix)           2009-01-20-20:54 %
+% Copyright (C) 1997--2009        Eitan M. Gurari        %
+% Modified                        Kapil Paranjape        %
+%                                                        %
+% This work may be distributed and/or modified under the %
+% conditions of the LaTeX Project Public License, either %
+% version 1.3 of this license or (at your option) any    %
+% later version. The latest version of this license is   %
+% in                                                     %
+%   http://www.latex-project.org/lppl.txt                %
+% and version 1.3 or later is part of all distributions  %
+% of LaTeX version 2003/12/01 or later.                  %
+%                                                        %
+% This work has the LPPL maintenance status "maintained".%
+%                                                        %
+% This Current Maintainer of this work                   %
+% is Eitan M. Gurari.                                    %
+%                                                        %
+%                             gurari@cse.ohio-state.edu  %
+%                 http://www.cse.ohio-state.edu/~gurari  %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
+%
+% Modifictions by Kapil Paranjape are tagged             %
+% <KHP_Changes> </KHP_Changes>                                           %
+%                                                        %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Notes:                                                            %
+%  1. Empty lines might be harmful                                  %
+%  2. Tagged script segments <tag>...</tag> are scanned only if     %
+%     their names are specified within -ctag switches of tex4ht.c   %
+%     and t4ht.c. When -c switches are not supplied, a -cdefault    %
+%     is implicitly assumed.                                        %
+%        The tags <tag> and </tag>, but not their bodies, are       %
+%     ignored if they are not located at the start of their lines.  %
+%  3. Place this file in your work directory and/or root directory  %
+%     and/or in directory `xxx' of your choice. In the latest case, %
+%     compile tex4ht.c and t4ht.c with `#define ENVFILE xxx', or    %
+%     provide the address of the file to tex4ht and t4ht throught   %
+%     the -e switch                                                 %
+%  4. Under kpathsea, the substring `%%~' may be employed in        %
+%     commands to indirectly obtain the value of ${SELFAUTOPARENT}. %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% * Replace `path', and possibly what follows, with appropriate     %
+%   content                                                         %
+% * A path may start with:                                          %
+%   ~ for environment variable HOME                                 %
+%   ~~ for environment variable TEX4HTTFM                           %
+%   %%~ for ${SELFAUTOPARENT} of KPATHSEA                           %
+% * A ! requests recursive search into subdirectories               %
+% * Multiple t and i entries are allowed                            %
+% * When supported by kpathsea                                      %
+%   + t entries are ignored                                         %
+%   + the path before /ht-fonts/ is ignored in i records that don't %
+%     represent real addresses                                      %
+%   + (see /usr/share/doc/tex4ht/README.kpathsea for details)
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+%
+t/usr/share/texmf/texmf/fonts/tfm/!
+%
+<default>
+i/usr/share/texmf/tex4ht/ht-fonts/iso8859/1/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+i/usr/share/texmf/tex4ht/ht-fonts/mozilla/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+</default>
+
+<mozhtf>
+i/usr/share/texmf/tex4ht/ht-fonts/mozilla/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</mozhtf>
+
+<iso2htf>
+i/usr/share/texmf/tex4ht/ht-fonts/iso8859/2/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</iso2htf>
+
+<iso5htf>
+i/usr/share/texmf/tex4ht/ht-fonts/iso8859/5/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</iso5htf>
+
+<iso7htf>
+i/usr/share/texmf/tex4ht/ht-fonts/iso8859/7/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</iso7htf>
+
+
+<iso15htf>
+i/usr/share/texmf/tex4ht/ht-fonts/iso8859/15/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</iso15htf>
+
+<koi8rhtf>
+i/usr/share/texmf/tex4ht/ht-fonts/koi/8r/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</koi8rhtf>
+
+<symhtf>
+i/usr/share/texmf/tex4ht/ht-fonts/symbol/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</symhtf>
+
+<win1251htf>
+i/usr/share/texmf/tex4ht/ht-fonts/win/1251/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</win1251htf>
+
+<unihtf>
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</unihtf>
+
+<emspkhtf>
+i/usr/share/texmf/tex4ht/ht-fonts/html-speech/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+i/usr/share/texmf/tex4ht/ht-fonts/css/emacspeak/!
+</emspkhtf>
+
+<jsmlhtf>
+i/usr/share/texmf/tex4ht/ht-fonts/jsml/!
+i/usr/share/texmf/tex4ht/ht-fonts/unicode/!
+i/usr/share/texmf/tex4ht/ht-fonts/ascii/!
+i/usr/share/texmf/tex4ht/ht-fonts/alias/!
+</jsmlhtf>
+
+%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% dvi-to-xxx                                                        %
+%   choose one G-script                                             %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% dvips options                                                     %
+%   magnification: -x mag  (e.g., -x 1200)                          %
+%   page size:     -T x,y  (e.g., -T 14in,14in)                     %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% <KHP_Changes>
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% The convert method is the upstream default method
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+<convert>
+ G.png
+ Gdvips -E -q -Ppdf -f %%1 -pp %%2 > zz%%4.ps
+ Ggs -sDEVICE=pngalpha -sOutputFile=%%3 -r110x110 -dEPSCrop -dBackgroundColor=16#ffffff -dTextAlphaBits=2 -dGraphicsAlphaBits=2 -q -dbatch -dNOPAUSE zz%%4.ps -c quit
+ Grm zz%%4.ps    
+G.svg
+Gdvips -Ppdf -mode ibmvga -D 110 -f %%1 -pp %%2 > zz%%4.eps
+Gpstoedit -f svg zz%%4.eps %%3      
+G.
+Gdvips -E -Ppdf -mode ibmvga -D 110 -f %%1 -pp %%2  > zz%%4.ps
+Gconvert -trim +repage -density 110x110 -transparent '#FFFFFF' zz%%4.ps %%3
+Grm zz%%4.ps 
+%--------- alternative instructions for old versions of convert
+% Gconvert -trim -density 110x110 -transparent "#FFFFFF" zz%%4.ps %%3
+% Gconvert -crop 0x0 +repage -density 110x110 -transparent "#FFFFFF" zz%%4.ps %%3
+% Gconvert -crop 0x0 +page -density 110x110 -transparent "#FFFFFF" zz%%4.ps %%3
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  
+</convert>
+% </KHP_Changes>
+<netpbm>
+Gdvips -Ppdf -mode ibmvga -D 110 -f %%1 -pp %%2  > zz%%4.ps
+Ggs -sDEVICE=ppm -r110 -sOutputFile=zz%%4.ppm -q -dbatch -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -dNOPAUSE zz%%4.ps -c quit
+Gmv zz%%4.ppm temp.ppm
+Gpnmcrop  temp.ppm > zz%%4.ppm
+Gpnmtopng -interlace -transparent 1,1,1 zz%%4.ppm > %%3
+ Gppmtopng -interlace -transparent 1,1,1 zz%%4.ppm > %%3
+Grm zz%%4.ps
+Grm zz%%4.ppm
+Grm temp.ppm
+% Gppmtogif -interlace -transparent 1,1,1 zz%%4.ppm > %%3 
+</netpbm>
+% <KHP_Changes>
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% This is the Debian default which uses dvipng
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+ <dvipng>
+G.png
+Gdvipng -T tight -D 166 -bg Transparent -pp %%2:%%2 %%1 -o %%3
+G.gif
+Gdvipng -T tight -D 166 -bg Transparent -gif -pp %%2:%%2 %%1 -o %%3
+G.
+Gdvips -Ppdf -mode ibmvga -D 110 -f %%1 -pp %%2 > zz%%4.ps
+Gconvert -crop 0x0 -density 110x110 -transparent '#FFFFFF' zz%%4.ps %%3
+Grm zz%%4.ps
+ </dvipng>
+% </KHP_Changes>
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Default scripts, shifted rightward 1 pos
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+ s--- needs --- %%1.idv[%%2] ==> %%3 ---
+ b--- characters ---
+ g.png
+% empty bitmaps                                                     %
+ Ecopy  empty.png %%1%%2
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+ %
+%
+% * Address for an automatically created bookkeeping file           %
+% * Ignored under kpathsea                                          %
+% * The work directory is assumed for a default                     %
+ l~/tex4ht.dir/tex4ht.fls
+%
+% t4ht -d%%2                                                        %
+Mmv %%1 %%2%%3
+Ccp %%1 %%2%%3
+% t4ht -d%%2 -m%%1                                                  %
+Achmod %%1 %%2%%3
+% removed protection                                                %
+S*
+%
+% <KHP_Changes>
+%
+<javahelp>
+.html mv %%1.html %%1.tmp
+.html java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s javahelp.4xt -o %%1.html %%1.tmp
+.jhm echo "java -jar ${HOME}/jh2.0/javahelp/bin/jhindexer.jar -db %%0-doc/%%1-jhs %%1*.html"
+.jhm echo "--- Warning ---  Beware of leftover %%1*.html files from other compilations"
+.jhm java -jar ${HOME}/jh2.0/javahelp/bin/jhindexer.jar -db %%0-doc/%%1-jhs %%1*.html
+</javahelp>
+<javahelp1>
+.jhm java -jar ${HOME}/jh1.1.3/javahelp/bin/jhindexer.jar -db %%0-doc/%%1-jhs %%1*.html
+</javahelp1>
+
+<emspk>
+.html mv %%1.html %%1.tmp
+.html java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -o %%1.html %%1.tmp
+</emspk>
+
+<jsml>
+.jsml mv %%1.jsml %%1.tmp
+.jsml java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -o %%1.jsml %%1.tmp
+</jsml>
+
+<docbk>
+.xml cp %%1.xml %%1.tmp
+.xml java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -o %%1.xml %%1.tmp
+</docbk>
+
+<xhtml>
+.html mv %%1.html %%1.tmp
+.html java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtml.4xt -o %%1.html %%1.tmp
+.xht mv %%1.xht %%1.tmp
+.xht java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtml.4xt -o %%1.xht %%1.tmp
+.xml mv %%1.xml %%1.tmp
+.xml java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtml.4xt -o %%1.xml %%1.tmp
+</xhtml>
+
+<xhtmml>
+.html mv %%1.html %%1.tmp
+.html java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtmml.4xt -o %%1.html %%1.tmp
+.xht mv %%1.xht %%1.tmp
+.xht java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtmml.4xt -o %%1.xht %%1.tmp
+.xml mv %%1.xml %%1.tmp
+.xml java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -s xhtmml.4xt -o %%1.xml %%1.tmp
+</xhtmml>
+<ooxtpipes>
+.4oo mv %%0.4oo %%0.tmp
+.4oo java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -o %%0.4oo %%0.tmp
+.4om mv %%1.4om %%1.tmp
+.4om java -classpath /usr/share/tex4ht/tex4ht.jar xtpipes -i /usr/share/texmf/tex4ht/xtpipes/ -o %%1.4om %%1.tmp
+</ooxtpipes>
+ %
+ % </KHP_Changes>
+ %
+%
+<validatehtml>
+ .html xmllint --noout --valid --html %%1.html
+</validatehtml>
+<validate>
+ .xml xmllint --noout --valid %%1.xml
+ .html xmllint --noout --valid %%1.html
+ .css mycssparser %%1.css
+</validate>
+ %
+<oo>
+%%% openoffice                                                      %
+.4oo mkdir -p sxw-%%0.dir
+.4os mkdir -p sxw-%%0.dir/Pictures
+.4os mv    %%1.4os         sxw-%%0.dir/settings.xml
+.4oo mv    %%0.4oo         sxw-%%0.dir/content.xml
+%                                                                   %
+.4om mkdir sxw-%%0.dir/%%1
+.4om mv    %%1.4om         sxw-%%0.dir/%%1/content.xml
+.4om cp    sxw-%%0.dir/settings.xml  sxw-%%0.dir/%%1/settings.xml
+%                                                                   %
+.4of mkdir -p sxw-%%0.dir/META-INF
+.4of mv    %%1.4of         sxw-%%0.dir/META-INF/manifest.xml
+%                                                                   %
+.4ot mv    %%1.4ot         sxw-%%0.dir/meta.xml
+.4oy mv    %%1.4oy         sxw-%%0.dir/styles.xml
+% .4og cp  --parents %%1   Pictures
+.4og mkdir -p              sxw-%%0.dir/Pictures/%%1
+.4og rmdir                 sxw-%%0.dir/Pictures/%%1
+.4og cp    %%1             sxw-%%0.dir/Pictures/%%1
+%-- sxw --                                                          %
+.4ox cd sxw-%%0.dir; zip -r %%0.sxw * ; cd ..
+%                                                                   %
+.4ox mv    sxw-%%0.dir/%%0.sxw .
+%                                                                   %
+.4ox rm    %%1.4ox
+.4ox rm -r -f sxw-%%0.dir
+%-- odt --                                                          %
+.4od cd sxw-%%0.dir; zip -r %%0.odt * ; cd ..
+%                                                                   %
+.4od mv    sxw-%%0.dir/%%0.odt .
+%                                                                   %
+.4od rm    %%1.4od
+.4od rm -r -f sxw-%%0.dir
+%%% end openoffice                                                  %
+</oo>
+%
+% end of file                                                       %
+