diff options
Diffstat (limited to 'Master/texmf-dist/doc/dvipdfmx')
-rw-r--r-- | Master/texmf-dist/doc/dvipdfmx/dvipdfmx.pdf | bin | 0 -> 183084 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/dvipdfmx/dvipdfmx.tex | 1279 | ||||
-rw-r--r-- | Master/texmf-dist/doc/dvipdfmx/fdl-1.3.txt | 451 |
3 files changed, 1730 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.pdf b/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.pdf Binary files differnew file mode 100644 index 00000000000..3a9ac317fa3 --- /dev/null +++ b/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.pdf diff --git a/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.tex b/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.tex new file mode 100644 index 00000000000..df6c7cabe9e --- /dev/null +++ b/Master/texmf-dist/doc/dvipdfmx/dvipdfmx.tex @@ -0,0 +1,1279 @@ +\documentclass[a4paper,xetex]{article} +\usepackage{xltxtra} +\usepackage{fontspec} +\usepackage{microtype} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%% PLATFORM DEPENDENT INSTRUCTION HERE +%% Font setup for body text. +\setmainfont{Constantia} +\setsansfont{Cambria} +\setmonofont[Scale=0.92]{Consolas}% Adjust xheight difference +%% The following section is for showing some fancy examples. +%% Some fonts used here may not be availabel on your system. +%% Please modify this. Just replacing with empty macros is OK. +\newcommand{\jpzerofourexamples}{{% +\setmainfont[Scale=5,RawFeature=+jp04]{SourceHanSerifJP-Light.otf}葛祇逢}} +\newcommand{\jpninezeroexamples}{{% +\setmainfont[Scale=5,RawFeature=+jp90]{SourceHanSerifJP-Light.otf}葛祇逢}} +%% We use PostScript raw code here to test dvipdfmx's capability. +%% TFM files `rml' and `rmlv' are distributed with ASCII pTeX. +%% TrueType font `yumindb.ttf' is bundled with Windows 10. +\newcommand{\jphoritext}{% +\makebox[112bp][l]{% +\raisebox{88bp}[112bp][0bp]{% +\special{pdf:mapline rml UniJIS-UTF8-H yumindb.ttf} +\special{ps: rml findfont 16 scalefont setfont + currentpoint moveto (「こんにちは」) show}% +}}} +\newcommand{\jpverttext}{% +\makebox[16bp][l]{% +\raisebox{112bp}[112bp][0bp]{% +\special{pdf:mapline rmlv UniJIS-UTF8-V yumindb.ttf} +\special{ps: rmlv findfont 16 scalefont setfont + currentpoint moveto (「こんにちは」) show}% +}}} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\usepackage{xcolor,hyperref,hyperxmp} +\hypersetup{% + bookmarksnumbered=true,% + colorlinks=true,% + urlcolor=[rgb]{0.2,0.2,0.4}, + linkcolor=[rgb]{0.2,0.2,0.4}, + pdftitle={The Dvipdfmx User's Manual},% + pdfauthor={The dvipdfmx project team},% + pdfsubject={A User's Manual for Dvipdfmx and Xdvipdfmx.},% + pdfkeywords={dvipdfmx, XeTeX, TeX, LaTeX}, + pdflang=en, + pdfcopyright={Copyright © The dvipdfmx project team. + Permission is granted to copy, distribute and/or modify this document + under the terms of the GNU Free Documentation License, Version 1.3 + or any later version published by the Free Software Foundation; + with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. + A copy of the license is included in the section entitled "GNU + Free Documentation License".}, + pdflicenseurl={http://www.gnu.org/licenses/fdl.html} +} +\usepackage{listings} +\lstset{ + keepspaces=true, + basicstyle={\ttfamily}, + frame={tb}, + breaklines=true, + columns=[l]{fullflexible}, + numbers=none, + xrightmargin=2em, + xleftmargin=2em, + aboveskip=2em, + belowskip=2em +} +\usepackage{mflogo} +\usepackage{marginnote} +\renewcommand*{\marginfont}{\footnotesize\itshape} +\usepackage[noorphans,font=itshape]{quoting} +\newcommand{\package}[1]{{\itshape #1}} +\newcommand{\code}[1]{\texttt{#1}} +\newcommand{\option}[1]{`\texttt{#1}'} +\newcommand{\dvipdfm}{\texttt{dvipdfm}} +\newcommand{\dvipdfmx}{\texttt{dvipdfmx}} +\newcommand{\xdvipdfmx}{\texttt{xdvipdfmx}} +\newcommand{\deprecated}[1]{\marginnote{\addfontfeatures{Color=CC3333}#1}} +\newcommand{\lnum}[1]{{\addfontfeatures{RawFeature=+lnum}#1}} +\usepackage{fancyhdr} +\pagestyle{fancy} +%\lhead{} +\title{The \dvipdfmx\ User's Manual} +\author{The \dvipdfmx\ project team\footnote{Jin-Hwan Cho, Matthias Franz, +and \href{mailto:shunsaku.hirata74@gmail.com}{Shunsaku Hirata}}} +\date{May 6, 2017} +\begin{document} + +\maketitle +%\tableofcontents + +\section{Introduction} + +The \dvipdfmx\ (formerly \dvipdfm-cjk) project +provides an extended version of the \dvipdfm, a DVI to PDF translator developed +by Mark~A.~Wicks. + +The primary goal of this project is to support multi-byte character encodings +and large character sets such as for East Asian languages. +This project started as a combined work of the \dvipdfm-jpn project by +Shunsaku Hirata and its modified one, \dvipdfm-kor, by Jin-Hwan Cho. + +Extensions to \dvipdfm\ include, +\begin{itemize} + \item Support for OpenType and TrueType font, including partial support + for OpenType Layout for finding glyphs and vertical writing. + \item Support for CJK-\LaTeX\ and H\LaTeX\ with Subfont Definition Files. + \item Support for various legacy multi-byte encodings via PostScript CMap + Resources. + \item Unicode related features: Unicode as an input encoding and + auto-creation of ToUnicode CMaps. + \item Support for p\TeX\ (a Japanese localized variant of \TeX) including + vertical writing extension. + \item Some extended DVI specials. + \item Reduction of output files size with on-the-fly Type1 to CFF (Type1C) + conversion and PDF object stream. + \item Advanced raster image support including alpha channels, embedded + ICC profiles, 16-bit bit-depth colors, and so on. + \item Basic PDF password security support for PDF output. +\end{itemize} +Some important features are still missing: +\begin{itemize} + \item Linearization. + \item Color Management. + \item Resampling of images. + \item Selection of compression filters. + \item Variable font and OpenType 1.8. + \item and many more... +\end{itemize} + +\dvipdfmx\ is now maintained as part of \TeX\ Live. Latest source code can +be found at \TeX\ Live SVN repository. For an instruction on accessing the +development sources for TeX Live, see,\medskip + +\url{http://www.tug.org/texlive/svn/} +\medskip + +This manual, ``The \dvipdfmx\ User's Manual'', is originally prepared for +\TeX\ Live 2017. Current maintainer of this manual is Shunsaku Hirata. +Latest version and contact information can be found at:\medskip + +\url{http://github.com/shirat74/dvipdfm-x-doc/} +\medskip + +\noindent{}Please send quenstions or suggestions. + +\subsection{\xdvipdfmx} + +\xdvipdfmx\ is an extended version of \dvipdfmx, and is now incorporated into +\dvipdfmx. + +The \xdvipdfmx\ extensions provides support for the Extended DVI (.xdv) format +generated by \XeTeX which includes support for platform-native fonts and the +\XeTeX\ graphics primitives, as well as Unicode text and OpenType font. + +\XeTeX\ originally used a Mac-specific program called \code{xdv2pdf} as a +backend program instead of \xdvipdfmx. The \code{xdv2pdf} program supported +a couple of special effects that are not yet available through \xdvipdfmx: +The Quartz graphics-based shadow support, AAT ``variation'' fonts such as Skia, +transparency as an attribute of font, and so on. +It would be nice if they continue to be supported. Suggestions and help are +welcomed. + + +\subsection{Legal Notice} + +Copyright © The dvipdfmx project team. +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.3 +or any later version published by the Free Software Foundation; +with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. +A copy of the license is included in the section entitled +``\hyperref[SEC:FDL]{GNU Free Documentation License}''. + +\section{Installation and Usage} + +Typical usage and installation steps are not different from the original +\dvipdfm. Please refer documents from \dvipdfm\ distribution for detailed +instruction on how to install and how to use \dvipdfm. The \dvipdfm\ manual is +available from its CTAN site:\medskip + +\url{http://www.ctan.org/tex-archive/dviware/dvipdfm} +\medskip + +The minimal requirements for building \dvipdfmx\ is the \code{kpathsea} library. +\code{zlib} for compression and \code{libpng} for PNG inclusion are highly +recommended. Optionally, the libpaper library may be used to handle paper sizes. + +This document only describes additions and modifications to \dvipdfm. +Please refer the +``\href{http://mirrors.ctan.org/dviware/dvipdfm/dvipdfm.pdf}{Dvipdfm User's Manual}'' +available from the CTAN site mentioned above for basic usage. + +Some additional command line options recognized by \dvipdfmx\ are listed in +Table~\ref{TABLE:options}. Try +\begin{lstlisting} +dvipdfmx --help +\end{lstlisting} +for the list of command line options and thier explanations. + +\begin{table} + \centering + \begin{tabular}{lp{8cm}}\hline + Option & Description \\ \hline\hline + \code{-C} \textit{number} & Specify miscellaneous option flags. See, + section of ``\hyperref[SEC:compatibility]{Incompatible Changes}'' for + details. \\ + \code{-S} & Enable PDF encryption. \\ + \code{-K} \textit{number} & Set encryption key length. The default value + is 40.\\ + \code{-P} \textit{number} & Set permission flags for PDF encryption. + The \textit{number} is a 32-bit unsigned integer representing permission + flags. + See, section of ``\hyperref[SEC:encryption]{Encryption Support}''. + The default value is \code{0x003C}.\\ + \code{-I} \textit{number} & Life of image cache in hours. By specifying + value \code{0} \dvipdfmx\ erases cached images, and value \code{-1} + erases all cached images and does not leave newly generated one. The + default value is \code{-2}. (ignore image cache) \\ + \code{-M} & Process \MP\ generated PostScript file.\\ + \code{-E} & Always try to embed fonts \emph{regardless of + liscensing}.\\ + \hline + \end{tabular} + \caption{Additional command line options recognized by \dvipdfmx.}% + \label{TABLE:options} +\end{table} + + +\section{Quick Guide} + +\dvipdfmx\ is supposed to be used by users of \LaTeX\ packages for typesetting +CJK languages like H\LaTeX\ and CJK-\LaTeX, and \TeX\ variants such as \XeTeX, +p\TeX, and up\TeX. +This section is intended to be a quick guide for each users. + +\subsection{\texorpdfstring{\XeTeX}{XeTeX}} +For \XeTeX\ users, most part of this document is irrelevant except section of +``\hyperref[SEC:graphics]{Graphics and Image Formats}'' and +``\hyperref[SEC:specials]{DVI Specials}''. + +\subsection{p\TeX} +p\TeX\ users are at least required to install several auxilially files +mentioned in the section of ``\hyperref[SEC:auxfiles]{Auxilially Files}'' +and to setup fontmappings. Just install the \package{adobemappings} and +\package{glyphlist} for auxilially files. (As \TeX\ Live basic intallation +requires them, they are probably already installed for \TeX\ Live users.) + +Setting up fontmaps can be done easily with help of the \package{ptex-fontmaps} +package. For examples, to use with IPA fonts (contained +in the \package{ipaex} package), run, +\begin{lstlisting} +updmap ipaex +\end{lstlisting} +Alternatively, just for a quick test of installation, try the following: +\begin{lstlisting} +\documentclass{article} +\begin{document} +\special{pdf:mapline rml H KozMinProVI-Regular} +...Some Japanese text goes here... +\end{document} +\end{lstlisting} +In this example, PDF viewer which can handle substitute font is required since +\dvipdfmx\ does not embed fonts. + +For using Japanese text in PDF document information and annotations, put +the following \code{special} command, +\begin{lstlisting} +\AtBeginDocument{\special{pdf:tounicode 90ms-RKSJ-UCS2}} +\end{lstlisting} +in the preamble. +The above \code{special} command instructs \dvipdfmx\ to convert text encoded +in Shift-JIS to Unicode. For EUC-JP, replace 90ms-RKJK-UCS2 with EUC-UCS2. + +\subsection{up\TeX} +up\TeX\ users are basically the same as p\TeX\ users but there are two choices +for setting fontmaps. Setup fontmaps as mentioned in the above for p\TeX, or use +keyword \code{unicode} in the encoding field of fontmap files. + +The former case might be easier as auto-creation of fontmap files can be done +with the \code{updmap} program and the \package{ptex-fontmaps} package. But in +this method there are some difficulties when using fonts which employ character +collection (glyph repertoire) other than Adobe-Japan1 in the case of PostScript +flvavored OpenType fonts. +In the later case, the \package{adobemappings} package is not reuiqred +and newer PostScript flavored OpenType fonts which do not employ Adobe-Japan1 +can be used too. + +Using \code{unicode} is more simpler and intuitive thus it is recommended to +use this method.\footnote{For \TeX\ Live 2017. Earlier versions have buggy +support.} +Typical example fontmap entries for using Adobe's SouceHan fonts look like: +\begin{lstlisting} +urml unicode SourceHanSerifJP-Light.otf +urmlv unicode SourceHanSerifJP-Light.otf -w 1 +ugbm unicode SourceHanSansJP-Medium.otf +ugbmv unicode SourceHanSansJP-Medium.otf -w 1 +\end{lstlisting} + +As in p\TeX, the following \code{special} instruction is necessary to PDF +document information and annotations to be shown correctly: +\begin{lstlisting} +\AtBeginDocument{\special{pdf:tounicode UTF8-UCS2}} +\end{lstlisting} +Here, input encodig is assumed to be UTF-8. + +\subsection{CJK-\LaTeX} + +CJK-\LaTeX users are required to have Subfont Definition Files to be installed. +They are available as part of the \package{ttfutils} package. + +To use TrueType Ariphic fonts provided by the \package{arphic-ttf} package: +\begin{lstlisting} +\documentclass{article} +\usepackage{CJKutf8} +...Other packages loaded here... +\AtBeginDocument{% + \special{pdf:tounicode UTF8-USC2}% + \special{pdf:mapline bsmiu@Unicode@ unicode bsmi00lp.ttf}% + } +\begin{document} +\begin{CJK}{UTF8}{bsmi} +...some Chinese text goes here... +\end{CJK} +\end{document} +\end{lstlisting} +Here, \code{pdf:mapline} special is used to setup fontmappings. + +\section{Auxiliary Files}\label{SEC:auxfiles} + +This section is mostly for supporting legacy encodings and legacy font format +such as PostScript Type1 font. \XeTeX\ users may skip this section. + +\dvipdfmx\ has a capability to handle various input encodings from 7-bit +encodings to variable-width multi-byte encodings. It also has some sort of +Unicode support. Several auxiliary files which are not common to \TeX\ users +are needed to enable those features. This section shortly describes about them. + +\subsection{PostScript CMap Resources} + +PostScript CMap Resources\footnote{See, ``\href{http://www.adobe.com/content/dam/Adobe/en/devnet/font/pdfs/5014.CIDFont\_Spec.pdf}{Adobe CMap and CIDFont Files Specification}''} +are required for supporting lagacy encodings such as Shift-JIS, EUC-JP, Big5, +and other East Asian encodings. \dvipdfmx\ internally identifies glyphs with +identifiers (CIDs\footnote{PostScript terminology ``Character IDentifier''.}) +represented as an integer ranging from 0 to 65535 in the CID-based glyph access. +PostScript CMap Resources describes the mapping between sequences of input +character codes and CIDs. \dvipdfmx\ has an extensible support for multi-byte +encodings via PostScript CMap Resources. + +CMap files for standard East Asian encodings, for use with Adobe's character +collections, are included in the \package{adobemapping} package. +The latest version of those CMap files maintained by Adobe can be found at +Adobe's GitHub Project page:\medskip + +\url{http://github.com/adobe-type-tools/cmap-resources} +\medskip + +Those files are mandatory for supporting p\TeX. up\TeX\ users may also +want to install them but they are not required. + +\subsection{Subfont Definition Files} + +CJK fonts usually contain several thousands of glyphs. For using such fonts +with (original) \TeX, which can only handle 8-bit encodings, it is necessary to +split fonts into several ``subfonts''. Subfont Definition File (SFD) +specify the way how those fonts are split into subfonts. \dvipdfmx\ uses SFD +files to convert subfonts back to a single font. + +SFD files are not required for use with \TeX\ variants which can handle +multi-byte character encodings and large character sets such as p\TeX, +up\TeX,\XeTeX, and Omega. +H\LaTeX\ and CJK-\LaTeX\ users are required to have those files to be +installed. SFD files are available as a part of the \package{ttfutils} package +for \TeX\ Live users. + +\subsection{The Adobe Glyph List and ToUnicode Mappings} + +The Adobe Glyph List\footnote{See, ``\href{http://github.com/adobe-type-tools/agl-specification}{Adobe Glyph List Specification}''} (AGL) +describes correspondence between PostScript glyph names (e.g., \code{AE}, +\code{Aacute},...) and Unicode character sequences representing them. +Some features described in the section ``Unicode Support'' requires AGL file. + +\dvipdfmx\ looks for the file \code{glyphlist.txt} when conversion from +PostScript glyph names to Unicode sequences is necessary. +This conversion is done in various situations; when creating ToUnicode CMaps +for 8-bit encoding fonts, finding glyph descriptions from TrueType and OpenType +fonts when the font itself does not provide a mapping from PostScript glyph +names to glyph indices (version 2.0 ``post'' table), and when the encoding +\code{unicode} is specified for Type1 font. + +AGL file is included in the \package{glyphlist} package. The latest version +can be found at Adobe's GitHub site:\medskip + +\url{http://github.com/adobe-type-tools/agl-aglfn} +\medskip + +ToUnicode Mappings are similar to AGL but they describe correspondence +between CID numbers (instead of glyph names) and Unicode values. +The content of those files are the same as CMap Resources. +They are required when using TrueType fonts emulated as CID-keyed fonts. +They should be found in the same directory as ordinary CMap files. + +ToUnicode Mapping files are included in \package{adobemapping} package. +Those files are not required for \XeTeX\ users. + +\section{Overview of Extensions} + +This section gives a quick overview of \dvipdfmx's extended capabilities. + +\subsection{CJK Support} + +There are many extensions made for supporting CJK languages. Features described +here is mainly for CJK languages but their use is actually not limited to it. +Those features are implemented in a generic way so that it can be beneficial to +users who are not involved in CJK languages. + +\subsubsection{Legacy Multi-byte Encodings} + +\dvipdfmx\ has an extensible support for encodings by means of +PostScript CMap Resources. Just like \code{enc} files are written for 8-bit +encodings, one can write their own CMap files to support custom encodings. +See, Adobe's technical notes for details on PostScript CMap Resources. + +\subsubsection{Vertical Writing} + +\dvipdfmx\ supports vertical writing extension used by p\TeX\ and up\TeX. +A DVI instruction to set writing mode is supported. OpenType Layout +GSUB Feature is supported for selecting vertical version of glyphs. + +\begin{figure} +\centering +\jphoritext\hspace{24pt}\jpverttext% +\caption{An example of horizontal and vertical text; +left and right corner brackets are replaced with their vertical counterparts.}% +\label{FIG:verttext} +\end{figure} + +\subsection{Unicode Support} + +Unicode support here consists of two parts: Supporting Unicode as input +encodings and making output PDF files ``Unicode aware''. + +\subsubsection{Unicode as Input Encoding} + +\dvipdfmx\ recognizes an additional keyword \code{unicode} in fontmap files +to declare that Unicode values are used in input DVI files. Unicode support is +basically limited to the Basic Multilingual Plane (BMP) since there are no +support for code ranges that requires more than three bytes in TFM and extended +TFM formats. + +\subsubsection{ToUnicode CMap Support} + +In PDF,it is often the case that text is not encoded in Unicode. +However, modern applications usually want them represented in Unicode to make +it usable. ToUnicode CMaps are a bridge between PDF text string encodings +and Unicode encodings, and they makes it possible to extract text in PDF as +Unicode encoded strings. It is important to make resulting PDF search-able and +copy-and-past-able. Dvipdfmx supports the auto-creation of ToUnicode CMaps. + +It will not work properly for multiply encoded glyphs due to fundamental +limitations of Unicode conversion mechanism with ToUnicode CMaps. + +\subsection{Other Extensions} + +\dvipdfmx\ can generate encrypted PDF documents to protect its contents from +unauthorized access. It is limited to passorwd-based authentication, and +public-key based authentication is not supported. The 256-bit AES encryption is +also supported for PDF version 1.7 setting although it may not be supported +by PDF viewers. + +There are various other improvements over \dvipdfm. The most notable one is +more improved PDF input and output support: The cross-reference stream and +object stream introduced in PDF-1.5 are also supported. + + +\section{Graphics and Image Format}\label{SEC:graphics} + +Graphics support was mostly rewritten. Support for BMP and JPEG\lnum{2000} is +added. An effort to preserve more information originally found in included +images, e.g., embedded ICC Profiles and XMP Metadata, was made. + +However, \dvipdfmx\ does not support various features common to graphics +manipulation programs such as resampling, color conversion, and selection of +compression filters. Thus, it is recommended to use other programs specialized +in image manipulation for preparation of images. + +\subsection{Supported Graphics File Formats} + +Supported formats are, PNG, JPEG, \lnum{JPEG2000}, BMP, PDF, and \MP\ generated +EPS. All other format images, such as SVG and PostScript, must be converted to +other format supported by \dvipdfmx\ before inclusion. +The \option{-D} option, as in \dvipdfm, can be used for filtering images. + +\subsection{PNG and JPEG} + +PNG and JPEG are supported as in \dvipdfm\ but it is mostly rewritten. + +PNG support includes most of important features of PNG such as color palette, +transparency, 16bit bit-depth color, embedded ICC Profiles, and calibrated +colors specified by \code{gAMA} and \code{cHRM} chunks. XMP Metadata is also +supported. Predictor filter may be applied for Flate compression which result in +better compression for larger images. Application of the predictor filter +sometimes makes compression speed very slow. Please try \option{-C 0x20} +(disable predictor filters) command line option to check if slowness is due to +the predictor filter. + +JPEG is relatively well supported. \dvipdfmx\ supports embedded ICC Profiles +and CMYK color. Embedded XMP metadata is also supported. +\dvipdfmx\ uses JFIF or Exif data to determin image's physical size. + +\subsection{PDF and ``MPS''} + +PDF inclusion is supported as in \dvipdfm, with various important enhancement +over \dvipdfm\ for robust inclusion. \dvipdfmx\ can handle cross-reference +streams and object streams introduced in \lnum{PDF-1.5}. +\dvipdfmx\ also supports inclusion of PDF pages other than the first page. +However, tagged PDF may cause problems and annotations are not kept. + +For \MP\ generated EPS files, multi-byte encoding support is added. +\dvipdfmx\ also supports ``\MP\ mode'': When \dvipdfmx\ is invoked with +\option{-M} option, it enters in \MP\ mode and processes a \MP\ +generated EPS file as input.% +\footnote{\code{prologue} must be set to \code{2}.} + +\subsection{Additional Supported Formats} + +BMP is supported but limited to uncompressed or RLE-compressed raster +images. Extensions are not (won't be) supported. + +\lnum{JPEG2000} is also supported. It is restricted to JP2 and JPX baseline +subset as required by PDF spec. It is not well supported and still in +an experimental stage. J2C format and transparency are not supported. + + +\subsection{Image Cache} + +Chaching of images generated via filtering command specified with \option{-D} +option is supported. It solves the problems that image inclusion becomes very +slow when external filtering program such as GhostScript is invoked each time +images are included. + +Use \option{-I} option to enable this feature: +\begin{lstlisting} +-I 24 +\end{lstlisting} +where the integer represents the life of cache files, 24 hours in this example. + + +\section{DVI Specials}\label{SEC:specials} + +\dvipdfmx\ is mostly compatible to \dvipdfm. +Several DVI \code{special} commnads are added for more flexible PDF generation: +Creation of arbitrary stream object, controlling \dvipdfmx\ behavior, and some +specials which might be useful for graphics drawing packages. + + +\subsection{Additions to \dvipdfm's \code{pdf:} Special} + +The \code{pdf:fstream} special is added, which enables creation of PDF stream +object from an existing file. +\begin{lstlisting} +pdf:fstream @identifier (filename) <<dictionary>> +\end{lstlisting} +where identifier and filename (specified as a PDF string object) are +mandatory and a dictionary object which is to be added to the stream +dictionary following the filename is optional. + +For examples, to incorporate a XMP Metadata, +\begin{lstlisting} +\special{pdf:fstream @xmp (test.xmp) << + /Type /Metadata + /Subtype /XML +>>} +\special{pdf:put @catalog << /Metadata @xmp >>} +\end{lstlisting} + +Similary, \code{pdf:stream} special can be used to create a PDF stream +object from a PDF string instead of a file: +\begin{lstlisting} +\special{pdf:stream @MyPattern + (0.16 0 0 0.16 0 0 cm 4 w + 50 0 m 50 28 28 50 0 50 c S 100 50 + m 72 50 50 28 50 0 c S + 50 100 m 50 72 72 50 100 50 c S + 0 50 m 28 50 50 72 50 100 c S + 100 50 m 100 78 78 100 50 100 c 22 100 0 78 0 50 c + 0 22 22 0 50 0 c 78 0 100 22 100 50 c S + 0 0 m 20 10 25 5 25 0 c f 0 0 m 10 20 5 25 0 25 c f + 100 0 m 80 10 75 5 75 0 c f + 100 0 m 90 20 95 25 100 25 c f + 100 100 m 80 90 75 95 75 100 c f + 100 100 m 90 80 95 75 100 75 c f + 0 100 m 20 90 25 95 25 100 c f + 0 100 m 10 80 5 75 0 75 c f + 50 50 m 70 60 75 55 75 50 c 75 45 70 40 50 50 c f + 50 50 m 60 70 55 75 50 75 c 45 75 40 70 50 50 c f + 50 50 m 30 60 25 55 25 50 c + 25 45 30 40 50 50 c f + 50 50 m 60 30 55 25 50 25 c 45 25 40 30 50 50 c f) + << + /BBox [0 0 16 16] + /PaintType 2 + /PatternType 1 + /Resources << + /ProcSet [/PDF] + >> + /TilingType 3 + /Type /Pattern + /XStep 16 + /YStep 16 + >> +} +\end{lstlisting} +The above example defines a tiling pattern. With the following code: +\begin{lstlisting} +\special{pdf:put @resources + << + /ColorSpace << /CS01 [/Pattern /DeviceRGB] >> + /Pattern << /PT01 @MyPattern >> + >> +} +\special{pdf:content + q 0.8 0.3 0.3 RG /CS01 cs 0.8 0.3 0.3 /PT01 scn + 0 0 240 80 re f +} +\end{lstlisting} +it draws a box filled with a tiling pattern as shown in +Figure~\ref{FIG:pattern}. + +\special{pdf:stream @MyPattern + (0.16 0 0 0.16 0 0 cm 4 w + 50 0 m 50 28 28 50 0 50 c S 100 50 + m 72 50 50 28 50 0 c S + 50 100 m 50 72 72 50 100 50 c S + 0 50 m 28 50 50 72 50 100 c S + 100 50 m 100 78 78 100 50 100 c 22 100 0 78 0 50 c + 0 22 22 0 50 0 c 78 0 100 22 100 50 c S + 0 0 m 20 10 25 5 25 0 c f 0 0 m 10 20 5 25 0 25 c f + 100 0 m 80 10 75 5 75 0 c f + 100 0 m 90 20 95 25 100 25 c f + 100 100 m 80 90 75 95 75 100 c f + 100 100 m 90 80 95 75 100 75 c f + 0 100 m 20 90 25 95 25 100 c f + 0 100 m 10 80 5 75 0 75 c f + 50 50 m 70 60 75 55 75 50 c 75 45 70 40 50 50 c f + 50 50 m 60 70 55 75 50 75 c 45 75 40 70 50 50 c f + 50 50 m 30 60 25 55 25 50 c + 25 45 30 40 50 50 c f + 50 50 m 60 30 55 25 50 25 c 45 25 40 30 50 50 c f) + << + /BBox [0 0 16 16] + /PaintType 2 + /PatternType 1 + /Resources << + /ProcSet [/PDF] + >> + /TilingType 3 + /Type /Pattern + /XStep 16 + /YStep 16 + >> +}% +\begin{figure} +\centering +\raisebox{-80bp}[0bp][80bp]{\makebox[240bp][l]{\special{pdf:put @resources + << + /ColorSpace << /CS01 [/Pattern /DeviceRGB] >> + /Pattern << /PT01 @MyPattern >> + >> +}% +\special{pdf:content + 0.8 0.3 0.3 RG /CS01 cs 0.8 0.3 0.3 /PT01 scn + 0 0 240 80 re f +}}}% +\caption{An example of tiling pattern.}\label{FIG:pattern} +\end{figure} + +\code{pdf:mapline} and \code{pdf:mapfile} specials can be used to append a +fontmap entry or to load a fontmap file: +\begin{lstlisting} +pdf:mapline foo unicode bar +pdf:mapfile foo.map +\end{lstlisting} + +\code{pdf:majorversion} and \code{pdf:minorversion} specials can be used to +specify major and minor version of output PDF. +\begin{lstlisting} +pdf:minorversion 3 +\end{lstlisting} + +To protect output PDF with encryption, use \code{pdf:encrypt} special +\begin{lstlisting} +pdf:encrypt userpw (foo) ownerpw (bar) length 128 perm 20 +\end{lstlisting} +where user-password and owner-password must be specified as PDF string objects. +(which can be empty) Numbers specifying key-length and permission flags here +must be decimal numbers. See, section of ``\hyperref[SEC:encryption]{Encryption +Support}'' for a brief description of permission flags. + +Other notable extensions are \code{code}, \code{bcontent}, and +\code{econtent}. The \code{code} special can be used to insert raw PDF graphics +instructions into output page content stream. It is different from \dvipdfm's +\code{content} special in that it does not enclose contents with a \code{q} +and \code{Q} (save-restore of graphics state) pair. +A typical usage of this special is: +\begin{lstlisting} +\special{pdf:code q 1 Tr} +text goes here... +\special{pdf:code Q} +\end{lstlisting} +which changes text rendering mode to 1, as shown in Figure~\ref{FIG:trmode} for +example. + +\begin{figure} +\centering +\mbox{\special{pdf:code q 1 w 1 Tr}% +{\fontsize{200pt}{200pt}\selectfont\textchi}% +\special{pdf:code Q}}% +\caption{A character drawn in the PDF text rendering mode 1.}% +\label{FIG:trmode} +\end{figure} + +Be careful on using this special as it is very easy to generate +broken PDF files. The \code{bcontent} and \code{econtent} pair is fragile and +often incompatible to other groups of special commands. It is not +always guaranteed to work as `expected'. + +\subsection{Dvipdfmx Extensions} + +A new special \code{dvipdfmx:config} was introduced in \TeX Live 2016 which +makes it possible to invoke a command line option. Most single letter command +line options except \option{D} are supported. For examples, +\begin{lstlisting} +dvipdfmx:config C 0x10 +\end{lstlisting} +sets the \dvipdfmx's compatibility flag. + +\subsection{DVI Special Examples} + +The following code reads \TeX\ source file and creates a stream object named +as \code{@SourceFile}, then creates a file attachment annotation. +\marginnote{% +\special{pdf:fstream @SourceFile (\jobname.tex)}% +\special{pdf:ann width 10bp height 20bp + << /Type /Annot + /Subtype /FileAttachment + /FS << + /Type /Filespec + /F (\jobname.tex) + /EF << /F @SourceFile >> + >> + /Name /PushPin + /C [0.8 0.2 0.2] + /T (The dvipdfmx project team) + /Subj (The Dvipdmfx User's Manual) + /Contents (XeLaTeX source file of this manual.) + >> +}}% +\begin{lstlisting} +\special{pdf:fstream @SourceFile (\jobname.tex)}% +\special{pdf:ann width 10bp height 20bp + << /Type /Annot + /Subtype /FileAttachment + /FS << + /Type /Filespec + /F (\jobname.tex) + /EF << /F @SourceFile >> + >> + /Name /PushPin + /C [0.8 0.2 0.2] + /T (The dvipdfmx project team) + /Subj (The Dvipdfmx User's Manual) + /Contents (XeLaTeX source file of the manual.) + >> +} +\end{lstlisting} +An Example of separation color space: +\special{pdf:stream @TintTransform1 + ({0 exch dup 0.62 mul exch 0}) + << /FunctionType 4 + /Domain [ 0.0 1.0 ] + /Range [ 0.0 1.0 0.0 1.0 0.0 1.0 0.0 1.0 ] + >> +}% +\special{pdf:stream @TintTransform2 + ({dup 0.78 mul exch dup 0.05 mul exch 0.71 mul 0}) + << /FunctionType 4 + /Domain [ 0.0 1.0 ] + /Range [ 0.0 1.0 0.0 1.0 0.0 1.0 0.0 1.0 ] + >> +}% +\special{pdf:obj @Orange [ + /Separation /Orange /DeviceCMYK @TintTransform1 + ] +}% +\special{pdf:obj @Green [ + /Separation /Green /DeviceCMYK @TintTransform2 + ] +}% +\begin{center} +\mbox{% +\special{pdf:put @resources << + /ColorSpace << /CS01 @Orange /CS02 @Green >> + >> +}% +\fontsize{40pt}{40pt}\selectfont +\special{pdf:code q /CS01 cs 1.0 scn}Orange\special{pdf:code Q} and +\special{pdf:code q /CS02 cs 1.0 scn}Green\special{pdf:code Q} +} +\end{center} +\begin{lstlisting} +\special{pdf:stream @TintTransform1 + ({0 exch dup 0.62 mul exch 0}) + << /FunctionType 4 + /Domain [ 0.0 1.0 ] + /Range [ 0.0 1.0 0.0 1.0 0.0 1.0 0.0 1.0 ] + >> +} +\special{pdf:stream @TintTransform2 + ({dup 0.78 mul exch dup 0.05 mul exch 0.71 mul 0}) + << /FunctionType 4 + /Domain [ 0.0 1.0 ] + /Range [ 0.0 1.0 0.0 1.0 0.0 1.0 0.0 1.0 ] + >> +} +\special{pdf:obj @Orange [ + /Separation /Orange /DeviceCMYK @TintTransform1 + ] +} +\special{pdf:obj @Green [ + /Separation /Green /DeviceCMYK @TintTransform2 + ] +} +\mbox{% + \special{pdf:put @resources << + /ColorSpace << /CS01 @Orange /CS02 @Green >> + >> + }% + \special{pdf:code q /CS01 cs 1.0 scn} + Orange + \special{pdf:code Q} + and + \special{pdf:code q /CS02 cs 1.0 scn} + Green + \special{pdf:code Q} +} +\end{lstlisting} +Transparency example: +\special{pdf:obj @gs01 << + /Type /ExtGState /CA 0.6 /ca 0.6 /AIS false +>>}% +\begin{center} +\mbox{% + \special{pdf:put @resources << + /ExtGState << /GS01 @gs01 >> + >>}% + \fontsize{200pt}{200pt}\selectfont + \special{pdf:code q 1.0 0.8 0.2 rg} + \textalpha% + \special{pdf:code /GS01 gs 0.4 0.8 0.4 rg}% + \hspace{-0.3em}\textbeta% + \hspace{-0.3em}\raisebox{0.5ex}{% + \special{pdf:code 0.4 0.4 0.8 rg}% + \textpi% + } + \special{pdf:code Q}% +} +\end{center} +\begin{lstlisting} +\special{pdf:obj @GS01 << + /Type /ExtGState /CA 0.6 /ca 0.6 /AIS false +>>}% +\mbox{% + \special{pdf:put @resources << + /ExtGState << /GS01 @GS01 >> + >>}% + \special{pdf:code q 1.0 0.8 0.2 rg}% + \textalpha% + \special{pdf:code /GS01 gs 0.4 0.8 0.4 rg}% + \hspace{-0.3em}\textbeta% + \hspace{-0.3em}\raisebox{0.5ex}{% + \special{pdf:code 0.4 0.4 0.8 rg}% + \textpi% + }% + \special{pdf:code Q}% +} +\end{lstlisting} +where \code{CA} and \code{ca} represent opacity of stroke and fill color +individually. + +\section{Font Mapping} + +Syntax of fontmap file is basically the same as \dvipdfm. There are few +extensions in \dvipdfmx. In addition to 8-bit \code{enc} files and +keyword \code{builtin} and \code{none}, \dvipdfmx\ accepts CMap name and +the keyword \code{unicode} in the encoding field. + +This section is completely irrevant to \XeTeX\ users. + +\subsection{Extended Syntax and Options} + +Few options are available in \dvipdfmx\ in addition to the original +dvipdfm's one. All options that makes \dvipdfmx\ to use unembedded +fonts are deprecated as by using them makes \dvipdfmx\ to create PDF +files which can be not compliant to the ISO standards. + +\subsubsection{SFD Specification} + +For bundling up fonts split into multiple subfonts via SFD back into +a single font, dvipdfmx supports an extended sytax of the form +\begin{lstlisting} +tfm_name@SFD@ encoding filename options +\end{lstlisting} + +A typical example looks like: +\begin{lstlisting} +gbsn@EUC@ GB-EUC-H gbsn00lp +\end{lstlisting} + +where TFMs \code{gbsn00}, \code{gbsn01}, \code{gbsn02}... are mapped into a +single font named \code{gbsn00lp} via the rule described in the SFD file +\code{EUC}. + +\subsubsection{TrueType Collection Index} + +TrueType Collection index number can be specified with \code{:n:} +in front of TrueType font name: +\begin{lstlisting} +min10 H :1:mincho +\end{lstlisting} + +In this example, the option \code{:1:} tells \dvipdfmx\ to select first +TrueType font from the TTC font \code{mincho.ttc}. Alternatively, the +\option{-i} option can be used in the option field to specify TTC index: +\begin{lstlisting} +min10 H mincho -i 1 +\end{lstlisting} + +\subsubsection{Non-embedding Switch} + +\deprecated{Use of this option is deprecated.} +\noindent{}The character \code{!} in front of the font name can be used to +indicate that the font shall not be embedded. This feature greatly reduces the +size of the final PDF output, but the PDF file may not be viewed exactly in +other systems on which appropriate fonts are not installed. +\bigskip + +\noindent{}NOTE: \dvipdfmx\ always converts input encodings to CIDs and then +uses Identity CMaps\footnote{Predefined CMaps \code{Identity-H} and +\code{Identity-V} for the identity mapping.} +in the output PDF. However, \lnum{ISO~32000-1:2008} describes as +\begin{quoting} +The Identity-H and Identity-V CMaps shall not be used with a non-embedded font. +Only standardized character sets may be used. +\end{quoting} +which had never appeared in Adobe's PDF References. This makes all PDF files +generated by \dvipdfmx\ with non-embedded CID-keyed fonts non-compliant to +the ISO standards. + +\subsubsection{`Standard' CJK Fonts} + +\deprecated{This feature is deprecated.} +\noindent{}Use of this feature shall be avoided for new documents. It is +described here since it might still be useful for some situations. + +\dvipdfmx\ recognizes several `Standard' CJK fonts although there are no such +notion in PDF. In older days where there were not so many freely available CJK +fonts, it was sometimes useful to create PDF files without embedded fonts and +let PDF viewers or printers to use substitute fonts (tend to be higher quality) +installed in their systems. \dvipdfmx\ `knows' several fonts which might be +available in PostScript printers and PDF applications such as Acrobat Reader, +and uses them without actually having it. +See, Table~\ref{TABLE:StdCJKFont}, for the list of available `Standard' CJK +fonts. + +\begin{table} + \centering + \begin{tabular}{lll}\hline + Character Collection & Font Family & Description \\ \hline\hline + Adobe-Japan1 & Ryumin-Light & PS printers \\ + & GothicBBB-Medium & \\ + Adobe-CNS1 & MHei-Medium-Acro & Acrobat Reader 4 \\ + & MSung-Light-Acro & \\ + Adobe-GB1 & STSong-Light-Acro & \\ + & STHeiti-Regular-Acro & \\ + Adobe-Japan1 & HeiseiMin-W3-Acro & \\ + & HeiseiKakuGO-W5-Acro & \\ + Adobe-Korea1 & HYGoThic-Medium-Acro & \\ + & HYSMyeongJo-Medium-Acro & \\ + Adobe-CNS1 & MSungStd-Light-Acro & Acrobat Reader 5 \\ + Adobe-GB1 & STSongStd-Light-Acro & \\ + Adobe-Korea1 & HYSMyeongJoStd-Medium-Acro \\ + Adobe-CNS1 & AdobeMingStd-Light-Acro & Adobe Reader 6 \\ + Adobe-GB1 & AdobeSongStd-Light-Acro & \\ + Adobe-Japan1 & KozMinPro-Regular-Acro & \\ + & KozGoPro-Medium-Acro & \\ + Adobe-Korea1 & AdobeMyungjoStd-Medium-Acro & \\ + Adobe-CNS1 & AdobeHeitiStd-Regular & Adobe Reader 7 \\ + Adobe-Japan1 & KozMinProVI-Regular & Adobe Reader 8\\ + \hline + \end{tabular} + \caption{List of available `Standard' CJK font. Most of them are + available as a part of Adobe Asian Font Packs for each versions of + Adobe or Acrobat Reader.}\label{TABLE:StdCJKFont} +\end{table} + +Only fixed-pitch glyphs (i.e., quarter, third, half, and full widths) are +supported for those fonts. + +\subsubsection{Stylistic Variants} + +\deprecated{Use of this option is deprecated.} +\noindent{}Keywords \code{,Bold}, \code{,Italic}, and \code{,BoldItalic} can be +used to create synthetic bold, italic, and bolditalic style variants from other +font using PDF viewer's (or OS's) function. +\begin{lstlisting} +jbtmo@UKS@ UniKSCms-UCS2-H :0:!batang,Italic +\end{lstlisting} + +Availability of this feature highly depends on the implementation of PDF +viewers. This feature is usually not supported for embedded fonts. +Notice that this option automatically disables font embedding thus +use of it is deprecated. + +\subsection{Specifying Unicode Plane} + +As there are no existing 3-bytes or 4-bytes TFM formats, the only way to use +Unicode characters other than the BMP is to map code range 0-65535 to different +planes via (e.g., to plane 1) \option{-p 1} fontmap option. This option is +available only when \code{unicode} is specified in the encoding field. + +\subsection{OpentType Layout Feature} + +OpenType Layout Feature fontmap options mentioned below are only meaningful +when \code{unicode} is specified in the encoding field. + +With the \option{-w} option, writing mode can be specified. +\option{-w 1} denotes the font is for vertical writing. It automatically +enables an OpentType Layout Feature related to vertical writing, namely, +\code{vert} or \code{vrt2}, to choose proper glyphs for vertical text. + +The \option{-l} option can be used to enable various OpenType Layout GSUB +Features. For examples, \option{-l jp04} +enables \code{jp04} feature to select \lnum{JIS2004} forms for Kanjis. +Features can be specified as a ``:'' separated list of OpenType Layout +Feature tags like \option{-l vkna:jp04}. +Script and language may be additionally specified as +\option{-l kana.JAN.ruby}. + +An example can be +\begin{lstlisting} +uprml-v unicode SourceHanSerifJP-Light.otf -w 1 -l jp90 +\end{lstlisting} +which declares that font should be treated as for vertical writing and +use \lnum{JIS1990} form for Kanjis. (See, Figure~\ref{FIG:jp90} for an example) + +\begin{figure} +\centering +\jpzerofourexamples\hspace{30pt}\jpninezeroexamples% +\caption{\lnum{JIS2004} vs. \lnum{JIS1990} form.}\label{FIG:jp90} +\end{figure} + +This feature is limited to the single substitution, there are no way to select +a glyph from multiple candidates, such as in \code{aalt}, and specifying +general many-to-many glyph substitutions does not take effect. + +\section{Encryption Support}\label{SEC:encryption} + +\dvipdfmx\ offers basic PDF password security support including +256-bits AES encryption. Only ``Standard'' security handler is supported and +public-key security handlers are currently not supported. +Encryption is enabled by \option{-S} command line option. + +When encrypting the document, up to two passwords can be specified: +an owner password and a user password. If a user attempts to open an encrypted +document that has a user password, PDF applications prompt for a password. +Correctly supplying either password enables the user to open the document to +display or to access to the contents. +Depending on which password (user or owner) was supplied, additional operations +allowed for an opened document is determined; full access for users who opened +the document with the correct owner password or additional operations +controlled by permission flags supplied by the owner of the document for users +who opened the document with the correct user password. + +Access permision flags can be specified via the \option{-P} option. Each bits +of the (unsigned) integer number given to this option represents user access +permissions; +e.g., bit position 3 for allowing ``print'', 4 for ``modify the contents'', +5 for ``copy or extract text'', and so on. +\begin{table}[b] + \centering + \begin{tabular}{lp{8.3cm}}\hline + Bit Position & Meaning \\ \hline\hline + 3 & Print the document. \\ + 4 & Modify the contents of the document. \\ + 5 & Copy or extract text and graphics from the document. \\ + 6 & Add or modify text annotations, fill in interactive form fields. + Creation and modification of interactive form field is also + allowed if bit 4 is set.\\ + \hline + \end{tabular} + \caption{Flag bits and their short explaination for the Revision 2 + Standard Security Handler.} +\end{table} +For examples, +\begin{lstlisting} +dvipdfmx -S -P 0x34 foo.dvi +\end{lstlisting} +allows printing, copying and extraction of text, and adding and modifying +text annotation and filling in interactive form fields (but disallows +modification of the contents of the document). + +The \option{-K} option can be used to specify the encryption key length. +The key length must be multiple of 8 in the range 40 to 128, or 256 (for PDF +version 1.7 plus Adobe Extension or forthcoming PDF version 2.0). + +Password will be asked when encryption is enabled. It may not work well on +Windows platforms. Use the \code{pdf:encrypt} special instead of command line +options in this case. + +The default values for \option{K} is 40 and for \option{-P} is \code{0x003C0}. + +\section{Other Improvements} + +This section briefly describes other improvements made for \dvipdfmx. + +\subsection{Extended Glyph Name Syntax} + +\dvipdfmx\ accepts the following syntax for glyph names in \code{enc} files: +\code{uni0130}, \code{zero.onum} and \code{T\_h.liga}. +Each represents a glyph accessed with Unicode value \code{U+0130}, +oldstyle number for zero and ``Th'' ligature accessed via OpenType +Layout GSUB Feature \code{onum} and \code{liga} respectively. +Note that \dvipdfmx\ does not understand glyph names which directly +use glyph indices such as \code{index0102} or \code{gid2104}, since those +indices are private to each font. + +When \dvipdfmx\ encounters a glyph name, e.g., \code{T\_h.liga}, it first looks +for OpenType \code{post} table if such glyph exists; if it exists, then +\dvipdfmx\ simply uses \code{post} talbe for mapping glyph name to glyph index; +if not, \dvipdfmx\ tries to convert \code{T\_h} to Unicode sequence (U+0054 +U+0068 in this example) via the AGL mapping; then, OpenType cmap table is used +to further converting resulting Unicode sequence to a sequence of glyph indices; +finally, OpenType Layout Feature \code{liga} is applied to get desired glyph. + + +\section{Incompatible Changes}\label{SEC:compatibility} + +There are various minor incompatible changes to \dvipdfm. + +The \option{-C} command line option may be used for compatibility to +\dvipdfm\ or older versions of \dvipdfmx. The \option{-C} option takes flags +meaning +\begin{itemize} + \item bit position 2: Use semi-transparent filling for tpic shading + command, instead of opaque gray color. (requires PDF 1.4) + \item bit position 3: Treat all CID-keyed font as fixed-pitch font. This is + only for compatibility. + \item bit position 4: Do not replace duplicate fontmap entries. + \dvipdfm\ behavior. + \item bit position 5: Do not optimize PDF destinations. Use this if you + want to refer from other files to destinations in the current file. + \item bit position 6: Do not use predictor filter for Flate compression. + \item bit position 7: Do not use object stream. +\end{itemize} + +The remap option \option{-r} in fontmaps is no longer supported and is +silently ignored. The command line option \option{-e} to disable partial +(subset) font embedding is not supported. + +\section{Font Licensing and Embedding} + +In OpenType format, information regarding how a font should be treated +when creating documents can be recorded.% +\footnote{See, `` \href{http://www.microsoft.com/typography/otspec/os2.htm}{OpenType Sepcification: OS/2 -- OS/2 and Windows Metrics Table}''.} +\dvipdfmx\ uses this information to decide whether embedding font is permitted. + +This font embedding information is indicated by a flag called +\code{fsType}; each bit representing different restrictions on font +embedding. +If multiple flag bits are set in \code{fsType}, the least restrictive +license granted takes precedence in \dvipdfmx. +The \code{fsType} flag bits recognized by \dvipdfmx\ is as follows: +\begin{itemize} + \item Installable embedding + \item Editable embedding + \item Embedding for Preview \& Print only +\end{itemize} +\dvipdfmx\ give the following warning message for fonts with `Preview \& +Print only' setting: +\begin{verbatim} + This document contains 'Preview & Print' only licensed font +\end{verbatim} + +For fonts with this type of licensing, font embedding is allowed solely for the +purpose of (on-screen) viewing and/or printing; further editing of the document +or extracting embedded font data for other purposes are not allowed. +One way to ensure this condition is to protect your document with a non-empty +password. + +All other flags are treated as more restrictive license than any of +the above flags and treated as ``No embedding allowed''; e.g., if both +of the editable-embedding flag and unrecognized license flag is set, +the font is treated as editable-embedding allowed, however, if only +unrecognized flags are set, the font is not embedded. + +Embedding flags are preserved in embedded font if the font is embedded +as a TrueType font or a CIDFontType2 CID-keyed font. +For all font embedded as a PostScript font (Type1C and CIDFontType0 +CID-keyed font), they are not preserved. +Only \code{Copyright} and \code{Notice} in the FontInfo dictionary are +preserved in this case. + +Some font vendors put different embedding restrictions for different +condition; e.g., font embedding might be not permitted for commercial +materials unless you acquire ``commercial license'' separately. +Please read EULA carefully before making decision on font usage. + +See, for examples, +\href{http://www.adobe.com/products/type/font-licensing/font-embedding-permissions.html}{Adobe's site on font embedding permissions} +for fonts in the Adobe Type Library. +Microsoft also has a +\href{http://www.microsoft.com/typography/RedistributionFAQ.mspx}{FAQ page on Font Redistribution}. + +For Japanese font in general, embedding permission tend to be somewhat +restrictive. Japanese users should read the statement regarding font +embedding from Japan Typography Association (in Japanese):\medskip + +\url{http://www.typography.or.jp/act/morals/moral4.html} +\medskip + +\dvipdfmx\ does not support full embedding. Only subset embedding is supported. + +\renewcommand{\refname}{Further Reading} +\begin{thebibliography}{99} +\bibitem{ADOBE} Adobe's PDF References and a free copy of +\lnum{ISO 32000-1:2008} standard are available from +``\href{http://www.adobe.com/devnet/pdf.html}{PDF Technology Center}'' +on \href{http://www.adobe.com/devnet.html}{Adobe Developer Connection}. +\bibitem{MICROSOFT} The OpenType Specification is available from Microsoft's +site: +``\href{http://www.microsoft.com/en-us/Typography/OpenTypeSpecification.aspx}% +{OpenType Specification}''. +\bibitem{CHOF} An article regarding DVI specials: Jin-Hwan Cho, +``\href{http://www.tug.org/TUGboat/tb30-1/tb94cho.pdf}{DVI specials for PDF generation}'', +TUGboat, 30(1):6-11, 2009. +\end{thebibliography} + +\section*{GNU Free Documentation License}\label{SEC:FDL} + +This document is distributed under the term of the GNU Free Documentation +License. See, the attached file for copying conditions.% +\marginnote{% +\special{pdf:fstream @fileobj (fdl-1.3.txt)}% +\special{pdf:ann width 10bp height 20bp + << /Type /Annot + /Subtype /FileAttachment + /FS << + /Type /Filespec + /F (fdl-1.3.txt) + /EF << /F @fileobj >> + >> + /Name /PushPin + /C [0.8 0.2 0.2] + /T (Free Software Foundation, Inc.) + /Subj (GNU Free Documentation License) + /Contents (Plain text version of the GNU Free Documentation License.) + >> +}}% + +Or, in case that PDF viewers can not extract attached files, please visit the +following site: +\medskip + +\url{http://www.gnu.org/licenses/fdl.html} + + +\end{document} diff --git a/Master/texmf-dist/doc/dvipdfmx/fdl-1.3.txt b/Master/texmf-dist/doc/dvipdfmx/fdl-1.3.txt new file mode 100644 index 00000000000..2f7e03ca516 --- /dev/null +++ b/Master/texmf-dist/doc/dvipdfmx/fdl-1.3.txt @@ -0,0 +1,451 @@ + + GNU Free Documentation License + Version 1.3, 3 November 2008 + + + Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc. + <http://fsf.org/> + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +0. PREAMBLE + +The purpose of this License is to make a manual, textbook, or other +functional and useful document "free" in the sense of freedom: to +assure everyone the effective freedom to copy and redistribute it, +with or without modifying it, either commercially or noncommercially. +Secondarily, this License preserves for the author and publisher a way +to get credit for their work, while not being considered responsible +for modifications made by others. + +This License is a kind of "copyleft", which means that derivative +works of the document must themselves be free in the same sense. It +complements the GNU General Public License, which is a copyleft +license designed for free software. + +We have designed this License in order to use it for manuals for free +software, because free software needs free documentation: a free +program should come with manuals providing the same freedoms that the +software does. But this License is not limited to software manuals; +it can be used for any textual work, regardless of subject matter or +whether it is published as a printed book. We recommend this License +principally for works whose purpose is instruction or reference. + + +1. APPLICABILITY AND DEFINITIONS + +This License applies to any manual or other work, in any medium, that +contains a notice placed by the copyright holder saying it can be +distributed under the terms of this License. Such a notice grants a +world-wide, royalty-free license, unlimited in duration, to use that +work under the conditions stated herein. The "Document", below, +refers to any such manual or work. Any member of the public is a +licensee, and is addressed as "you". You accept the license if you +copy, modify or distribute the work in a way requiring permission +under copyright law. + +A "Modified Version" of the Document means any work containing the +Document or a portion of it, either copied verbatim, or with +modifications and/or translated into another language. + +A "Secondary Section" is a named appendix or a front-matter section of +the Document that deals exclusively with the relationship of the +publishers or authors of the Document to the Document's overall +subject (or to related matters) and contains nothing that could fall +directly within that overall subject. (Thus, if the Document is in +part a textbook of mathematics, a Secondary Section may not explain +any mathematics.) The relationship could be a matter of historical +connection with the subject or with related matters, or of legal, +commercial, philosophical, ethical or political position regarding +them. + +The "Invariant Sections" are certain Secondary Sections whose titles +are designated, as being those of Invariant Sections, in the notice +that says that the Document is released under this License. If a +section does not fit the above definition of Secondary then it is not +allowed to be designated as Invariant. The Document may contain zero +Invariant Sections. If the Document does not identify any Invariant +Sections then there are none. + +The "Cover Texts" are certain short passages of text that are listed, +as Front-Cover Texts or Back-Cover Texts, in the notice that says that +the Document is released under this License. A Front-Cover Text may +be at most 5 words, and a Back-Cover Text may be at most 25 words. + +A "Transparent" copy of the Document means a machine-readable copy, +represented in a format whose specification is available to the +general public, that is suitable for revising the document +straightforwardly with generic text editors or (for images composed of +pixels) generic paint programs or (for drawings) some widely available +drawing editor, and that is suitable for input to text formatters or +for automatic translation to a variety of formats suitable for input +to text formatters. A copy made in an otherwise Transparent file +format whose markup, or absence of markup, has been arranged to thwart +or discourage subsequent modification by readers is not Transparent. +An image format is not Transparent if used for any substantial amount +of text. A copy that is not "Transparent" is called "Opaque". + +Examples of suitable formats for Transparent copies include plain +ASCII without markup, Texinfo input format, LaTeX input format, SGML +or XML using a publicly available DTD, and standard-conforming simple +HTML, PostScript or PDF designed for human modification. Examples of +transparent image formats include PNG, XCF and JPG. Opaque formats +include proprietary formats that can be read and edited only by +proprietary word processors, SGML or XML for which the DTD and/or +processing tools are not generally available, and the +machine-generated HTML, PostScript or PDF produced by some word +processors for output purposes only. + +The "Title Page" means, for a printed book, the title page itself, +plus such following pages as are needed to hold, legibly, the material +this License requires to appear in the title page. For works in +formats which do not have any title page as such, "Title Page" means +the text near the most prominent appearance of the work's title, +preceding the beginning of the body of the text. + +The "publisher" means any person or entity that distributes copies of +the Document to the public. + +A section "Entitled XYZ" means a named subunit of the Document whose +title either is precisely XYZ or contains XYZ in parentheses following +text that translates XYZ in another language. (Here XYZ stands for a +specific section name mentioned below, such as "Acknowledgements", +"Dedications", "Endorsements", or "History".) To "Preserve the Title" +of such a section when you modify the Document means that it remains a +section "Entitled XYZ" according to this definition. + +The Document may include Warranty Disclaimers next to the notice which +states that this License applies to the Document. These Warranty +Disclaimers are considered to be included by reference in this +License, but only as regards disclaiming warranties: any other +implication that these Warranty Disclaimers may have is void and has +no effect on the meaning of this License. + +2. VERBATIM COPYING + +You may copy and distribute the Document in any medium, either +commercially or noncommercially, provided that this License, the +copyright notices, and the license notice saying this License applies +to the Document are reproduced in all copies, and that you add no +other conditions whatsoever to those of this License. You may not use +technical measures to obstruct or control the reading or further +copying of the copies you make or distribute. However, you may accept +compensation in exchange for copies. If you distribute a large enough +number of copies you must also follow the conditions in section 3. + +You may also lend copies, under the same conditions stated above, and +you may publicly display copies. + + +3. COPYING IN QUANTITY + +If you publish printed copies (or copies in media that commonly have +printed covers) of the Document, numbering more than 100, and the +Document's license notice requires Cover Texts, you must enclose the +copies in covers that carry, clearly and legibly, all these Cover +Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on +the back cover. Both covers must also clearly and legibly identify +you as the publisher of these copies. The front cover must present +the full title with all words of the title equally prominent and +visible. You may add other material on the covers in addition. +Copying with changes limited to the covers, as long as they preserve +the title of the Document and satisfy these conditions, can be treated +as verbatim copying in other respects. + +If the required texts for either cover are too voluminous to fit +legibly, you should put the first ones listed (as many as fit +reasonably) on the actual cover, and continue the rest onto adjacent +pages. + +If you publish or distribute Opaque copies of the Document numbering +more than 100, you must either include a machine-readable Transparent +copy along with each Opaque copy, or state in or with each Opaque copy +a computer-network location from which the general network-using +public has access to download using public-standard network protocols +a complete Transparent copy of the Document, free of added material. +If you use the latter option, you must take reasonably prudent steps, +when you begin distribution of Opaque copies in quantity, to ensure +that this Transparent copy will remain thus accessible at the stated +location until at least one year after the last time you distribute an +Opaque copy (directly or through your agents or retailers) of that +edition to the public. + +It is requested, but not required, that you contact the authors of the +Document well before redistributing any large number of copies, to +give them a chance to provide you with an updated version of the +Document. + + +4. MODIFICATIONS + +You may copy and distribute a Modified Version of the Document under +the conditions of sections 2 and 3 above, provided that you release +the Modified Version under precisely this License, with the Modified +Version filling the role of the Document, thus licensing distribution +and modification of the Modified Version to whoever possesses a copy +of it. In addition, you must do these things in the Modified Version: + +A. Use in the Title Page (and on the covers, if any) a title distinct + from that of the Document, and from those of previous versions + (which should, if there were any, be listed in the History section + of the Document). You may use the same title as a previous version + if the original publisher of that version gives permission. +B. List on the Title Page, as authors, one or more persons or entities + responsible for authorship of the modifications in the Modified + Version, together with at least five of the principal authors of the + Document (all of its principal authors, if it has fewer than five), + unless they release you from this requirement. +C. State on the Title page the name of the publisher of the + Modified Version, as the publisher. +D. Preserve all the copyright notices of the Document. +E. Add an appropriate copyright notice for your modifications + adjacent to the other copyright notices. +F. Include, immediately after the copyright notices, a license notice + giving the public permission to use the Modified Version under the + terms of this License, in the form shown in the Addendum below. +G. Preserve in that license notice the full lists of Invariant Sections + and required Cover Texts given in the Document's license notice. +H. Include an unaltered copy of this License. +I. Preserve the section Entitled "History", Preserve its Title, and add + to it an item stating at least the title, year, new authors, and + publisher of the Modified Version as given on the Title Page. If + there is no section Entitled "History" in the Document, create one + stating the title, year, authors, and publisher of the Document as + given on its Title Page, then add an item describing the Modified + Version as stated in the previous sentence. +J. Preserve the network location, if any, given in the Document for + public access to a Transparent copy of the Document, and likewise + the network locations given in the Document for previous versions + it was based on. These may be placed in the "History" section. + You may omit a network location for a work that was published at + least four years before the Document itself, or if the original + publisher of the version it refers to gives permission. +K. For any section Entitled "Acknowledgements" or "Dedications", + Preserve the Title of the section, and preserve in the section all + the substance and tone of each of the contributor acknowledgements + and/or dedications given therein. +L. Preserve all the Invariant Sections of the Document, + unaltered in their text and in their titles. Section numbers + or the equivalent are not considered part of the section titles. +M. Delete any section Entitled "Endorsements". Such a section + may not be included in the Modified Version. +N. Do not retitle any existing section to be Entitled "Endorsements" + or to conflict in title with any Invariant Section. +O. Preserve any Warranty Disclaimers. + +If the Modified Version includes new front-matter sections or +appendices that qualify as Secondary Sections and contain no material +copied from the Document, you may at your option designate some or all +of these sections as invariant. To do this, add their titles to the +list of Invariant Sections in the Modified Version's license notice. +These titles must be distinct from any other section titles. + +You may add a section Entitled "Endorsements", provided it contains +nothing but endorsements of your Modified Version by various +parties--for example, statements of peer review or that the text has +been approved by an organization as the authoritative definition of a +standard. + +You may add a passage of up to five words as a Front-Cover Text, and a +passage of up to 25 words as a Back-Cover Text, to the end of the list +of Cover Texts in the Modified Version. Only one passage of +Front-Cover Text and one of Back-Cover Text may be added by (or +through arrangements made by) any one entity. If the Document already +includes a cover text for the same cover, previously added by you or +by arrangement made by the same entity you are acting on behalf of, +you may not add another; but you may replace the old one, on explicit +permission from the previous publisher that added the old one. + +The author(s) and publisher(s) of the Document do not by this License +give permission to use their names for publicity for or to assert or +imply endorsement of any Modified Version. + + +5. COMBINING DOCUMENTS + +You may combine the Document with other documents released under this +License, under the terms defined in section 4 above for modified +versions, provided that you include in the combination all of the +Invariant Sections of all of the original documents, unmodified, and +list them all as Invariant Sections of your combined work in its +license notice, and that you preserve all their Warranty Disclaimers. + +The combined work need only contain one copy of this License, and +multiple identical Invariant Sections may be replaced with a single +copy. If there are multiple Invariant Sections with the same name but +different contents, make the title of each such section unique by +adding at the end of it, in parentheses, the name of the original +author or publisher of that section if known, or else a unique number. +Make the same adjustment to the section titles in the list of +Invariant Sections in the license notice of the combined work. + +In the combination, you must combine any sections Entitled "History" +in the various original documents, forming one section Entitled +"History"; likewise combine any sections Entitled "Acknowledgements", +and any sections Entitled "Dedications". You must delete all sections +Entitled "Endorsements". + + +6. COLLECTIONS OF DOCUMENTS + +You may make a collection consisting of the Document and other +documents released under this License, and replace the individual +copies of this License in the various documents with a single copy +that is included in the collection, provided that you follow the rules +of this License for verbatim copying of each of the documents in all +other respects. + +You may extract a single document from such a collection, and +distribute it individually under this License, provided you insert a +copy of this License into the extracted document, and follow this +License in all other respects regarding verbatim copying of that +document. + + +7. AGGREGATION WITH INDEPENDENT WORKS + +A compilation of the Document or its derivatives with other separate +and independent documents or works, in or on a volume of a storage or +distribution medium, is called an "aggregate" if the copyright +resulting from the compilation is not used to limit the legal rights +of the compilation's users beyond what the individual works permit. +When the Document is included in an aggregate, this License does not +apply to the other works in the aggregate which are not themselves +derivative works of the Document. + +If the Cover Text requirement of section 3 is applicable to these +copies of the Document, then if the Document is less than one half of +the entire aggregate, the Document's Cover Texts may be placed on +covers that bracket the Document within the aggregate, or the +electronic equivalent of covers if the Document is in electronic form. +Otherwise they must appear on printed covers that bracket the whole +aggregate. + + +8. TRANSLATION + +Translation is considered a kind of modification, so you may +distribute translations of the Document under the terms of section 4. +Replacing Invariant Sections with translations requires special +permission from their copyright holders, but you may include +translations of some or all Invariant Sections in addition to the +original versions of these Invariant Sections. You may include a +translation of this License, and all the license notices in the +Document, and any Warranty Disclaimers, provided that you also include +the original English version of this License and the original versions +of those notices and disclaimers. In case of a disagreement between +the translation and the original version of this License or a notice +or disclaimer, the original version will prevail. + +If a section in the Document is Entitled "Acknowledgements", +"Dedications", or "History", the requirement (section 4) to Preserve +its Title (section 1) will typically require changing the actual +title. + + +9. TERMINATION + +You may not copy, modify, sublicense, or distribute the Document +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense, or distribute it is void, and +will automatically terminate your rights under this License. + +However, if you cease all violation of this License, then your license +from a particular copyright holder is reinstated (a) provisionally, +unless and until the copyright holder explicitly and finally +terminates your license, and (b) permanently, if the copyright holder +fails to notify you of the violation by some reasonable means prior to +60 days after the cessation. + +Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + +Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, receipt of a copy of some or all of the same material does +not give you any rights to use it. + + +10. FUTURE REVISIONS OF THIS LICENSE + +The Free Software Foundation may publish new, revised versions of the +GNU Free Documentation License from time to time. Such new versions +will be similar in spirit to the present version, but may differ in +detail to address new problems or concerns. See +http://www.gnu.org/copyleft/. + +Each version of the License is given a distinguishing version number. +If the Document specifies that a particular numbered version of this +License "or any later version" applies to it, you have the option of +following the terms and conditions either of that specified version or +of any later version that has been published (not as a draft) by the +Free Software Foundation. If the Document does not specify a version +number of this License, you may choose any version ever published (not +as a draft) by the Free Software Foundation. If the Document +specifies that a proxy can decide which future versions of this +License can be used, that proxy's public statement of acceptance of a +version permanently authorizes you to choose that version for the +Document. + +11. RELICENSING + +"Massive Multiauthor Collaboration Site" (or "MMC Site") means any +World Wide Web server that publishes copyrightable works and also +provides prominent facilities for anybody to edit those works. A +public wiki that anybody can edit is an example of such a server. A +"Massive Multiauthor Collaboration" (or "MMC") contained in the site +means any set of copyrightable works thus published on the MMC site. + +"CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0 +license published by Creative Commons Corporation, a not-for-profit +corporation with a principal place of business in San Francisco, +California, as well as future copyleft versions of that license +published by that same organization. + +"Incorporate" means to publish or republish a Document, in whole or in +part, as part of another Document. + +An MMC is "eligible for relicensing" if it is licensed under this +License, and if all works that were first published under this License +somewhere other than this MMC, and subsequently incorporated in whole or +in part into the MMC, (1) had no cover texts or invariant sections, and +(2) were thus incorporated prior to November 1, 2008. + +The operator of an MMC Site may republish an MMC contained in the site +under CC-BY-SA on the same site at any time before August 1, 2009, +provided the MMC is eligible for relicensing. + + +ADDENDUM: How to use this License for your documents + +To use this License in a document you have written, include a copy of +the License in the document and put the following copyright and +license notices just after the title page: + + Copyright (c) YEAR YOUR NAME. + Permission is granted to copy, distribute and/or modify this document + under the terms of the GNU Free Documentation License, Version 1.3 + or any later version published by the Free Software Foundation; + with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. + A copy of the license is included in the section entitled "GNU + Free Documentation License". + +If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts, +replace the "with...Texts." line with this: + + with the Invariant Sections being LIST THEIR TITLES, with the + Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. + +If you have Invariant Sections without Cover Texts, or some other +combination of the three, merge those two alternatives to suit the +situation. + +If your document contains nontrivial examples of program code, we +recommend releasing these examples in parallel under your choice of +free software license, such as the GNU General Public License, +to permit their use in free software. |