Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456 Preparing LaTeX documents for the World-Wide Web
Hyperlinks and bookmarks were automatically added by
using the hypperref latex style package. Try it. When
you see "as shown in Figure 1", click on the 1
and you will be taken to Figure 1.
The colored boxes show the hyperlinks (the boxes
do not print).
You can
get the hyperref package from directory
macros/latex/contrib/supported/hyperref
of any
CTAN archive.
LaTeX style files
A number of people have worked to
produce LaTeX style files that
produce documents formatted appropriately for ACM Transactions.
The files avaiable are:
In preparing a latex document for distribution on the world-wide web,
the first question is the format in which you which to distribute it. You
have several options:
HTML
In this case, you probably want to use the tool latex2html.
This tool does a fairly good job of converting the content of a latex document
to HTML, but the result only has a faint resemblence to the apperence of
your original document (which is appropriate, since HTML doesn't describe
apperence). A big advantage of this is that is can be read on pretty much
any WWW browser (including text-only browsers, such as lynx).
postscript
postscript was developed as a format for sending documents to
printers. There are a fair number of issues involved in generating portable
postscript, some of which are described in a seperate
document. Postscript works fairly well if you just download it in order
to print it out. To view postscript on-screen, you need special tools such
as ghostview. Ghostview works
fairly well once it is set-up, but it a fairly difficult process to set
it up on your own personal computer.
PDF - portable document format
PDF is a postscript variant which is designed to allow on-screen
viewing. You can print a PDF document from a PDF viewer. There are a number
of tools for converting between PDF and postscript, including Adobe's Distiller
(part of the full Adobe Acrobat package). PDF can be enriched with a number
of additional features, such as thumbnails, bookmarks, hyperlinks, and
there are freely available viewers available from Adobe, as well as plug-ins
for WWW browsers. The viewing software somewhat more polished than ghostview
and easy to install on personal computers.
Font options
When generating postscript from latex, you have several options about
how to describe the fonts. Most LaTeX documents use the Computer Modern
fonts developed by Donald Knuth. These fonts are rarely used outside of
TeX.
Embedded font bitmaps
This is usually the default method of handling fonts. The generated
postscript file contains bitmap representation of the fonts used in the
document. One critical issue is the resolution of the bitmaps. This is
very installation dependent, but is often 300 dots/inch. If your postscript
is generated with 300 dots/inch bitmap fonts, then you will see little
or no improvement when printing your document on a 600 dots/inch laserprinter,
compared with a 300 dot/inch laserprinter. Another problem with bitmap
fonts is that when the document is shown on screen, the bitmaps need to
be scaled or shrunk by uneven multiples, which often leads to a very poor
apperence.
Embedded postscript fonts
You can embed actual postscript fonts in the postscript for your document.
This produces the best apperence for both screen and printing. However,
there are several drawbacks.
Until recently, there were no public domain postscript versions of
TeX's Computer Modern fonts. There are a number of commerical postscript
versions of Computer Modern (but they are not free). Even if you were willing
to pay for them, there is another problem. Legally, distributting a postscript
document that contains a font is the same as distributing the font itself.
It is possible to avoid this problem by subsetting the fonts: only distributting
a partial copy of the font (which contains only the characters used). Both
Distiller and dvips can perform font subsetting. Sources of Computer Modern
fonts:
BaKoMa fonts - available from the directory
fonts/postscript/bakoma of a
CTAN archive.
Blue sky fonts
The resulting postscript files are much larger. In addition to the
normal increases caused by font inclusion, Computer Modern comes in several
different optical sizes (each with there own postscript description). Optical
size for a font means that fonts that are intended for small visual size
have a simplified, more robust appereance, compared with fonts designed
for large visual size, which can have thin, delicate serifs. Much of this
size increase can be eliminated by using font subsetting, and by either
using compressed postscript, or pdf (which has built-in compression).
Omitted fonts
You can generate postscript from latex that doesn't contain font descriptions,
just font names. Since few tools and no printers come with the computer
modern fonts installed, this is strongly discouraged if you are using Computer
Modern fonts. If you change the font selection so that you are using fonts
such as Times Roman and Helvetica, this is reasonable.
Getting dvips to refrain from embedding bitmap fonts
This document describes how to get
dvips
to generate
postscript files that do not contain embedded bitmap fonts.
A more detailed explaination of this process is
given by a document on Adobe's website.
This is intended to be a shorter description that doesn't explain
the process as much.
The font substitution list
You need to create a font substitution list file for use by dvips.
Each line of this file starts with the name of a font as
used within TeX, such as cmb10. The rest of the line can contain:
nothing - the generated postscript will just contain
references the the named font
white space, followed by a name (such as CMB10) -
- the generated postscript will just contain
references the the second name
while space, followed by a <, followed by a file name -
the file name should be a type 1 encoding of the postscript
font in PFB or PFA format.
Specifying a font substitution list
If your home directory contains a file .dvipsrc
containing a line:
p +fontMapFileName
that font map will be used for all dvips jobs you run.
Alternatively, you can create a file such config.embed
which contains the same line. Then, when you invoke dvips with
the command dvips -P embed ... , it will look for
config.embed in the current directory (and perhaps your home directory).
How dvips looks for config files is dependent on your installation
and can be changed using the TEXCONFIG environment variable
as described in the "Environment Variables" section
of the dvips documentation.
Font appearence
Font
1x magnification
8x magnification
300 dots/inch bitmap fonts
600 dots/inch bitmap fonts
Type 1 postscript fonts
File size
This table shows the file sizes
for a 41 page LaTeX document prepared using the ACM transactions
style file.