| 1 |
<?xml version="1.0" encoding="iso-8859-1" ?> |
| 2 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" |
| 3 |
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 4 |
<!--http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd--> |
| 5 |
<html xmlns="http://www.w3.org/1999/xhtml" |
| 6 |
> |
| 7 |
<head><title>MS Windows</title> |
| 8 |
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> |
| 9 |
<meta name="generator" content="TeX4ht (https://tug.org/tex4ht/)" /> |
| 10 |
<meta name="originator" content="TeX4ht (https://tug.org/tex4ht/)" /> |
| 11 |
<!-- xhtml,th4,index --> |
| 12 |
<meta name="src" content="mn.tex" /> |
| 13 |
<link rel="stylesheet" type="text/css" href="mn.css" /> |
| 14 |
<meta name="viewport" content="width=device-width, initial-scale=1" /> |
| 15 |
</head><body |
| 16 |
> |
| 17 |
<a |
| 18 |
href="mn.html#mn28.html" >exit MS Windows</a> |
| 19 |
<h3 class="SubSectionHead"><a |
| 20 |
name="QQ1-28-70"></a>A Setup for MS Windows</h3> |
| 21 |
<ol type="a" > |
| 22 |
<li> <a |
| 23 |
name="index28-70001"></a>Establish a directory, say, ‘<span class="cmtt-10">c:\tex4ht</span>’. |
| 24 |
<!--l. 7684--><p class="noindent" ></p></li> |
| 25 |
<li> <a |
| 26 |
name="index28-70002"></a>Download the file <a |
| 27 |
href="tex4ht.zip" >tex4ht.zip</a> into the directory <span class="cmtt-10">tex4ht.dir </span>and unzip it. |
| 28 |
<p class="rightline"><span class="cmbx-10">Update the Pointers in the Environment File</span></p> |
| 29 |
<!--l. 7710--><p class="noindent" ></p></li> |
| 30 |
<li> <a |
| 31 |
name="index28-70003"></a> <a |
| 32 |
name="index28-70004"></a>Replace in <a |
| 33 |
href="tex4ht-env-win32.txt" ><span class="cmtt-10">c:\tex4ht\texmf\tex4ht\base\win32\tex4ht.env</span></a> the lines starting with the character ‘<span class="cmtt-10">t</span>’, with |
| 34 |
alternative lines which state what directories should be searched for the tfm files of TeX and LaTeX. The directory |
| 35 |
names must be preceded with the character ‘<span class="cmtt-10">t</span>’ at the first column. If their subdirectories are also to be searched, the |
| 36 |
names should be appended with the character ‘<span class="cmtt-10">!</span>’. |
| 37 |
<!--l. 7723--><p class="indent" > Note that long file names on MS Windows, and file names with spaces, might have short space-free aliases. For |
| 38 |
instance, a directory name ‘<span class="cmtt-10">c:\progra~1\texmf</span>’ instead of ‘<span class="cmtt-10">c:\program files\texmf</span>’. The alternative names can |
| 39 |
be checked by issuing the ‘<span class="cmtt-10">dir</span>’ command in a DOS session. |
| 40 |
</p><!--l. 7730--><p class="noindent" ></p></li> |
| 41 |
<li> <a |
| 42 |
name="index28-70005"></a>If needed, adjust the paths in the ‘<span class="cmtt-10">i</span>’ records of <span class="cmtt-10">tex4ht.env</span>. These records are used for searching htf fonts, and |
| 43 |
they are similar to the ‘<span class="cmtt-10">t</span>’ records. |
| 44 |
<p class="rightline"><span class="cmbx-10">Update the Bitmap Generating Scripts</span></p> |
| 45 |
<!--l. 7744--><p class="noindent" ></p></li> |
| 46 |
<li> <a |
| 47 |
name="index28-70006"></a>The file <span class="cmtt-10">tex4ht.env </span>contains the following default script, of calls to system utilities for translating dvi pictures into |
| 48 |
png. |
| 49 |
<div class="Verbatim"><span class="cmtt-10">Gif</span><span class="cmtt-10"> exist</span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> DEL</span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> >nul</span><span class="cmtt-10"> </span> |
| 50 |
<br /><span class="cmtt-10">Gif</span><span class="cmtt-10"> exist</span><span class="cmtt-10"> %%3</span><span class="cmtt-10"> DEL</span><span class="cmtt-10"> %%3</span><span class="cmtt-10"> >nul</span><span class="cmtt-10"> </span> |
| 51 |
<br /><span class="cmtt-10">Gdvips</span><span class="cmtt-10"> -E</span><span class="cmtt-10"> -Ppdf</span><span class="cmtt-10"> -mode</span><span class="cmtt-10"> ibmvga</span><span class="cmtt-10"> -D</span><span class="cmtt-10"> 110</span><span class="cmtt-10"> -f</span><span class="cmtt-10"> %%1</span><span class="cmtt-10"> -pp</span><span class="cmtt-10"> %%2</span><span class="cmtt-10"> ></span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> </span> |
| 52 |
<br /><span class="cmtt-10">Gconvert</span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> -trim</span><span class="cmtt-10"> +repage</span><span class="cmtt-10"> -density</span><span class="cmtt-10"> 110x110</span><span class="cmtt-10"> -transparent</span><span class="cmtt-10"> "#FFFFFF"</span><span class="cmtt-10"> %%3</span><span class="cmtt-10"> </span> |
| 53 |
<br /><span class="cmtt-10">Gif</span><span class="cmtt-10"> exist</span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> DEL</span><span class="cmtt-10"> zz%%4.ps</span><span class="cmtt-10"> >nul</span><span class="cmtt-10"> </span> |
| 54 |
<br /></div> |
| 55 |
<!--l. 7757--><p class="indent" > You may replace this script with an alternative sequence of system calls. In such a case, place one command per |
| 56 |
line, and mark each of these lines with the character ‘<span class="cmtt-10">G</span>’ at the first column. The literate version tex4ht-env.tex of |
| 57 |
tex4ht.env offers a few suggestions. |
| 58 |
</p><!--l. 7763--><p class="indent" > The entry <span class="cmtt-10">%%1 </span>is a parameter referring to a dvi file, the <span class="cmtt-10">%%2 </span>is a parameter indicating a page |
| 59 |
number, the <span class="cmtt-10">%%3 </span>is a parameter standing for an output file name, and <span class="cmtt-10">%%4 </span>is a parameter providing the |
| 60 |
jobname. |
| 61 |
</p><!--l. 7772--><p class="indent" > The <a |
| 62 |
href="http://www.radicaleye.com/dvips.html" >dvips</a> utility translates dvi files into postscript. The <span class="cmtt-10">convert </span>utility, provided within the distribution of |
| 63 |
<a |
| 64 |
href="http://www.imagemagick.org/" >ImageMagick</a>, translates postscript files into png. |
| 65 |
</p><!--l. 7778--><p class="indent" > The script employs the Metafont mode ‘<span class="cmtt-10">ibmvga</span>’ of resolution ‘<span class="cmtt-10">110</span>’; the available modes are listed in file |
| 66 |
<span class="cmtt-10">modes.mf </span>of Metafont. |
| 67 |
</p><!--l. 7783--><p class="indent" > Use the option ‘<span class="cmtt-10">-crop 0x0 +page</span>’ or ‘<span class="cmtt-10">-crop 0x0 +repage</span>’ instead of ‘<span class="cmtt-10">-trim</span>’ for old convert utilities that do |
| 68 |
not recognize the latter argument. |
| 69 |
</p><!--l. 7787--><p class="noindent" ></p></li> |
| 70 |
<li>Instead of employing the G scripts, glyphs can rely on specialized <a |
| 71 |
href="mn29.html" name="mn29.html" >F scripts</a> of similar nature for creating pngs. |
| 72 |
<!--l. 7806--><p class="noindent" ></p></li> |
| 73 |
<li> <a |
| 74 |
name="index28-70007"></a> <a |
| 75 |
name="index28-70008"></a> <a |
| 76 |
name="index28-70009"></a> <a |
| 77 |
name="index28-70010"></a>The bitmap formats can be controlled by a ‘g’ record of tex4ht.env, a ‘-g’ switch of <span class="cmtt-10">tex4ht.c</span>, and a -LGTYP |
| 78 |
switch in the compilation of tex4ht.c. The default setting assumes the ‘png’ format. |
| 79 |
<p class="rightline"><span class="cmbx-10">Update the Other Scripts in the Environment File</span></p> |
| 80 |
<!--l. 7820--><p class="noindent" ></p></li> |
| 81 |
<li>If needed, replace the scripts ‘<span class="cmtt-10">Mmove %%1 %%2%%3</span>’, and ‘<span class="cmtt-10">Ccopy %%1 %%2%%3</span>’ in <span class="cmtt-10">tex4ht.env </span>with <a |
| 82 |
href="mn30.html" name="mn30.html" >alternative |
| 83 |
scripts</a> for moving and copying files. The parameter <span class="cmtt-10">%%1 </span>stands for the source file(s), the parameter <span class="cmtt-10">%%2 </span>provides the |
| 84 |
target directory name, and the parameter <span class="cmtt-10">%%3 </span>refers to the target file name(s). |
| 85 |
<!--l. 7846--><p class="noindent" ></p></li> |
| 86 |
<li>If applicable, replace the scripts ‘<span class="cmtt-10">Achmod %%1 %%2%%3</span>’ in <span class="cmtt-10">tex4ht.env </span>with an alternative script for changing the |
| 87 |
access mode of files. The parameter <span class="cmtt-10">%%1 </span>stands for access mode, the parameter <span class="cmtt-10">%%2 </span>refers to a directory name, and |
| 88 |
the parameter <span class="cmtt-10">%%3 </span>refers to the file(s). |
| 89 |
<!--l. 7854--><p class="noindent" ></p></li> |
| 90 |
<li> <a |
| 91 |
name="index28-70011"></a>Postprocessing of files can be requested with ‘<span class="cmtt-10">.</span>’ scripts. The files are selected by their extension names, as listed |
| 92 |
following the period symbols. The parameter ‘<span class="cmtt-10">%%1</span>’ provides the file names, and the parameter ‘<span class="cmtt-10">%%0</span>’ provides the |
| 93 |
jobnames. |
| 94 |
<!--l. 7862--><p class="indent" > The environment file <a |
| 95 |
href="tex4ht-env-win32.txt" >tex4ht.env</a> offers the following draft of a dot script for <span class="cmbx-10">validating </span>output of |
| 96 |
compilations. |
| 97 |
</p><div class="Verbatim"><span class="cmtt-10"><validate></span><span class="cmtt-10"> </span> |
| 98 |
<br /><span class="cmtt-10"> .xml</span><span class="cmtt-10"> xmllint</span><span class="cmtt-10"> --noout</span><span class="cmtt-10"> --valid</span><span class="cmtt-10"> %%1.xml</span><span class="cmtt-10"> </span> |
| 99 |
<br /><span class="cmtt-10"> .html</span><span class="cmtt-10"> xmllint</span><span class="cmtt-10"> --noout</span><span class="cmtt-10"> --valid</span><span class="cmtt-10"> %%1.html</span><span class="cmtt-10"> </span> |
| 100 |
<br /><span class="cmtt-10"> .css</span><span class="cmtt-10"> mycssparser</span><span class="cmtt-10"> %%1.css</span><span class="cmtt-10"> </span> |
| 101 |
<br /><span class="cmtt-10"></validate></span><span class="cmtt-10"> </span> |
| 102 |
<br /></div> |
| 103 |
<!--l. 7877--><p class="indent" > The dot script may be activated in the following manner. |
| 104 |
</p><!--l. 7879--><p class="indent" > |
| 105 |
</p><ol type="1" > |
| 106 |
<li>Fix the paths in the first two records. |
| 107 |
<!--l. 7883--><p class="noindent" ></p></li> |
| 108 |
<li>Bind a CSS validator to the .css record. (<a |
| 109 |
href="http://jigsaw.w3.org/css-validator/DOWNLOAD.html" ><span class="cmtt-10">http://jigsaw.w3.org/css-validator/DOWNLOAD.html</span></a>) |
| 110 |
<!--l. 7889--><p class="noindent" ></p></li> |
| 111 |
<li>Remove the leading space characters from the above record. |
| 112 |
</li></ol> |
| 113 |
<!--l. 7903--><p class="noindent" ></p></li> |
| 114 |
<li>Postprocessing of files can also be requested with ‘<span class="cmtt-10">X</span>’ scripts. The file names are accessed through the parameter |
| 115 |
‘<span class="cmtt-10">%%1</span>’, and their extensions through the parameter ‘<span class="cmtt-10">%%2</span>’. |
| 116 |
<p class="rightline"><span class="cmbx-10">Set the Script Files</span></p> |
| 117 |
<!--l. 7911--><p class="noindent" ></p></li> |
| 118 |
<li>If you use a command different than ‘<span class="cmtt-10">latex</span>’ for compiling LaTeX source files, replace the references to <span class="cmtt-10">latex </span>in |
| 119 |
<span class="cmtt-10">c:\tex4ht\bin\win32\*.bat </span>with the appropriate command name. The <span class="cmtt-10">tex </span>and <span class="cmtt-10">texi </span>commands require similar |
| 120 |
attention. |
| 121 |
<p class="rightline"><span class="cmbx-10">Make the System Globally Known</span></p> </li> |
| 122 |
<li>Add ‘<span class="cmtt-10">c:\tex4ht\bin\win32</span>’ to your path variable in ‘<span class="cmtt-10">c:\AUTOEXEC.BAT</span>’. |
| 123 |
<!--l. 7924--><p class="noindent" ></p></li> |
| 124 |
<li>Place the files ‘<span class="cmtt-10">tex4ht.sty</span>’ and ‘<span class="cmtt-10">*.4ht</span>’ of <span class="cmtt-10">c:\texmf\tex\generic\tex4ht\ </span>within the LaTeX/TeX tree (either by |
| 125 |
moving the files to a directory which already has sty files, or by modifying the environment variable TEXINPUTS to |
| 126 |
point also to ‘<span class="cmtt-10">c:\texmf\tex\generic\tex4ht\</span>’). |
| 127 |
<!--l. 7931--><p class="noindent" ></p></li> |
| 128 |
<li>If your TeX system uses a database to locate files, make sure to refresh it (e.g., select <span class="cmtt-10">Start -> Programs -></span> |
| 129 |
<span class="cmtt-10">MiKTeX -> Refresh</span>, or run ‘<span class="cmtt-10">initexmf -u</span>’ from a DOS session, to update MiKTeX). |
| 130 |
<p class="rightline"><span class="cmbx-10">Didn’t Use ’</span><span class="cmtt-10">c:\tex4ht’</span><span class="cmbx-10">?</span></p> </li> |
| 131 |
<li>If TeX4ht is installed in a directory other than <span class="cmtt-10">c:\tex4ht</span>, make sure to adjust the related paths in <span class="cmtt-10">tex4ht.env </span>the |
| 132 |
<span class="cmtt-10">.bat </span>files. |
| 133 |
<!--l. 7945--><p class="noindent" ></p></li> |
| 134 |
<li>Some output modes assume <a |
| 135 |
href="http://www.sun.com/" >Java</a> is also available in the computer in use. |
| 136 |
<p class="rightline"><span class="cmbx-10">Test the Installation</span></p> </li> |
| 137 |
<li>Move <span class="cmtt-10">testa.tex </span>and <span class="cmtt-10">testb.tex </span>from <span class="cmtt-10">c:\tex4ht.dir\temp\ </span>to your work directory </li> |
| 138 |
<li>Compile ‘<span class="cmtt-10">testa.tex</span>’ with the command ‘<span class="cmtt-10">ht latex testa</span>’ </li> |
| 139 |
|
| 140 |
<li>Compile ‘<span class="cmtt-10">testb.tex</span>’ with the command ‘<span class="cmtt-10">htlatex testb</span>’ |
| 141 |
</li></ol> |
| 142 |
<!--l. 7967--><p class="indent" > [<a |
| 143 |
href="http://www.csulb.edu/~murdock/dosindex.html" >MS Commands</a>] |
| 144 |
|
| 145 |
</p> |
| 146 |
<hr /> |
| 147 |
<!--l. 7972--><p class="indent" > <small>Generated August 24, 2020 - <a href="/tex4ht/">tex4ht home page</a></small></p> |
| 148 |
</body></html> |