summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/microtype
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2007-07-16 15:54:19 +0000
committerKarl Berry <karl@freefriends.org>2007-07-16 15:54:19 +0000
commit095c21ac9a136a78a974cb1bdcb06215f815eb64 (patch)
tree87a2ffd1b3c67f1485059e6cfad05c92dfe606fd /Master/texmf-dist/source/latex/microtype
parent858c858014703d3a44c1e0bd5c69f14fe2702012 (diff)
microtype 2.2 (14jul07)
git-svn-id: svn://tug.org/texlive/trunk@4600 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/microtype')
-rw-r--r--Master/texmf-dist/source/latex/microtype/microtype.dtx4045
-rw-r--r--Master/texmf-dist/source/latex/microtype/microtype.ins26
2 files changed, 2557 insertions, 1514 deletions
diff --git a/Master/texmf-dist/source/latex/microtype/microtype.dtx b/Master/texmf-dist/source/latex/microtype/microtype.dtx
index 80d185fdffc..ceefb327e10 100644
--- a/Master/texmf-dist/source/latex/microtype/microtype.dtx
+++ b/Master/texmf-dist/source/latex/microtype/microtype.dtx
@@ -1,10 +1,10 @@
%\iffalse meta-comment
% ^^A messages to WinEdt:
-% -*- TeX:DTX:UK -*-
-% smartQuote: English
-% DTXversion: 2.1
+% !Mode:: "TeX:DTX:UK"
+% !smartQuote:: "English"
+% !DTXversion:: "2.2"
% ------------------------------------------------------------------------
-% $Id: microtype.dtx,v 1.40 2007-01-21 16:50:39+01 schlicht Exp schlicht $
+% $Id: microtype.dtx,v 1.45 2007-07-14 16:10:26+02 schlicht Exp schlicht $
% ------------------------------------------------------------------------
% The `microtype' package
% An interface to the micro-typographic extensions of pdfTeX
@@ -31,41 +31,45 @@
\ProvidesFile{microtype.dtx}
%</driver>
%<package|letterspace>\ProvidesPackage
-%<package> {microtype}
-%<letterspace> {letterspace}
+%<package> {microtype}
%<*package>
- [2007/01/21 v2.0 Micro-typography with pdfTeX (RS)]
+ [2007/07/14 v2.2 Micro-typography with pdfTeX (RS)]
%</package>
-%<letterspace> [2007/01/21 v1.0 Robust letterspacing (RS)]
+%<letterspace> {letterspace}[2007/07/14 v1.2 Robust letterspacing (RS)]
%<*config>
%<config>\ProvidesFile
-%<m-t> {microtype.cfg}[2007/01/14 v2.0 microtype main configuration file (RS)]
-%<bch> {mt-bch.cfg}[2005/12/02 v1.4 microtype config. file: Bitstream Charter (RS)]
-%<cmr> {mt-cmr.cfg}[2005/11/07 v1.9 microtype config. file: Computer Modern Roman (RS)]
-%<pad> {mt-pad.cfg}[2005/11/07 v1.5 microtype config. file: Adobe Garamond (RS)]
-%<pmn> {mt-pmn.cfg}[2004/11/07 v1.2 microtype config. file: Adobe Minion (HH)]
-%<ppl> {mt-ppl.cfg}[2005/11/16 v1.6 microtype config. file: Palatino (RS)]
-%<ptm> {mt-ptm.cfg}[2006/04/20 v1.7 microtype config. file: Times (RS)]
-%<ugm> {mt-ugm.cfg}[2006/01/26 v1.0 microtype config. file: URW Garamond (RS)]
-%<msa> {mt-msa.cfg}[2006/02/04 v1.1 microtype config. file: AMS symbols (a) (RS)]
-%<msb> {mt-msb.cfg}[2005/06/01 v1.0 microtype config. file: AMS symbols (b) (RS)]
-%<euf> {mt-euf.cfg}[2006/07/03 v1.1 microtype config. file: AMS Euler Fraktur (RS)]
-%<eur> {mt-eur.cfg}[2006/07/31 v1.1 microtype config. file: AMS Euler Roman (RS)]
-%<eus> {mt-eus.cfg}[2006/07/28 v1.2 microtype config. file: AMS Euler Script (RS)]
-%<zpeu> {mt-zpeu.cfg}[2006/05/04 v1.0 microtype config. file: Adobe Euro (RS)]
-%<euroitc> {mt-euroitc.cfg}[2006/05/04 v1.0 microtype config. file: ITC Euro (RS)]
-%<mvs> {mt-mvs.cfg}[2006/07/05 v1.1 microtype config. file: Marvosym Euro (RS)]
+%<m-t> {microtype.cfg}[2007/07/14 v2.2 microtype main configuration file (RS)]
+%<bch> {mt-bch.cfg}[2007/03/03 v1.5 microtype config. file: Bitstream Charter (RS)]
+%<blg> {mt-blg.cfg}[2007/07/14 v1.0 microtype config. file: Bitstream Letter Gothic(RS)]
+%<cmr> {mt-cmr.cfg}[2005/11/07 v1.9 microtype config. file: Computer Modern Roman (RS)]
+%<pad> {mt-pad.cfg}[2005/11/07 v1.5 microtype config. file: Adobe Garamond (RS)]
+%<pmn> {mt-pmn.cfg}[2004/11/07 v1.2 microtype config. file: Adobe Minion (HH)]
+%<ppl> {mt-ppl.cfg}[2005/11/16 v1.6 microtype config. file: Palatino (RS)]
+%<ptm> {mt-ptm.cfg}[2006/04/20 v1.7 microtype config. file: Times (RS)]
+%<ugm> {mt-ugm.cfg}[2006/01/26 v1.0 microtype config. file: URW Garamond (RS)]
+%<msa> {mt-msa.cfg}[2006/02/04 v1.1 microtype config. file: AMS symbols (a) (RS)]
+%<msb> {mt-msb.cfg}[2005/06/01 v1.0 microtype config. file: AMS symbols (b) (RS)]
+%<euf> {mt-euf.cfg}[2006/07/03 v1.1 microtype config. file: AMS Euler Fraktur (RS)]
+%<eur> {mt-eur.cfg}[2006/07/31 v1.1 microtype config. file: AMS Euler Roman (RS)]
+%<eus> {mt-eus.cfg}[2006/07/28 v1.2 microtype config. file: AMS Euler Script (RS)]
+%<zpeu> {mt-zpeu.cfg}[2006/05/04 v1.0 microtype config. file: Adobe Euro (RS)]
+%<euroitc> {mt-euroitc.cfg}[2006/05/04 v1.0 microtype config. file: ITC Euro (RS)]
+%<mvs> {mt-mvs.cfg}[2006/07/05 v1.1 microtype config. file: Marvosym Euro (RS)]
%</config>
%
%<*driver>
\documentclass[10pt,a4paper]{ltxdoc}
+\makeatletter
% Let's abolish CM! We use Charter and Letter Gothic
% (for the pre-built documentation on CTAN):
% \def\rmdefault{bch}
% \def\ttdefault{blg}
+\usepackage[latin1]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{textcomp}
-\usepackage[expansion=false,kerning=true]{microtype} % it's a web document
+\GetFileInfo{microtype.dtx}
+\usepackage[expansion=false,kerning=true]{microtype}[\filedate]
+\usepackage{ifpdf}
\DeclareMicrotypeSet*[protrusion]
{ doc }
{ encoding = {*, TS1, OMS},
@@ -79,25 +83,36 @@
{ encoding = T1,
family = blg }
{ _ = {100,100} } % underscores shouldn't touch
-\makeatletter
- \IfFileExists{t1mgt.fd} % Fraktur font in section \ref{sec:lettersp}
- {\SetTracking{encoding=T1,family=mgt}{150}
- \newcommand\textfrak[1]{{\fontfamily{mgt}\selectfont ##1}}}
- {\IfFileExists{yfonts.sty}
- {\usepackage{yfonts}
- \SetTracking{encoding=LY,family=yfrak}{150}}
- {\let\textfrak\@gobble}
- }
-\usepackage{ifpdf}
+ \ifx\tagcode\undefined\else % disable ?` and !` ligatures (sample in section \ref{sec:disable-ligatures})
+ \DisableLigatures[?,!]{encoding = *, family = rm* }
+ \fi
+ \IfFileExists{t1mwr.fd}{ % Fraktur sample in section \ref{sec:lettersp}
+ \newcommand\textfrak[1]{{\fontfamily{mwr}\selectfont ##1}}
+ \ifpdf
+ \SetTracking[no ligatures={f}]{encoding=T1,family=mwr}{100}
+ \fi
+ }{
+ \IfFileExists{yfonts.sty}{
+ \usepackage{yfonts}
+ \ifpdf
+ \SetTracking[no ligatures={f}]{encoding=LY,family=yfrak}{100}
+ \fi
+ }{
+ \let\textfrak\@gobble
+ }
+ }
\tolerance=700
-\ifpdf\ifnum\pdftexversion<140 \else
- \ifx\pdfcolorstack\@undefined\else % pdftex 1.40.0, including textmatrix patch
+\let\printlogo\@empty
+\ifpdf
+ \ifnum\pdftexversion<140 \else % pdftex 1.40, including textmatrix patch
\microtypesetup{expansion=alltext,step=1} % hence we can activate expansion ...
- \tolerance=300 % ... and can apply almost TeX's default tolerance
+ \tolerance=300 % ... and make TeX almost as tolerant as it normally is
\g@addto@macro\macrocode{\pdfadjustspacing\z@}
-\fi\fi\fi
-\let\printlogo\@empty
-\ifpdf\InputIfFileExists{microtype-logo.dtx}\relax\relax\fi
+ \fi
+ \InputIfFileExists{microtype-logo.dtx}\relax\relax
+\else
+ \let\lsstyle\relax
+\fi
\usepackage{booktabs}
\usepackage{array}
\newcolumntype{L}[1]{p{#1}<{\raggedright}}
@@ -108,18 +123,19 @@
\definecolor{thegrey} {gray}{0.5}
\definecolor{theshade}{gray}{0.94}
\definecolor{theframe}{gray}{0.75}
+\usepackage{graphicx}
% general layout
\frenchspacing
-\expandafter\newif\csname ifcharter\endcsname
+\expandafter\newif\csname ifcmr\endcsname
\long\def\@tempa{cmr}
\ifx\rmdefault\@tempa
+ \cmrtrue
\def\PackageFont{\sffamily}
\def\match{\textbullet}
\def\textgeq{$\geq$}
\linespread{1}\normalfont
\setlength\textheight{47\baselineskip}
\else
- \chartertrue
\def\bfdefault{b}
\def\Module#1{{\color{theblue}$\langle$\textit{#1}$\rangle$}}
\DeclareRobustCommand{\LaTeX}{L\kern-.26em{\sbox\z@ T\vbox to\ht\z@{%
@@ -140,6 +156,15 @@
{paragraph}{4}{0pt}%
{3.25ex plus 1ex minus .2ex}{-1em}%
{\normalfont\normalsize\itshape}}
+% title
+\def\@maketitle{%
+ \newpage\null\vskip 2em
+ \begin{center}\let\footnote\thanks
+ {\LARGE \@title\par}\vskip 1.5em
+ {\large \parbox{.33\textwidth}{\centering\@author}%
+ \parbox{.33\textwidth}{\centering\@date}}%
+ \vskip1.5em\rule{.66\textwidth}{.4pt}%
+ \end{center}\par\vskip1.5em}
% headers
\headheight=15pt
\def\ps@MTheadings{%
@@ -150,16 +175,15 @@
}}\hss}
\let\@oddfoot\@empty
\let\@mkboth\markboth
- \def\sectionmark##1{\markboth{\textls*[50]{\MakeUppercase{##1}}}{}}
+ \def\sectionmark##1{\markboth{\textls*[60]{\MakeUppercase{##1}}}{}}
\def\subsectionmark##1{\markright{: ##1}}}
\pagestyle{MTheadings}
% toc
\let\l@section@\l@section
\def\l@section{\vskip -.75ex\l@section@}
-\let\l@subsection@\l@subsection
-\def\l@subsection{\vskip.25ex \penalty\@secpenalty \l@subsection@}
+\def\l@subsection{\vskip.25ex \penalty\@secpenalty \@dottedtocline{2}{1.5em}{2.7em}}
\def\l@subsubsection#1#2{%
- \leftskip 3.8em
+ \leftskip 4.2em
\rightskip 2em plus 1fil
\parindent 0pt
{\let\numberline\@gobble{\small[#1~--~#2]}}}
@@ -176,7 +200,7 @@
\fi
\def\defspecial@toc#1#2#3{\long\def#1{%
\ifpdf\phantomsection\specialoutline\pdfbookmark[1]{#2}{#3}\normaloutline\fi
- \section*{#2}\@mkboth{\textls*[50]{\MakeUppercase{#2}}}{}%
+ \section*{#2}\@mkboth{\textls*[60]{\MakeUppercase{#2}}}{}%
\@starttoc{#3}}}
\defspecial@toc\tableofcontents\contentsname{toc}
\defspecial@toc\listoftables\listtablename{lot}
@@ -198,54 +222,85 @@
\leavevmode\hbox to 15pt{\@thefnmark\hss}#1}
\skip\@mpfootins=0.5\baselineskip
% lists
-\def\descriptionlabel#1{\hspace\labelsep\normalfont#1:}
-\def\@listi{\leftmargin\leftmargini
+\setlength\leftmargini{15pt}
+\setlength\leftmarginii{12.5pt}
+\setlength\leftmarginiii{10pt}
+\def\@listi{\leftmargin \leftmargini
\parsep 4.5pt plus 1pt minus 1pt
\topsep 4.5pt plus 1pt minus 1pt
\itemsep 0pt}
\let\@listI\@listi
-\setlength\leftmargini{15pt}
-\setlength\leftmarginii{15pt}
-\setlength\leftmarginiii{10pt}
+\def\descriptionlabel#1{\hspace\labelsep\normalfont#1:}
+\renewenvironment{itemize}
+ {\ifnum \@itemdepth >\thr@@\@toodeep\else
+ \advance\@itemdepth\@ne
+ \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}%
+ \expandafter\list
+ \csname\@itemitem\endcsname
+ {\ifnum\@itemdepth=\@ne\leftmargin 0pt\fi
+ \def\makelabel##1{\hss\llap{##1}}}%
+ \fi}
+ {\endlist}
+\newenvironment{enum}[1][0]
+ {\list\labelenumi
+ {\usecounter{enumi}\setcounter{enumi}{#1}\addtocounter{enumi}{-1}%
+ \renewcommand\labelenumi{\texttt{\theenumi}:}%
+ \leftmargin 30pt
+ \itemindent-15pt
+ \labelwidth 15pt
+ \labelsep 0pt
+ \def\makelabel##1{##1\hss}}}
+ {\endlist}
\newenvironment{options}
- {\list{}{\leftmargin 0pt
- \labelwidth 0pt
- \labelsep 1em
- \itemindent \labelsep}}
+ {\list{}
+ {\leftmargin 0pt
+ \labelwidth 0pt
+ \labelsep 1em
+ \itemindent \labelsep
+ \lstset{belowskip=0pt}}}
{\endlist}
% tables
\setlength\tabcolsep{2pt}
\long\def\@makecaption#1#2{%
\sbox\@tempboxa{\footnotesize\itshape#1: #2}%
- \hb@xt@\hsize{\box\@tempboxa\hfil}%
+ \ifdim \wd\@tempboxa >\hsize
+ \footnotesize\itshape#1: #2\par
+ \else
+ \hb@xt@\hsize{\box\@tempboxa\hfil}%
+ \fi
\vskip 6pt}
% index and change log
\IndexPrologue{\section{Index}%
Links refer to the page where the corresponding entry is described (bold face)
resp. occurs. Plain numbers refer to the code line where the corresponding entry
is defined (underlined) resp. used.}
-\GlossaryPrologue{\section{Change History}\label{sec:changes}\vspace*{-2\multicolsep}}
+\GlossaryPrologue{\section{Change History}\label{sec:changes}\vspace*{-\multicolsep}}
+ %\setcounter{finalcolumnbadness}{100}
%\raggedcolumns
-\setcounter{finalcolumnbadness}{100}
\setcounter{IndexColumns}{2}
\def\IndexMin{12\baselineskip}
\g@addto@macro\IndexParms{\footnotesize}
\def\GlossaryParms{\IndexParms
- \def\@idxitem ##1##2\efill{\end{multicols}
- \begin{multicols}{2}[\subsubsection*{\if##1v\relax Version ##2
+ \def\@idxitem ##1##2\efill{%
+ \end{multicols}
+ \begin{multicols}{2}
+ [\subsubsection*{\if##1v\relax Version ##2
(\csname MTversiondate##2\endcsname)\else ##2\fi}][6\baselineskip]
+ \ifpdf \phantomsection \pdfbookmark[2]{\if##1v\relax ##2
+ (\csname MTversiondate##2\endcsname)\else ##2\fi}{subsection##2}\fi
\GlossaryParms \rightskip 15pt plus 5pt
\let\item\@idxitem
\ignorespaces \makeatletter \scan@allowedfalse}%
- \def\subitem{\par\hangindent 25pt}%
- \def\subsubitem{\subitem\hspace*{15pt}}}
+ \def\subitem{\par\hangindent 15pt}%
+ \def\subsubitem{\subitem\hspace*{7.5pt}}}
% macrocode
\MacroTopsep=0pt
\MacrocodeTopsep=3pt
-\settowidth\MacroIndent{\scriptsize 0000}
-\def\theCodelineNo{\reset@font\color{thegrey}\scriptsize\arabic{CodelineNo}}
+\setlength\MacroIndent{0pt}
+\def\theCodelineNo{\reset@font\color{thegrey}\scriptsize\arabic{CodelineNo}\,}
\def\MacroFont{\ttfamily\small}
\def\AltMacroFont{\ttfamily\footnotesize}
+\def\PrintMacroName#1{\strut\MacroFont\string #1\hskip15pt}
\def\ImplementationSettings{%
\linespread{1}%
\hfuzz=16pt
@@ -303,29 +358,31 @@
\DeclareRobustCommand\opt[1]{{\ttfamily#1}\@bsphack\CatIndex{#1}{option}\@esphack}
\DeclareRobustCommand\file[1]{{\ttfamily#1}}
% ... and whistles
-{\catcode`\"\active
+{\catcode`\$\active
\gdef\verbatim#1
- {\catcode`\"\active \def"##1"{\colorbox{theshade}{%
+ {\catcode`\$\active \def$##1${\colorbox{theshade}{%
\textrm{Text lost! Please install the \pkg{listings} package.}}}%
\@beginparpenalty\predisplaypenalty\@verbatim\MacroFont
\frenchspacing\@vobeyspaces\expandafter\@xverbatim\@gobble}}
\IfFileExists{listings.sty}{
\usepackage{listings}
\lstset{
- gobble=1,columns=flexible,keepspaces,upquote,escapechar=",
+ gobble=1,columns=flexible,keepspaces,upquote,escapechar=$,
basicstyle=\MacroFont,
keywords=[0]{\microtypesetup,\DeclareMicrotypeSet,\UseMicrotypeSet,
- \DeclareMicrotypeSetDefault,\SetProtrusion,\SetExpansion,\DisableLigatures,
- \DeclareCharacterInheritance,\DeclareMicrotypeAlias,\LoadMicrotypeFile,
- \microtypecontext,\Microtype@Hook,\SetExtraSpacing,\SetExtraKerning,
- \SetTracking,\textls,\lsstyle,\lslig,\DeclareMicrotypeBabelHook},
+ \DeclareMicrotypeSetDefault,\SetProtrusion,\SetExpansion,\SetTracking,
+ \SetExtraSpacing,\SetExtraKerning,\DisableLigatures,\DeclareCharacterInheritance,
+ \DeclareMicrotypeVariants,\DeclareMicrotypeAlias,\DeclareMicrotypeBabelHook,
+ \LoadMicrotypeFile,\microtypecontext,\textmicrotypecontext,
+ \textls,\lsstyle,\lslig,\Microtype@Hook},
keywordstyle=[0]\color{thegreen},
keywords=[1]{protrusion,expansion,activate,DVIoutput,draft,final,verbose,
- config,factor,auto,stretch,shrink,step,selected,unit,context,
- tracking,spacing,kerning,letterspace,babel}, % defersetup
+ config,factor,auto,stretch,shrink,step,selected,unit,context,%defersetup,
+ tracking,spacing,kerning,letterspace,babel,no ligatures}, % there's a \nobreakspace in this line
keywordstyle=[1]\color{thered},
comment=[l]\%,
commentstyle=\color{thegrey}\itshape,
+ alsoother={0123456789$_},
frame=single,backgroundcolor=\color{theshade},rulecolor=\color{theframe},
xleftmargin=3.4pt,xrightmargin=3.4pt,belowskip=\smallskipamount
}
@@ -352,7 +409,7 @@
pdfsubject={An interface to the micro-typographic extensions of pdfTeX},
pdfkeywords={TeX, LaTeX, pdftex, typography, micro-typography,
character protrusion, margin kerning, optical alignment, font expansion,
- font scaling, hz, kerning, spacing, interword glue, letterspacing, tracking}
+ font scaling, hz, kerning, spacing, glue, letterspacing, tracking}
]{hyperref}
\pdfcatalog{/Lang(en-GB)}
\ifnum\pdftexversion < 130 \else
@@ -360,7 +417,7 @@
\IfFileExists{hyperxmp.sty}{
\usepackage{hyperxmp}
\hypersetup{%
- pdfcopyright={\textcopyright\ 2004--2006 R Schlicht\012%
+ pdfcopyright={\textcopyright\ 2004--2007 R Schlicht\012%
This work may be distributed and/or modified under the conditions
of the LaTeX Project Public License, either version 1.3c of this
license or (at your option) any later version.\&\#xA;%
@@ -396,28 +453,34 @@
{mailto:<w.m.l@gmx.net>%20Robert%20Schlicht?subject=[microtype%20\fileversion]}
{\texttt{w.m.l@gmx.net}}}}
% the samples on the first page, utilising nested optional content groups (aka. layers):
- \ifnum\pdftexversion<140 \else \ifx\pdfcolorstack\@undefined \else
- \def\mt@layer#1#2{\pdfliteral{/OC/#1 BDC}#2\pdfliteral{EMC}}
+ \ifnum\pdftexversion<140 \else
+ \def\mt@layer#1#2{\pdfliteral direct{/OC/#1 BDC}#2\pdfliteral direct{EMC}}
\ifx\mt@objects\@undefined\let\mt@objects\@empty\fi
+ \ifx\mt@order \@undefined\let\mt@order \@empty\fi
\let\mt@resources\@empty
\def\mt@register#1#2{%
\immediate\pdfobj{<< /Type/OCG /Name(#1:#2) >>}
\expandafter\xdef\csname mt@#1@#2\endcsname{\the\pdflastobj\space 0 R }
- \xdef\mt@objects{\mt@objects\csname mt@#1@#2\endcsname}
+ \xdef\mt@objects {\mt@objects \csname mt@#1@#2\endcsname}
+ \xdef\mt@order {\mt@order \csname mt@#1@#2\endcsname}
\xdef\mt@resources{\mt@resources/#1#2 \csname mt@#1@#2\endcsname}}
- \mt@register{Protrusion}{true}\mt@register{Protrusion}{false}
- \mt@register{Expansion} {true}\mt@register{Expansion} {false}
- \mt@register{invisible}{}
+ \xdef\mt@order{\mt@order[(Sample)}
+ \mt@register{Protrusion}{true} \mt@register{Protrusion}{false}
+ \mt@register{Expansion} {true} \mt@register{Expansion} {false}
+ \mt@register{invisible}{}
+ \xdef\mt@order{\mt@order]}
\pdfcatalog{/OCProperties <<
- /OCGs [\mt@objects]
- /D << /Order [\mt@objects]
- /BaseState/ON
- /OFF [\mt@Protrusion@true \mt@Expansion@true \mt@invisible@] >> >>}
+ /OCGs [\mt@objects]
+ /D << /Order [\mt@order]
+ /BaseState/ON
+ /OFF [\mt@Protrusion@true \mt@Expansion@true \mt@invisible@] >> >> }
\newbox\mt@box
+ \newdimen\mt@unvdimen
\def\mt@place#1{%
+ \vskip-\mt@unvdimen
\setbox\mt@box\vbox{#1}%
- \@tempdima\dimexpr\ht\mt@box+\dp\mt@box\relax
- \unvbox\mt@box \vskip-\@tempdima\relax}
+ \mt@unvdimen\dimexpr\ht\mt@box+\dp\mt@box\relax
+ \unvbox\mt@box}
\def\mt@pseudo@marg#1{%
\mt@place{\llap{\vbox{%
\hsize\marginparwidth
@@ -433,8 +496,8 @@
/BS << /Type/Border/W 1 /S/D /D[4 1] >>
/H/O /C[0.65 0.04 0.07] /Contents(Click to Toggle #1!)
%/OC << /Type/OCMD /VE[/Not \mt@invisible@] >> % not honoured by older viewers
- /A << /S/SetOCGState /State[/Toggle \csname mt@#1@false\endcsname
- \csname mt@#1@true\endcsname] >>}
+ /A << /S/SetOCGState /State[/Toggle \csname mt@#1@true\endcsname
+ \csname mt@#1@false\endcsname] >>}
#1 \hfill\pdfendlink & \mt@layer{#1true}{\rlap{on}}\mt@layer{#1false}{off}}
\renewcommand\microtypesample[1]{%
\begingroup
@@ -454,25 +517,24 @@
\mt@show@sample{false}{false}
\mt@show@sample{false}{true}
\mt@show@sample{true} {false}
- % for compatibility with older PDF viewers that don't support OCGs, we
- % add a layer that contains a white box, which will hide the underlying
- % layers for older viewers, and will be ignored by PDF 1.5 capable viewers.
\mt@layer{invisible}{%
+ % for compatibility with older PDF viewers that don't support OCGs, we
+ % add a layer that contains a white box, which will hide the underlying
+ % layers for older viewers, and will be ignored by PDF 1.5 capable viewers.
\mt@place{\rlap{\hskip-\marginparwidth \color{white}%
- \vrule width\dimexpr\hsize+\marginparwidth\relax height\@tempdima}}
+ \vrule width\dimexpr\hsize+\marginparwidth\relax height\mt@unvdimen}}
\mt@pseudo@marg{\color{thered}%
If you had a \acronym{PDF} viewer that understands
\acronym{PDF}\,{\smaller1.5}, you could view the effect of the
micro-typographic features by clicking on the links.\strut
\\\vphantom{\colorbox{white}{\tabular l\\\addlinespace\\\endtabular}}%
\\[0.3\baselineskip] Both features are enabled throughout this document.}}
- \def\mt@place##1{\setbox\mt@box\vbox{##1}\unvbox\mt@box}
\mt@show@sample{true}{true}
\vskip 4pt
\endgroup
\edef\x{\pdfpageresources{/Properties <<\mt@resources>>}}\x}
\def\emptypdfpageresources{\pdfpageresources{}}
- \fi\fi
+ \fi
\else
\usepackage{url}
\newcommand\hyperref[2][]{#2}
@@ -483,14 +545,22 @@
\let\mailto\texttt
\def\mailtoRS{\mailto{w.m.l@gmx.net}}
\fi
-\hyphenation{Ha-rald Har-ders Ber-nard Ku-char-czyk Jac-kow-ski Ste-phan}
+\ifx\l@ukenglish\@undefined
+ \hyphenation{let-ter-spac-ing let-ter-spaced let-ter-space}
+\else
+ \language=\l@ukenglish
+\fi
+\hyphenation{Ha-rald Har-ders Ber-nard Ku-char-czyk Jac-kow-ski Ste-phan
+ with-out}
% abbreviations
\DeclareRobustCommand\thanh{H\`an Th\^e%
\ifx\eTeXversion\undefined \llap{\raisebox{0.5ex}{\'{}}}
\else \llap{\raisebox{0.45ex}{\'{}\kern\dimexpr.05em-2\fontdimen1\font\relax}}
\fi Th\`anh}
\def\pdftex{\texorpdfstring{pdf\kern.05em\TeX}{pdfTeX}}
+\def\luatex{\texorpdfstring{Lua\TeX}{LuaTeX}}
\def\etex{\mbox{e-\TeX}}
+\def\nonetex{\mbox{\rlap{\kern.05em/}e-\TeX}} % aka. \TeX
\def\microtype{{\PackageFont microtype}}
\def\fontdim{\cmd\fontdimen\,}
\def\eg{e.\,g.}
@@ -500,11 +570,14 @@
\advance\@tempcnta-7 \ifcase\@tempcnta\tiny\or\scriptsize\or
\footnotesize\or\small\or\or\normalsize\or\or\large\or\or\or\Large\fi}
\DeclareRobustCommand\acronym[1]{\texorpdfstring
- {{\smaller\ifcharter\textls[60]{#1}\else#1\fi}}{#1}}
+ {{\smaller\ifcmr #1\else\textls[60]{#1}\fi}}{#1}}
{\catcode`\<=\active
\AtBeginDocument{\catcode`\<=\active
\def<#1>{\acronym{#1}}
- \def\contributor#1 <#2\at#3>{\textit{#1}}}}
+ \def\contributor#1 <#2\at#3>{\@contributor{#1}{#2@#3}}
+ \DeclareRobustCommand\@contributor[2]{\textit{#1}}
+ %\DeclareRobustCommand\@contributor[2]{\href{mailto:#2}{\textit{#1}}}
+ }}
\CodelineIndex
\EnableCrossrefs
\RecordChanges
@@ -515,37 +588,45 @@
%</driver>
% \fi
%
+%^^A |microtype| n. [Gr. mikros, small; typos, type] (CNID: Anthozoa)
+%^^A A normal mesentery arrangement. see -> macrotype.
+%^^A (Armand R. Maggenti, Online Dictionary of Invertebrate Zoology: M, 2005,
+%^^A http://digitalcommons.unl.edu/onlinedictinvertzoology/14)
+%
% ^^A -------------------------------------------------------------------------
%\GeneralChanges*
%\changes{v1.0}{2004/09/11}{Initial version}
-%\changes{v2.0}{2006/12/29}{new package \pkg{letterspace}: a stripped-down version}
+%\changes{v2.0}{2006/12/29}{new package \pkg{letterspace}: a stripped-down version,
+% containing the letterspacing commands only}
%\GeneralChanges{Documentation}
%\changes{v1.9b}{2006/01/13}{activate expansion in the distributed <PDF>}
+%\changes{v2.2}{2007/04/01}{logo transparency and amusement}
+% ^^A Adobe Reader 8 had serious bugs with transparency. Fixed in 8.1.
%
% \GetFileInfo{microtype.dtx}
% \title{\printlogo
% \textls{The \microtype\ package}\\[.3\baselineskip]\large
% An interface to the micro-typographic extensions of \pdftex}
-% \author{R Schlicht\quad\mailtoRS}
-% \date{\fileversion\ --- \filedate}
+% \author{R Schlicht\\\mailtoRS}
+% \date{\fileversion\\\filedate}
%
% \maketitle \thispagestyle{empty}
%
%\begin{abstract}
%\noindent
-% The \microtype\ package provides an interface to the micro-typographic
+% The \microtype\ package provides a \LaTeX\ interface to the micro-typographic
% extensions of \pdftex: most prominently, character protrusion and font
% expansion, furthermore the adjustment of interword spacing and additional
% kerning, as well as hyphenatable letterspacing (tracking) and the possibility
-% to disable all ligatures of a font.
+% to disable all or selected ligatures.
% It allows to apply these features to customisable sets of fonts, and to
% configure all micro-typographic aspects of the fonts in a straight-forward
% and flexible way. Settings for various fonts are provided.\footnote{
% Currently, this package provides protrusion settings for Computer Modern
% Roman, Palatino, Times, <URW> Garamond, Adobe Garamond and Minion,
-% Bitstream Charter, and the <AMS> symbols and Euler fonts, for various Euro
-% symbol fonts, as well as some generic settings for unknown fonts.
-% Contributions are very welcome.}
+% Bitstream Charter and Letter Gothic, the <AMS> symbols and Euler fonts, for
+% various Euro symbol fonts, as well as some generic settings for unknown
+% fonts. Contributions are very welcome.}
%
% Note that font expansion and character protrusion will only work with
% \pdftex, at least version 0.14f. Automatic font expansion requires version
@@ -559,17 +640,17 @@
% section~\ref{sec:lettersp}).
%
%\bigskip\noindent
-% This package is copyright \textcopyright\ 2004\kern1pt--2007 R Schlicht.
+% This package is copyright \textcopyright\ 2004\kern.07em--2007 R Schlicht.
% It may be distributed and/or modified under the conditions of the
-% \IfFileExists{lppl.tex}{\hyperref[LPPL:LPPL]}\relax
+% \IfFileExists{lppl.tex}{\hyperref[LPPL:LPPL]}{\href{http://www.latex-project.org/lppl/}}
% {\LaTeX\ Project Public License},
-% either version 1.3c of this license or (at your option) any later version.
+% either version~1.3c of this license or (at your option) any later version.
% This work has the <LPPL> maintenance status `author-maintained'.
%\end{abstract}
%
%
%\newpage
-%\emptypdfpageresources
+%\emptypdfpageresources ^^A layout: layers of the logo
%\tableofcontents
%\listoftables
%
@@ -639,7 +720,8 @@
% pose a problem any longer. The \microtype\ package provides the possibility
% to change the tracking of customisable sets of fonts, \eg, small capitals. It
% also introduces two new commands \cs{textls} and \cs{lsstyle} for ad-hoc
-% \textls{letterspacing}, which can be used like the normal text commands.
+% letterspacing, which can be used like the normal text commands. Note that
+% letterspacing only works in <PDF> mode.
%
% \emph{Adjustment of interword spacing} is based upon the idea that in order to
% achieve a uniform greyness of the text, the space between words should also
@@ -675,7 +757,7 @@
% The possibility, finally, to \emph{disable all ligatures} of a font may be
% useful for typewriter fonts.
%
-%\emptypdfpageresources ^^A layout
+%\emptypdfpageresources ^^A layout: layers of the sample
%\bigskip\noindent
% The \microtype\ package provides an interface to all these micro-typographic
% extensions. All micro-typographic aspects may be customised to your taste and
@@ -683,7 +765,7 @@
% of all options and customisation possibilities.
%
%
-%\section{Invoking the Package}
+%\section{Getting Started}
%
% There is nothing surprising in loading this package:
%\begin{verbatim}[morekeywords={[1]{microtype}}]
@@ -693,9 +775,30 @@
% fine-tuning the micro-typographic appearance of your document (which would
% seem unlikely, since using this package is proof of your interest in
% typographic issues), you may actually skip the rest of this document.
+%^^A
+% If this, on the other hand, does not satisfy you -- be it for theoretical or
+% practical reasons -- this manual will guide you on the path to the desired
+% results along the following milestones:
%
+%\changes{v2.2}{2007/06/06}{add overview}
+%\begin{itemize}
+% \item Enable the respective micro-typographic feature, either via the
+% respective package option or with the \cs{microtypesetup} command
+% (section~\ref{sec:options}).
+% \item Select the fonts to which this feature should be applied by declaring
+% and activating `sets of fonts'. Some sets are predefined, which may be
+% activated directly in the package options (section~\ref{sec:font-sets}).
+% \item Fine-tune the micro-typographic settings of the fonts or sets of fonts
+% (section~\ref{sec:fine-tuning}).
+% \item If you're of the kind who always wants to go further, you'll
+% certainly be interested in the possibility of context-sensitive setup
+% (section~\ref{sec:context}).
+% \item Should you encounter any obstacles, follow the hints and caveats
+% (section~\ref{sec:caveats}).
+%\end{itemize}
%
-%\section{Options}
+%
+%\section{Options}\label{sec:options}
%
% Like many other \LaTeX\ packages, the \microtype\ package accepts options in
% the well known |key=value| syntax. In the following, you'll find a
@@ -792,19 +895,22 @@
% otherwise, it will be disabled.
% If \opt{auto} is set to false, the fonts for all expansion steps must exist
% (with files called \meta{font~name}\texttt{\textpm}\meta{expansion value},
-% \eg, \file{cmr12+10}, as described in the \cite{pdftexman}). If expanded
-% instances of the fonts are available, they will be used regardless whether
-% \opt{auto} is true or not.
+% \eg, \file{cmr12+10}, as described in the \cite{pdftexman}).
+%\iffalse ^^A no longer true (1.40?)
+% If expanded instances of the fonts are available, they will be used
+% regardless whether \opt{auto} is true or not.
+%\fi
%
%\changes{v1.9}{2005/08/27}{add remark about Type\,1 fonts required for
% automatic font expansion}
-% Automatic font expansion requires fonts in Type\,1 format. Therefore, if you
+% Automatic font expansion does not work with bitmap fonts. Therefore, if you
% are using the Computer Modern Roman fonts in <T1> encoding\footnote{
% En passant, it may be noted that Type\,1 format and <T1> encoding are in
% no other way related than that both start with a `T' and end with a `1'.},
% you should either install the \pkg{cm-super} fonts or use the Latin Modern
% fonts (package \pkg{lmodern}).
%
+%\ifcmr\pagebreak\fi ^^A layout
%\bigskip
%\Describe{Option}{stretch}{:integer}[20]
%\DescribeOption{shrink}
@@ -851,10 +957,10 @@
%\subsection{Option for Tracking/Letterspacing}\label{sub:option-tracking}
%
%\Describe{Option}{letterspace}{:integer}[100]
-% This option changes the default amount for tracking (see
-% section~\ref{sub:tracking}) resp. letterspacing (see
-% section~\ref{sec:lettersp}). The amount is specified in thousandth of 1em;
-% admissible values are in the range of \textminus1000 to +1000.
+% This option changes the default amount for tracking (see section~\ref{sub:tracking})
+% resp. letterspacing (see section~\ref{sec:lettersp}). The amount is specified
+% in thousandths of 1em; admissible values are in the range of \textminus1000
+% to +1000.
%
%
%\subsection{Miscellaneous Options}\label{sub:options-misc}
@@ -877,11 +983,13 @@
% -- in the latter case, the \opt{DVIoutput} option is redundant.
%
% When generating <DVI> files, font expansion has to be enabled explicitly.
-% \emph{Automatic} font expansion will not work because dvips (resp. the <DVI>
-% viewer) is not able to generate the expanded fonts on the fly.
+% Neither letterspacing nor \emph{automatic} font expansion will work because
+% the postprocessing drivers (|dvips|, |dvipdfm|, etc.) resp. the <DVI> viewer
+% are not able to generate the fonts on the fly.
%
%\changes{v2.0}{2006/11/28}{add remark about `\opt{draft}' option disabling \microtype\
-% (noted by \contributor Michalis Miatidis <miatidis\at informatik.rwth-aachen.de>)}
+% (noted by \contributor Michalis Miatidis <miatidis\at informatik.rwth-aachen.de>)}
+% ^^A private mail, 26/11/2006
%\bigskip
%\Describe{Option}{draft}{true,!false}
%\DescribeOption{final}
@@ -932,8 +1040,7 @@
%\fi
%
%
-%\markright{} ^^A layout
-%\subsection{Changing Options Later}\label{sec:options-cmd}
+%\subsection{Changing Options Later}\label{sub:options-cmd}
%
%\Describe{Macro}{\microtypesetup}{key\,|=|\,value list}
% Inside the preamble, this command accepts all package options described above
@@ -1027,10 +1134,8 @@
% For instance, if you wanted to have the roman family in all sizes protruded,
% but only the normal sized, possibly italic, typewriter font (in contrast to,
% say, the small one), this is how you could declare the set:
-%\pagebreak ^^A layout
%\begin{verbatim}[deletekeywords={[1]{protrusion}}]
-%\DeclareMicrotypeSet
-% [ protrusion ]
+%\DeclareMicrotypeSet[protrusion]
% { myset }
% { encoding = T1,
% family = rm*,
@@ -1041,7 +1146,7 @@
% the |font| key. Size selection commands are possible, too, however, ranges are
% not allowed.
%
-%\begin{table}\small
+%\begin{table}\microtypesetup{protrusion=false}\small
%\caption{Predefined font sets}\label{tab:predefined-font-sets}
%\begin{tabular}{@{}L{65pt}L{80pt}*3{L{41pt}}L{67pt}@{}}
%\toprule
@@ -1083,12 +1188,19 @@
% & sc
% & -- \\
%\cmidrule(r){1-1}
-% |footnotesize|\linebreak(|scriptsize|)
+% |footnotesize|
% & Text encodings, <TS1>
% & --
% & --
% & --
-% & |-\small|\linebreak(|-\footnotesize|) \\
+% & |-\small|\\
+%\cmidrule(r){1-1}
+% |scriptsize|
+% & Text encodings, <TS1>
+% & --
+% & --
+% & --
+% & |-\footnotesize| \\
%\cmidrule(r){1-1}
% |normalfont|
% & |\encoding*|
@@ -1121,10 +1233,11 @@
%
%\bigskip
%\Describe{Macro}{\DeclareMicrotypeSetDefault}{?features,set name}
-% If the package has been loaded without activating any font sets, the sets
+% If a feature is enabled but no font set has been chosen explicitly, the sets
% declared by this command will be activated. By default, the `|alltext|' font
% set will be used for character protrusion and additional kerning, the
-% `|basictext|' set for font expansion and interword spacing.
+% `|basictext|' set for font expansion and interword spacing, and the
+% `|smallcaps|' set for tracking.
%
%\bigskip\noindent
% These commands may only be used in the preamble or in the main configuration
@@ -1141,7 +1254,7 @@
% straight-forward methods of customising these finer aspects of
% micro-typography.
%
-% All fine-tuning commands follow basically the same syntax: They all take
+% All fine-tuning commands follow basically the same syntax: they all take
% three arguments; the first one is optional and may contain additional
% options; in the second argument, you specify the set of fonts to which the
% settings should apply; the third argument contains the actual settings.
@@ -1183,7 +1296,7 @@
%\paragraph{The protrusion settings}
% consist of \meta{character}\,|=|\,\meta{protrusion factors} pairs.
%
-% The \meta{characters} may be specified either as a single character (`|A|'),
+% The characters may be specified either as a single character (`|A|'),
% as a text symbol command (`\cmd\textquoteleft'), or as a slot number: three
% digits for decimal notation, prefixed with~|"| for hexadecimal, with~|'| for
% octal (\eg, the `fl' ligature in <T1> encoding:~|029|, |"1D|, |'35|).
@@ -1194,7 +1307,7 @@
% characters that should inherit protrusion or expansion factors (see
% section~\ref{sub:inherit}).
%
-% The \meta{protrusion factors} designate the amount that a character should be
+% The protrusion factors designate the amount that a character should be
% protruded into the left margin (first value) respectively into the right
% margin (second value). By default, the values are relative to the character
% widths, so that a value of 1000 means that the character should be shifted
@@ -1270,7 +1383,6 @@
%
%\paragraph{The expansion settings}
% consist of \meta{character}\,|=|\,\meta{expansion factor} pairs.
-%
% You may specify one number for each character, which determines the amount
% that a character may be expanded. The numbers denominate thousandths of the
% full expansion.
@@ -1288,10 +1400,11 @@
% Analogous to \cs{SetProtrusion}, the optional argument may be used to
% assign a name to the list, to load another list, to preset all
% expansion factors, to set the input encoding, or to determine the
-% context of the list.
+% context of the list (contexts are only allowed if you are using at least
+% \pdftex\ version 1.40.4).
%\changes{v1.8}{2005/04/12}{add example of how to get rid of a widow
% (suggested by \contributor Adam Kucharczyk <adamk\at ijp-pan.krakow.pl>)}
-% ^^A private mail, 09/04/2004
+% ^^A private mail, 09/04/2005
% \item[\key{auto}, \key{stretch}, \key{shrink}, \key{step}]
% These keys can be used to override the global settings from the package
% options (see section~\ref{sub:options-expansion}). If you don't specify
@@ -1300,42 +1413,34 @@
%
% As a practical example, suppose you have a paragraph containing a widow
% that could easily be avoided by shrinking the font a little bit more.
-% You could take advantage of the |stretch| and |shrink| options to allow
-% for more expansion in this particular paragraph. There is one problem
-% that has to be worked around, however: \pdftex\ prohibits the use of
-% the same font with different expansion parameters. If you do not want
-% to create a clone of the font setup (this would require duplicating the
-% \file{tfm}/\file{vf} files under a new name, and writing new \file{fd}
-% files and \file{map} entries), you could exploit a dirty trick and load
-% a minimally larger font for the paragraph in question. E.\,g., for a
-% document typeset in 10pt:
+% In conjunction with the |context| option (see section~\ref{sec:context}
+% for further details), you could thus allow for more expansion in this
+% particular paragraph:
%\begin{verbatim}[gobble=2]
% \SetExpansion
-% [ stretch = 30,
+% [ context = sloppy,
+% stretch = 30,
% shrink = 60,
-% step = 5 ]
-% { encoding = *,
-% size = 10.001 }
+% step = 5 ]
+% { encoding = {OT1,T1,TS1} }
% { }
-% \newcommand{\expandpar}[1]{{%"^^A
-% \footnote{Note that the \cmd\expandpar\ command can only be applied to ^^A
-% complete paragraphs. If you are using Computer Modern Roman, you ^^A
-% have to load the \pkg{fix-cm} package to be able to select fonts ^^A
-% in arbitrary sizes. Finally, the reason I suggest to use a larger ^^A
-% font, and not a smaller one, is to prevent a different design size ^^A
-% being selected.}"
-% \fontsize{10.001}{\baselineskip}\selectfont #1\par}}
-% % ...
-% \expandpar{This paragraph contains an `unnecessary' widow.}
+% % ... END PREAMBLE
+% {\microtypecontext{expansion=sloppy}%
+% This paragraph contains an `unnecessary' widow.}
%\end{verbatim}
+% This method of employing contexts to temporarily apply different
+% expansion parameters only works with \pdftex\ version 1.40.4 or later.
+% For older versions, a dirty trick is laid out in
+% section~\ref{ssec:font-setup} on page~\pageref{exp-hack}. Also note
+% that \pdftex\ prohibits the use of fonts with different expansion
+% limits or steps (even of different fonts) within one paragraph, hence
+% the sloppy context has to be applied to complete paragraphs.
% \item[\key{factor}]
% This option provides a different method to alter expansion settings for
-% certain fonts, working around another restriction of \pdftex: it does
-% not allow different expansion limits or steps (even of different fonts)
-% within one paragraph. The |factor| option influences the expansion
-% factors of all characters (in contrast to the overall stretchability)
-% of the font. For instance, if you want the italic shape to be expanded
-% less, you could declare:
+% certain fonts, working around the restriction just mentioned. The
+% |factor| option influences the expansion factors of all characters (in
+% contrast to the overall stretchability) of the font. For instance, if
+% you want the italic shape to be expanded less, you could declare:
%\begin{verbatim}
%\SetExpansion
% [ factor = 500 ]
@@ -1363,60 +1468,111 @@
% or shrunk by the same amount, you would have to declare an empty list for
% these fonts.
%
-%\ifcharter\else\pagebreak\fi ^^A layout
+%
%\subsection{Tracking}\label{sub:tracking}
%\Describe{Macro}{\SetTracking}{?options,set of fonts,tracking amount}
% An important typographic technique -- which was missing in \TeX\ for a long
% time -- is tracking, \ie, the uniform addition or subtraction of letter space
% to/from all the characters in a font. For example, it is good typographic
-% practice to slightly space out pieces of text set in all capitals or small
-% capitals (as in this document), and to increase letter spacing of smaller and
-% decrease that of larger type.\footnote{
-% For full-featured fonts like Computer Modern, this is usually not
+% practice to slightly space out text set in all capitals or small capitals (as
+% in this document). Legibility may also be improved by minimally increasing
+% the tracking of smaller and decreasing that of larger type.\footnote{
+% With full-featured fonts like Computer Modern, this is usually not
% necessary, though, since they come in optical sizes, and the tracking of
% the small-capitals font is already adjusted.}
-% With \pdftex\ 1.40 and \microtype, this is now possible, and moreover, easy
-% to achieve. For instance, to increase the letter spacing of all fonts smaller
-% than \cmd\small, and also space out the small-caps font, you could specify
-% something like the following:
+% The \cs{SetTracking} command allows to specify the tracking amount for
+% different fonts or font sets. It will also be evaluated by the \cs{textls}
+% command, which may be used for letterspacing shorter pieces of text (see
+% section~\ref{sec:lettersp}).
+%
+%\paragraph{The tracking amount}
+% is specified in thousandths of 1em (or the given unit); negative values are
+% allowed, too.
+%
+%\paragraph{Options:}
+%\begin{options}
+% \item[\key{name}, \key{unit}, \key{context}]
+% These options serve the same functions as in the previous configuration
+% commands. The unit may be any dimension, default is 1em.
+% \item[\key{spacing}]
+% When the inter-\emph{character} spacing gets altered, the inter-\emph{word}
+% spacing probably also needs to be adjusted. This option expects three
+% numbers for interword space, stretch and shrink respectively, which are
+% given in thousandths of 1em (or of the current \texttt{unit}). If a
+% value is followed by an asterisk, it denotes thousandths of the
+% respective font dimension which will be added to it. For instance, with
+%\begin{verbatim}
+%\SetTracking[ spacing = {25*,166,} ]{ encoding = *, shape = sc }{ 25 }
+%\end{verbatim}
+% the interword space will be increased by 2.5\%, the stretch amount will
+% be set to 0.166em, and the shrink amount will not be modified. If you
+% don't specify the \texttt{spacing} option, the interword space will be
+% scaled by the current letterspace amount (as in the above example),
+% stretch and shrink will not be changed.
+% \item[\key{outer spacing}]
+% If an interword space precedes or follows letterspaced text, it will by
+% default be equal to that within the text. With this option, which
+% accepts the same values as \texttt{spacing}, it may be adjusted
+% independently.
+%\enlargethispage\baselineskip ^^A layout
+% \item[\key{no ligatures}]
+% As far as \pdftex\ is concerned, ligatures in letterspaced fonts would
+% be constructed as usual, which may be advisable when changing the
+% tracking by only a small amount. For larger letterspacing amounts, on
+% the other hand, the normal letter space within ligatures would have
+% displeasing \textls[150]{e\lslig{ff}ects}.
+% This key expects a comma-separated list of characters for which
+% ligatures should be disabled; the character that begins a ligature must
+% be specified.
+% If the key is given without a value, \emph{all} ligatures of the font
+% will be disabled. This is not recommended, however, since it also
+% entails that kerning will be switched off.\footnote{
+% The inseparable connexion of ligatures and kerns is a limitation of
+% \TeX\ that will not be lifted before the advent of \luatex.}
+% The default settings disable ligatures for the character `|f|' only,
+% \ie, `ff', `fi', ffi', etc.\footnote{
+% With \pdftex\ versions older than 1.40.4, \emph{all} ligatures, and
+% hence all kerning, will be disabled. It is recommended to use at least
+% version 1.40.4.}
+% In exceptional situations, you can manually break up a ligature by
+% inserting `|{\kern0pt}|' resp. \pkg{babel}'s \verb="|=
+% shortcut, or protect it by enclosing it in \cs{lslig} (see
+% section~\ref{sec:lettersp}).
+%\end{options}
+%
+%\medskip\noindent
+% As an example, suppose you want to space out all small capitals by 50/1000em
+% (0.025em on each side of each character), fonts smaller than \cmd\small\ by
+% 0.02em, and to decrease the tracking of large type by 0.02em. You can achieve
+% this with the following settings:
+%^^A there's a \nobreakspace ahead!
%\begin{verbatim}
%\usepackage[tracking=true]{microtype}
%\DeclareMicrotypeSet*[tracking]{my}
% { encoding = *,
-% size = -small,
+% size = {-small,Large-},
% font = */*/*/sc/* }
-%\SetTracking{ encoding = *, shape = sc }{ 50 }
-%\SetTracking{ encoding = *, size = footnotesize }{ 70 }
-%\SetTracking{ encoding = *, size = -footnotesize }{ 100 }
+%\SetTracking[ no ligatures = f ]{ encoding = *, shape = sc}{ 50 }
+%\SetTracking{ encoding = *, size = -small }{ 20 }
+%\SetTracking{ encoding = *, size = Large- }{ -20 }
%\end{verbatim}
-% In the above example, the small-caps font would be spaced out by 50/1000em
-% (0.025em on each side of each character), fonts in \cmd\footnotesize\ would
-% be spaced out by 0.07em, and even smaller type by 0.1em. The amount of letter
-% spacing is given in thousandth of 1em. The interword space will be scaled
-% accordingly.
-%
-% Letterspaced fonts for which you do not specify an amount will be spaced out
-% by the default of 0.1em (adjustable with the package option \opt{letterspace},
-% see section~\ref{sub:options-misc}). Suppose your editor wants you to shorten
-% your 1000 pages chef-d'\oe uvre by 20 pages, you could load \microtype\ with
-% (fingers crossed):
+%
+%\medskip\noindent
+% Letterspaced fonts for which settings don't exist will be spaced out by the
+% default of 0.1em (adjustable with the package option \opt{letterspace}, see
+% section~\ref{sub:options-misc}). Suppose your editor wants you to shorten
+% your 1000 pages chef-d'\oe uvre by a handful of pages, you could load
+% \microtype\ with (fingers crossed):
%\begin{verbatim}
%\usepackage[tracking=alltext,letterspace=-40]{microtype}
%\end{verbatim}
%
-%\paragraph{Options:}
-%\begin{options}
-% \item[\key{name}, \key{unit}, \key{context}]
-% These options serve the same function as in the previous configuration
-% commands. The unit may be any dimension, default is 1em.
-%\end{options}
-%
%
%\subsection{Interword Spacing}\label{sub:interword-spacing}
%
%\Describe{Macro}{\SetExtraSpacing}{?options,set of fonts,spacing settings}
% This command allows you to fine tune the interword spacing (also known as
-% glue). A preliminary remark on what a `space' is may be in order: Between two
+% glue). A preliminary remark on what a `space' is may be in order: between two
% words, \TeX\ will insert a so called glue, which is characterised by three
% parameters -- the normal distance between two words, the maximum amount of
% space that may be added to it, and the maximum amount that may be subtracted.
@@ -1441,15 +1597,14 @@
%
%\paragraph{Options:}
%\begin{options}
-% \item[\key{name}, \key{load}, \key{factor}, \key{inputenc}, \key{context}]
+% \item[\key{name}, \key{load}, \key{factor}, \key{preset}, \key{inputenc}, \key{context}]
% These options serve the same function as in the previous configuration
% commands.
-% \item[\key{unit}] Like in \cs{SetProtrusion}, you can specify the unit by which
-% the specified numbers are measured. Possible values are: |character|, a
-% \meta{dimension} and, additionally, |space|. The latter will measure the
-% values in thousandths of the respective space dimension set by the font.
-% By default, the unit is measured by the space dimensions. For example,
-% with these settings:
+% \item[\key{unit}] You can specify the unit by which the specified numbers are
+% measured. Possible values are: |character|, a \meta{dimension} and,
+% additionally, |space|. The latter will measure the values in thousandths
+% of the respective space dimension set by the font. By default, the unit
+% is measured by the space dimensions. For example, with these settings:
%\begin{verbatim}
%\SetExtraSpacing
% [ unit = space ] % default
@@ -1463,9 +1618,6 @@
% and the maximum shrink amount of the interword space (\fontdim3
% and 4). As another example, setting all three value to |-1000|
% would completely cancel a space after the respective character.
-% \item[\key{preset}] Preset all characters to the specified three values,
-% possibly scaled by a |factor|, and measured by a given |unit| (except
-% |character|).
%\end{options}
%
%
@@ -1479,10 +1631,11 @@
% appears in the text, the specified kerning will be inserted, regardless of
% which character precedes resp. follows it.
%
-% I should not neglect to mention a limitation of this additional kerning: if a
-% word \emph{immediately follows} such a kern (\ie, not separated by a space),
-% hyphenation will be inhibited, unless you insert the breakpoints with |\-|
-% manually. This restriction of \pdftex\ will hopefully be lifted one day.
+% I should not neglect to mention a limitation of this additional kerning:
+% words \emph{immediately following} such a kern (not separated by a space)
+% will not be hyphenated, unless you insert the breakpoints manually, \eg, for
+% kerning after the apostrophe, `|l'apos\-trophe|'. This restriction of \pdftex\
+% will hopefully be lifted soon.
%
%\paragraph{The kerning settings}
% are specified as pairs of \meta{character}\,|=|\,\meta{kerning values}, where
@@ -1535,19 +1688,16 @@
% extend this file with custom settings (or load a different configuration file
% with the `\opt{config}' option, see section~\ref{sub:options-misc}).
%
-% If you are embarking on creating new expansion and protrusion settings for a
-% font family, you should put them into a separate file, whose name must be:
-% `|mt-|\meta{font family}|.cfg|' (\eg, `\file{mt-pad.cfg}'), and may contain
-% all commands described in the current section~\ref{sec:fine-tuning}. These
-% files will be loaded automatically if you are actually using the respective
-% fonts. If the font name consists of four characters, the package will also
-% try to find the file for the base font family by removing the suffix denoting
-% the sub-family, so that you may put settings for the fonts |padx| (expert
-% set), |padj| (oldstyle numerals) and |pad| (plain) into one and the same
-% file.
+% If you are embarking on creating new settings for a font family, you should
+% put them into a separate file, whose name must be: `|mt-|\meta{font
+% family}|.cfg|' (\eg, `\file{mt-cmr.cfg}'), and may contain all commands
+% described in the current section~\ref{sec:fine-tuning}. These files will be
+% loaded automatically if you are actually using the respective fonts.
+% This package ships with configuration files for a number of font families.
+% Table~\ref{tab:fonts} lists them all.
%
-%\changes{v1.6a}{2005/02/02}{add table of fonts with tailored protrusion settings}
%\begin{table}[t]\small
+%\changes{v1.6a}{2005/02/02}{add table of fonts with tailored protrusion settings}
%\caption{Fonts with tailored protrusion settings}\label{tab:fonts}
%\begin{minipage}{\textwidth}
%\def\arraystretch{1.2}
@@ -1569,7 +1719,8 @@
% \pkg{eco} (|cmor|), \pkg{hfoldsty} (|hfor|)}
% & <OT1>, <OT4>, <T1>, <T5>, <LY1>, <TS1>
% & n, it, sl, sc \\
-% Bitstream Charter (|bch|)\footnote{Alias: \pkg{mathdesign}/Charter (|mdbch|)}
+% Bitstream Charter (|bch|)\footnote{Aliases: \pkg{mathdesign}/Charter (|mdbch|),
+% MicroPress's \pkg{chmath} (|chr|)}
% & <OT1>, <T1>, <T5>, <LY1>, <TS1>
% & n, it, (sl)\footnote{Settings inherited from italic shape\label{fn:it-sl}}, sc \\
% Adobe Garamond (|pad|, |padx|, |padj|)
@@ -1578,15 +1729,19 @@
% <URW> Garamond (|ugm|)\footnote{Alias: \pkg{mathdesign}/<URW> Garamond (|mdugm|)}
% & <OT1>, <T1>, <TS1>
% & n, it\\
-% Adobe Minion (|pmnx|, |pmnj|)
+% Bitstream Letter Gothic (|blg|)\footnote{Alias: \pkg{ulgothic} (|ulg|)}
+% & <OT1>, <T1>, <TS1>
+% & n, it \\
+% Adobe Minion (|pmnx|, |pmnj|)\footnote{By courtesy of Harald Harders (\mailto{h.harders@tu-bs.de})}
% & <OT1>, <T1>, <LY1>, <TS1>
% & n, it, (sl)\fnref{fn:it-sl}, sc, si \\
% Palatino (|ppl|, |pplx|, |pplj|)\footnote{Aliases: \pkg{pxfonts} (|pxr|),
-% \pkg{qfonts}/QuasiPalatino (|qpl|)}
+% \pkg{qfonts}/QuasiPalatino, \TeX\ Gyre Pagella (|qpl|),
+% <FPL> Neu (|fp9x|, |fp9j|)}
% & <OT1>, <OT4>, <T1>, <LY1>, (<TS1>)\fnref{fn:incmpl}
% & n, it, (sl)\fnref{fn:it-sl}, sc \\
% Times (|ptm|, |ptmx|, |ptmj|)\footnote{Aliases: \pkg{txfonts} (|txr|),
-% \pkg{qfonts}/QuasiTimes (|qtm|)}
+% \pkg{qfonts}/QuasiTimes, \TeX\ Gyre Termes (|qtm|)}
% & <OT1>, <OT4>, <T1>, <LY1>, <QX>, (<TS1>)\fnref{fn:incmpl}
% & n, it, (sl)\fnref{fn:it-sl}, sc \\
% Computer Modern math (|cmsy|, |cmm|)
@@ -1606,21 +1761,28 @@
%\end{minipage}
%\end{table}
%
-% This package ships with configuration files for the font families Computer
-% Modern Roman, Palatino, the inescapable Times, <URW> Garamond, Adobe Garamond
-% and Minion\footnote{
-% By courtesy of Harald Harders (\mailto{h.harders@tu-bs.de}).},
-% for Bitstream Charter, the <AMS> symbols and Euler fonts and Euro symbol
-% fonts (Adobe, <ITC> and \pkg{marvosym}). Table~\ref{tab:fonts} lists them
-% all.
+%\bigskip
+%\Describe{Macro}{\DeclareMicrotypeVariants}{list of suffixes}
+%\DescribeMacro{\DeclareMicrotypeVariants*}
+% On its search for a configuration file, the package will also try to remove
+% from the font name a suffix of one or more letters that denotes a `variant'
+% of the base font (cf.~\cite{fontname}). This allows it to put settings for,
+% \eg, the fonts |padx| (expert set), |padj| (oldstyle numerals) and |pad|
+% (plain) into one and the same file \file{mt-pad.cfg}.
+% This command expects a comma-separated list of variant suffixes. The starred
+% version appends the suffix(es) to the existing list. The default declaration
+% is:
+%\begin{verbatim}
+%\DeclareMicrotypeVariants{x,j,w,a,d,0,1}
+%\end{verbatim}
%
%\bigskip
%\Describe{Macro}{\DeclareMicrotypeAlias}{font name,alias font}
-% You may use this command for fonts that are very similar, or actually the same
-% (for instance if you did not stick to the Berry naming scheme when installing
-% the font). An example would be the Latin Modern fonts which are clones of the
-% Computer Modern fonts, so that it is not necessary to create new settings for
-% them -- you could say:
+% This command may be used for fonts that are very similar, or actually the
+% same (for instance if you did not stick to the Berry naming scheme when
+% installing a font). An example would be the Latin Modern fonts which are
+% clones of Computer Modern, so that it is not necessary to create new settings
+% for them -- you could say:
%\begin{verbatim}
%\DeclareMicrotypeAlias{lmr}{cmr}
%\end{verbatim}
@@ -1628,7 +1790,6 @@
% not find settings for it, also try the font |cmr|. In fact, you will find
% this very line, along with some others, in the default configuration file.
%
-%\ifcharter\else\pagebreak\fi ^^A layout
%\bigskip
%\Describe{Macro}{\LoadMicrotypeFile}{font name}
% In rare cases, it might be necessary to load a font configuration file
@@ -1652,27 +1813,33 @@
% This command may be used anywhere in the document (also in the preamble) to
% change the micro-typographic context. To each feature (\key{protrusion},
% \key{expansion}, \key{tracking}, \key{spacing} and \key{kerning}), one
-% context may be assigned. Consequently, only settings which have been
-% specified with the corresponding `|context|' keyword will be applied.
+% context may be assigned. Consequently, only settings with the corresponding
+% `|context|' keyword will be applied.
+%
+%\bigskip
+%\Describe{Macro}{\textmicrotypecontext}{context assignments,general text}
+% The alternative command \cs{textmicrotypecontext} sets the context(s) for the
+% text given in the second argument.
%
%\changes{v1.9c}{2006/01/25}{add example of how to increase protrusion of footnote markers
% (suggested by \contributor Georg Verweyen <verweyen\at gmail.com>)}
% ^^A private mail, 25/01/2006
+%\bigskip\noindent
% Suppose you want the footnote markers in the text to be protruded by a larger
% amount. You could define settings for the numbers:
%\begin{verbatim}
%\SetProtrusion
-% [ context = footnotes ]
+% [ context = footnote ]
% { font = */*/*/*/scriptsize } % adapt if necessary
% { 1 = { ,650}, 2 = { ,400}, 3 = { ,400}, 4 = { ,400}, 5 = { ,400},
% 6 = { ,400}, 7 = { ,500}, 8 = { ,400}, 9 = { ,400}, 0 = { ,400} }
%\end{verbatim}
-% and have \microtype's context changed by the footnote marker command. This
-% command differs among the various classes, here are some examples: for the
-% base \LaTeX\ classes, \eg, \pkg{article}:
+% and have the context changed in the footnote marker command. This command
+% differs among the various classes; for the base classes, \eg, \pkg{article},
+% it would be:
%\begin{verbatim}
%\newcommand*\new@makefnmark{\hbox{\@textsuperscript{\normalfont
-% \microtypecontext{protrusion=footnotes}\@thefnmark}}}
+% \microtypecontext{protrusion=footnote}\@thefnmark}}}
%\renewcommand*\@footnotemark{%
% \leavevmode \ifhmode\edef\@x@sf{\the\spacefactor}\nobreak\fi
% \new@makefnmark \ifhmode\spacefactor\@x@sf\fi \relax}
@@ -1681,11 +1848,11 @@
% auto-detection of multiple footnotes, which prevents protrusion:
%\begin{verbatim}
%\renewcommand*\@makefnmark{\hbox{\@textsuperscript{\normalfont
-% \microtypecontext{protrusion=footnotes}\@thefnmark}}}
+% \microtypecontext{protrusion=footnote}\@thefnmark}}}
%\let\m@mmf@prepare\relax
%\let\m@mmf@check\relax
%\end{verbatim}
-% For other classes, the command would have to be changed in a similar way.
+% ^^A For other classes, the command would have to be changed in a similar way.
%
%\bigskip\noindent
% Another possibility would be to employ contexts for a language-dependent
@@ -1695,9 +1862,9 @@
%\end{verbatim}
% to the preamble. This would have the effect that kerning settings for the
% French context would be applied to the document. Should parts of the document
-% be in English, you could insert
+% be in English, you could write:
%\begin{verbatim}
-%\microtypecontext{kerning=}
+%\textmicrotypecontext{kerning=}{English text!}
%\end{verbatim}
% to reset the context, so that the punctuation characters in these parts will
% not receive any extra kerning.
@@ -1727,7 +1894,7 @@
% will be reset.
%
%
-%\section{\textls*[150]{Letterspacing}\, revisited}\label{sec:lettersp}
+%\section{Letterspacing revisited}\label{sec:lettersp}
%
%\Describe{Macro}{\textls}{?amount,general text}
%\DescribeMacro{\textls*}
@@ -1741,43 +1908,61 @@
% should probably only letterspace small-capitals or all-capitals. Another
% just cause may be emphasis in texts typeset in Fraktur fonts.}
% For such ad-hoc letterspacing, \microtype\ introduces two commands that can
-% be used in the same way as \LaTeX's text commands: \cs{textls} expects the
-% text in the mandatory argument, while \cs{lsstyle} will switch on
-% letterspacing for all subsequent fonts until the end of the current group.
-% The starred version of \cs{textls} does not add any extra space before or
-% after the text, which may be useful, \eg, for section titles.
-% By default, each character will be spaced out by 100/1000em (0.05em on each
-% side); this amount may be altered in the optional argument to \cs{textls},
-% using the \cs{SetTracking} command, or globally with the \opt{letterspace}
-% package option (see section~\ref{sub:options-misc}).
-%
-%\ifcharter\else\pagebreak\fi ^^A layout
+% be used in the same way as \LaTeX's text commands (independently of whether
+% the |tracking| option is enabled): \cs{textls} expects the text in the
+% mandatory argument, while \cs{lsstyle} will switch on letterspacing for all
+% subsequent fonts until the end of the current group. The starred version of
+% \cs{textls} does not add any extra space before or after the text, which may
+% be useful, \eg, for section titles. By default, each character will be spaced
+% out by 100/1000em (0.05em on each side); this amount may be altered in the
+% optional argument to \cs{textls}, using the \cs{SetTracking} command, or
+% globally with the \opt{letterspace} package option, with decreasing
+% significance in this order.
+%
%\bigskip
%\Describe{Macro}{\lslig}{ligature}
-% One side-effect of letterspacing is that ligatures will be disabled. While
-% this is usually typographically correct, it is not in the case of Fraktur
-% fonts, where the ligatures `ch', `ck', `tz' and `sz' (\ss) should not be
-% broken up. You can protect ligatures (including `|s:|', `|"a|', `|*a|' etc.)
-% with the \cs{lslig} command:
+% Since the commands \cs{textls} and \cs{lsstyle} will also evaluate the
+% `\texttt{no ligatures}' key for the respective font, you do not need to worry
+% about protecting or breaking ligatures with most fonts. However, in certain
+% situations, there may be a conflict of ligatures beginning with the same
+% letter, where some of them should be inhibited, while others should not. When
+% typesetting text in Fraktur, for example, the ligatures `ch', `ck', `tz' and
+% `sz'~(`\textfrak{sz}') should never be broken up; you also usually see the
+% `st'~(`\textfrak{st}') ligature in letterspaced text. Furthermore, at least
+% the \pkg{yfonts} package realises the short~s~(`\textfrak{s:}') as the
+% ligature~`|s:|'. On the other hand, the `ct' ligature and the other `long~s'
+% ligatures often found in Fraktur fonts should be suppressed. There are two
+% ways to solve this problem: either don't disable the `|s|' and/or `|c|'
+% ligatures and break those that need to be broken up by inserting
+% `|{\kern0pt}|' or \pkg{babel}'s \verb="|= shortcut; or disable them and
+% protect those ligatures that need to be protected by enclosing them in the
+% \cs{lslig} command. So, the following two solutions have the same result
+% (namely, `\textfrak{\lsstyle Aus:s{\kern0pt}ichts:los{\kern0pt}igkeit}').
+%
+%\begin{verbatim}[morekeywords={[0]{\kern}}]
+%\SetTracking[no ligatures={f}]{encoding = LY, family = yfrak}{}
+%\textfrak{\lsstyle Aus:s{\kern0pt}ichts:los{\kern0pt}igkeit}
+%\end{verbatim}
%\begin{verbatim}
-%\textfrak{\lsstyle S\lslig{ch}mu\lslig{tz}fle\lslig{ck}} "\% \normalsize^^A
-%\textfrak{\lsstyle S\lslig{ch}mu\lslig{tz}fle\lslig{ck}} "
+%\SetTracking[no ligatures={f,s,c}]{encoding = LY, family = yfrak}{}
+%\textfrak{\lsstyle Au\lslig{s:}si\lslig{ch}t\lslig{s:}losigkeit}
%\end{verbatim}
%
%\bigskip\noindent
%\DescribePackage{letterspace}
-% These three commands (plus the \opt{letterspace} option) are also available
-% with the \pkg{letterspace} package, which is in fact a much stripped-down
-% version of \microtype, omitting support for all the other extensions. If you
-% find that you don't need \microtype's specialties and it is only slowing down
-% the compilation, you should use the \pkg{letterspace} package instead (which
-% won't work together with \microtype; it does not contain anything that
-% \microtype\ doesn't).
+% These three commands (plus the \opt{letterspace} option, described in
+% section~\ref{sub:option-tracking}) are also available with the
+% \pkg{letterspace} package, which is in fact a much stripped-down version of
+% \microtype, omitting support for all the other extensions (also omitting the
+% possibilities of the \cs{SetTracking} command -- all `|f|' ligatures will be
+% disabled). If you prefer to forgo \microtype's specialties, you may load the
+% \pkg{letterspace} package instead. Both packages should not be used at the
+% same time.
%
%
%\section{Disabling Ligatures}\label{sec:disable-ligatures}
%
-%\Describe{Macro}{\DisableLigatures}{set of fonts}
+%\Describe{Macro}{\DisableLigatures}{?characters,set of fonts}
% While completely disabling all ligatures of a font (which will also switch
% off kerning for this font), purposely \textit{lowers} the micro-typographic
% quality instead of raising it, it is especially useful for typewriter fonts,
@@ -1788,7 +1973,15 @@
%\begin{verbatim}
%\DisableLigatures{encoding = T1, family = tt* }
%\end{verbatim}
-% This command may only be used in the preamble.
+% It is also possible to disable selected ligatures only. The optional argument
+% may contain a comma-separated list of characters for which the ligature
+% mechanism should be inhibited:
+%\begin{verbatim}
+%\DisableLigatures[?,!]{encoding = T1} % $\ifx\tagcode\undefined\else ^^A
+% \normalfont\color{thegrey}inhibit ?` !`, but not fi -- >> etc.\fi$
+%\end{verbatim}
+% The character that begins the ligature(s) is what matters. This command may
+% only be used in the preamble, and only once.
%
%
%\section{Hints and Caveats}\label{sec:caveats}
@@ -1815,16 +2008,16 @@
%
%\changes{v2.0}{2006/12/13}{qualify hint about web documents with regard to older \pdftex\ versions}
%\paragraph{Don't use font expansion for web documents (with older \pdftex\ versions).}
-% With \pdftex\ older than 1.40, each expanded instance of the font will be
-% embedded in the <PDF> file, hence the file size may increase by quite a large
-% factor (depending on expansion limits and step). Therefore, courtesy and
-% thriftiness of bandwidth command it not to enable font expansion when
+% With \pdftex\ versions older than 1.40, each expanded instance of the font
+% will be embedded in the <PDF> file, hence the file size may increase by quite
+% a large factor (depending on expansion limits and step). Therefore, courtesy
+% and thriftiness of bandwidth command it not to enable font expansion when
% creating files to be distributed electronically. With \pdftex\ 1.40, which
% uses a different technique of expansion, the file size increase can be
% neglected.
%
%\changes{v1.9e}{2006/07/10}{add hint about unknown encodings}
-%\paragraph{Settings for Cyrillic/Greek/Thai etc. encodings are currently not included.}
+%\paragraph{Settings for Cyrillic/Greek/Thai etc. encodings are not yet included.}
% The default sets of fonts for which the micro-typographic features will be
% enabled (see table~\ref{tab:predefined-font-sets}) only contain those
% encodings for which configurations exist. Therefore, if you are using any
@@ -1844,10 +2037,23 @@
% you are, for example, writing an English text, your readers would probably be
% rather confused by additional spaces before the punctuation characters.
%
+%\changes{v2.2}{2007/07/06}{add hint about extra <TOC> leader dot
+% (first discovered by \contributor Morten H\o gholm <morten.hoegholm\at latex-project.org>)}
+% ^^A private mail, 2006/08/26
+%\paragraph{You might want to disable protrusion in the Table of Contents.}
+% In unfortunate situations, enabled protrusion might internally alter the line
+% length in the <TOC> and similar lists in such a way that an excess leader dot
+% will fit in. The solution is to temporarily disable protrusion for the <TOC>:
+%\begin{verbatim}
+%\microtypesetup{protrusion=false}
+%\tableofcontents
+%\microtypesetup{protrusion=true}
+%\end{verbatim}
+%
%\changes{v1.9}{2005/07/10}{add hint about \texttt{verbatim} environment}
%\paragraph{You might want to disable protrusion in \texttt{verbatim} environments.}
-% As you know by now, \microtype\ will by default apply character protrusion to
-% all fonts contained in the font set `|alltext|'. This also includes the
+% As you know by now, \microtype\ will by default activate character protrusion
+% for all fonts contained in the font set `|alltext|'. This also includes the
% typewriter font. Although it does make sense to protrude the typewriter font
% if it appears in running text (like, for example, in this manual), this is
% probably not desirable inside the |verbatim| environment. However,
@@ -1869,22 +2075,25 @@
%
%\changes{v1.7}{2005/03/23}{add hint about compatibility}
%\paragraph{Compatibility.}
-% The package should work happily together with all other \LaTeX\ packages
-% (except \pkg{pdfcprot}). However, life isn't perfect, so problems are to be
-% expected. Currently, I am only aware of the following issue:
+% The package is supposed to work happily together with all other \LaTeX\
+% packages (except \pkg{pdfcprot}). However, life isn't perfect, so problems
+% are to be expected. Currently, I am only aware of the following issue:
+%\begin{itemize}
+% \item If you want to use 8-bit characters in the configuration, you have to
+% load the \pkg{inputenc} package first. Unicode input is also supported
+% (when loading \pkg{inputenc} with the |utf8| option, however,
+% \emph{not} with the |utf8x| option resp. the \pkg{ucs} package). If
+% your document includes multiple input encodings, 8-bit characters in
+% the settings will not work reliably unless you specify the |inputenc|
+% key.
+%\end{itemize}
%
-% If you want to use 8-bit characters in the configuration, you have to load
-% the \pkg{inputenc} package first. Unicode input is also supported (when
-% loading \pkg{inputenc} with the |utf8| option, however, \emph{not} with the
-% |utf8x| option resp. the \pkg{ucs} package). If you are using multiple input
-% encodings in your document, 8-bit characters in the settings will not work
-% reliably -- you should then specify the |inputenc| key.
%
%\changes{v1.8}{2005/06/23}{add hint about error messages}
%\paragraph{Possible error messages and how to get rid of them:}
%\begin{itemize}
-%\lstset{belowskip=-\smallskipamount,frame=none,xleftmargin=0pt,backgroundcolor=,
-% basicstyle=\MacroFont\footnotesize}
+%\lstset{deletekeywords={[1]{expansion,auto}},belowskip=-\smallskipamount,frame=none,
+% xleftmargin=0pt,backgroundcolor=,basicstyle=\MacroFont\footnotesize}
%\changes{v1.9a}{2005/11/15}{add explanation for error message in <DVI> mode}
% \item
%\begin{verbatim}
@@ -1896,7 +2105,20 @@
% possible in <DVI> mode, it requires that all instances of the expanded fonts
% exist on your \TeX\ system.
%
-%\changes{v2.0}{2006/12/13}{qualify hints about expansion error messages with regard to older \pdftex\ versions}
+%\changes{v2.2}{2007/06/13}{add hint about error message with \pdftex\ 1.40}
+% \item
+%\begin{verbatim}
+%! pdfTeX error (font expansion): auto expansion is only possible with scalable fonts.
+%\end{verbatim}
+% Automatic font expansion has been improved in \pdftex\ 1.40, in that it now
+% not only works with Type\,1 fonts but also with TrueType, OpenType and even
+% non-embedded fonts. The above error message indicates either that you are
+% trying to apply expansion to a bitmap~(|pk|) font, which is still not
+% possible, or that the font isn't found at all, \eg, because of missing map
+% entries.
+%
+%\changes{v2.0}{2006/12/13}{qualify hints about expansion error messages with
+% regard to older \pdftex\ versions}
% \item
%\begin{verbatim}
%Warning: pdflatex: font ptmr8r cannot be expanded (not an included Type1 font)
@@ -1917,11 +2139,11 @@
%\begin{verbatim}
%Warning: pdflatex (file ecrm1000+20): Font ecrm1000+20 at 1200 not found
%\end{verbatim}
-% Furthermore, \pdftex\ older than 1.40 requires Type\,1 fonts for automatic
-% font expansion. When you receive a message like the above, you are probably
-% trying to apply font expansion to a bitmap or TrueType font. With older
-% \pdftex\ versions, this is only possible if you manually create expanded
-% instances of the fonts.
+% Furthermore, \pdftex\ versions older than 1.40 require Type\,1 fonts for
+% automatic font expansion. When you receive a message like the above, you are
+% probably trying to apply font expansion to a bitmap or TrueType font. With
+% older \pdftex\ versions, this is only possible if you manually create
+% expanded instances of the fonts.
%
%\changes{v2.0}{2006/11/05}{add hint about how to increase \texttt{font\textunderscore max}
% and \texttt{font\textunderscore mem\textunderscore size}}
@@ -1942,10 +2164,11 @@
% Memory parameter `|pdf_mem_size|' too small (\pdftex\ versions older than 1.30).
%
% When applying micro-typographic enhancement to a large document with a lot of
-% fonts, \pdftex\ may be running out of some kind of memory. It may be
+% fonts, \pdftex\ may be running out of some kind of memory. It can be
% increased by setting the respective parameter to a larger value. For
% web2c-based systems, change the settings in \file{texmf.cnf}, for MiK\TeX, in
-% the file \file{miktex.ini} (2.4) resp. \file{pdflatex.ini} (2.5).
+% the file \file{miktex.ini} (2.4 or older) resp. \file{pdflatex.ini} (2.5 or
+% newer).
%
%\changes{v2.0}{2007/01/05}{add hint about warning when tracking \emph{and}
% expansion is applied to a font}
@@ -1953,8 +2176,8 @@
%\begin{verbatim}[deletekeywords={[1]{expansion}}]
%pdfTeX warning (font expansion): font should be expanded before its first use
%\end{verbatim}
-% This warning will occur if tracking \emph{and} expansion is applied to a font.
-% It is harmless and can be ignored.
+% This warning will occur with \pdftex\ versions older than 1.40.4, if tracking
+% \emph{and} expansion is applied to a font. It is harmless and can be ignored.
%\end{itemize}
%
%
@@ -1968,7 +2191,7 @@
% If you have created a configuration file for another font, or if you have any
% suggestions for enhancements in the default configuration files, I~would
% gratefully accept them: \mailtoRS.
-%\iffalse\footnote{^^A ... OK, so nobody has any...
+%\iffalse\footnote{^^A ... OK, so nobody has any ...
% Should you have lots of \pkg{pdfcprot} configuration files lying around,
% I can also provide you with a \TeX\ conversion script. Just ask me.}
%\fi
@@ -2023,50 +2246,62 @@
% \contributor Ralf Stubner <ralf.stubner\at physik.uni-erlangen.de>,
% \contributor Holger Uhr <huhr\at uni-paderborn.de>,
% \contributor Peter Dyballa <Peter_Dyballa\at Web.DE>,
+% \contributor Morten H\o gholm <morten.hoegholm\at latex-project.org>,
% \contributor Steven Bath <steven128\at iname.com>,
% \contributor Daniel Flipo <daniel.flipo\at univ-lille1.fr>,
-% \contributor Michalis Miatidis <miatidis\at informatik.rwth-aachen.de>
+% \contributor Michalis Miatidis <miatidis\at informatik.rwth-aachen.de>,
+% \contributor Sven Naumann <svenau\at gmx.net>,
+% \contributor Ross Hetherington <ross\at heth.eclipse.co.uk>,
+% \contributor Geoff Vallis <gkv\at Princeton.EDU>
% and
-% \contributor Sven Naumann <svenau\at gmx.net>.
+% \contributor Steven~E. Harris <seh\at panix.com>.
%
%
%\begin{thebibliography}{}
% \bibitem[Th\`anh 2000]{ThanhThesis}
-% \thanh, \emph{Micro-typographic extensions to the \TeX\ typesetting system},
+% \thanh, `Micro-typographic extensions to the \TeX\ typesetting system',
% \newblock Diss. Masaryk University Brno 2000,
% \newblock in: \textit{TUGBoat}, vol.~21(2000), no.~4, pp.~317--434.
% \newblock (Online at \url{http://www.tug.org/TUGboat/Articles/tb21-4/tb69thanh.pdf})
%
%\iffalse ^^A obsolete
% \bibitem[Th\`anh 2001]{ThanhTUG}
-% \thanh, \emph{Margin Kerning and Font Expansion with \pdftex},
+% \thanh, `Margin Kerning and Font Expansion with \pdftex',
% \newblock in: \textit{TUGBoat}, vol.~22(2001), no.~3 -- Proceedings of the
% 2001 Annual Meeting, pp.~146--148.
% \newblock (Online at \url{http://www.tug.org/TUGboat/Articles/tb22-3/tb72thanh.pdf})
%\fi
%
%\bibitem[Th\`anh 2004]{ThanhPracTeX}
-% \thanh, \emph{Micro-typographic extensions of \pdftex\ in practice},
+% \thanh, `Micro-typographic extensions of \pdftex\ in practice',
% \newblock in: \textit{TUGBoat}, vol.~25(2004), no.~1 -- Proceedings of the
% Practical \TeX\ 2004 Conference, pp.~35--38.
% \newblock (Online at \url{http://www.tug.org/TUGboat/Articles/tb25-1/thanh.pdf})
%
%\iffalse
% \bibitem[Th\`anh 2005]{ThanhEuroTeX}
-% \thanh, \emph{Experiences with micro-typographic extensions of \pdftex\ in practice},
-% \newblock in: Proceedings of Euro\TeX\ 2005, 15\textsuperscript{th}~Annual
-% Meeting of the European \TeX\ Users, March~7 -- March~11, 2005,
-% Abbaye des Pr\'emontr\'es, Pont-\`a-Mousson, pp.~81--88.
-% \newblock (Online at \url{http://www.dante.de/dante/events/eurotex/papers/TUT07.pdf})
-% ^^A \url{https://www.tug.org/members/TUGboat/tb27-0/thanh.pdf} ^^A is this the same?
+% \thanh, `Experiences with micro-typographic extensions of \pdftex\ in practice',
+% \newblock in: Euro\TeX\ 2005 Proceedings
+% ^^A 15th~Annual Meeting of the European \TeX\ Users,
+% ^^A March~7 -- March~11, 2005, Abbaye des Pr\'emontr\'es, Pont-\`a-Mousson,
+% [=~\textit{TUGBoat}, vol.~27(2006), no.~0],
+% pp.~159--164.
+% \newblock (Online at \url{http://www.tug.org/TUGboat/Articles/tb27-0/thanh.pdf})
+% ^^A = \url{http://www.dante.de/dante/events/eurotex/papers/TUT07.pdf}
%\fi
%
% \bibitem[\pdftex\ manual]{pdftexman}
% \thanh, Sebastian Rahtz, Hans Hagen, Hartmut Henkel, Pawe\l\ Jackowski, Martin Schr\"oder,
% \emph{The \pdftex\ user manual},
-% \newblock 1 January 2007.
+% \newblock 25 January 2007.
% \newblock (Available from <CTAN> at \ctanurl{systems/pdftex/};
% latest version at \url{http://sarovar.org/projects/pdftex/})
+% ^^A or even \url{http://foundry.supelec.fr/scm/?group_id=23}
+%
+% \bibitem[Fontname]{fontname}
+% Karl Berry, \emph{Fontname. Filenames for \TeX\ fonts},
+% \newblock September 2005.
+% \newblock (Available from <CTAN> at \ctanurl{info/fontname/fontname.pdf})
%
% \bibitem[\LaTeXe\ font selection]{fntguide}
% \LaTeX3 Project Team, \emph{\LaTeXe\ font selection},
@@ -2085,24 +2320,21 @@
%\end{thebibliography}
%
%\section{Short History}\label{sec:short-history}
-%\changes{v1.5}{2004/12/11}{add short history (section~\ref{sec:short-history})}
+%\changes{v1.5}{2004/12/11}{add `Short History'}
%
% The comprehensive list of changes can be
% \expandafter\ifx\csname r@sec:changes\endcsname\relax
% obtained by running `\texttt{makeindex \mbox{-s gglo.ist}
-% \mbox{-o microtype.gls} microtype.glo}'\else
+% \mbox{-o microtype.gls} microtype.glo}'\else
% found in appendix~\ref{sec:changes}\fi.
% The following is a list of all changes relevant in the user land; bug and
% compatibility fixes are swept under the rug.
%
%\newenvironment{History}
-% {\list{}
-% {\leftmargin 15pt
-% \itemindent-15pt
-% \labelwidth 22pt
-% \labelsep 0pt
+% {\list\labelitemi
+% {\leftmargin 0pt
% \parsep 0pt
-% \def\makelabel##1{##1\hss}}}
+% \def\makelabel##1{\hss\llap{##1}}}}
% {\endlist}
%\newcommand\Version[2]{
% \VersionDate{#1}{#2}
@@ -2115,7 +2347,26 @@
% \global\expandafter\def\csname MTversiondate#1\endcsname{#2}}
%
%\begin{History}
-%\Version{2.1}{\filedate}
+%\Version{2.2}{\filedate}
+% \item Improvements to tracking/letterspacing: retain kerning (with \pdftex\ 1.40.4);
+% automatically adjust protrusion settings
+% \item New key `\texttt{no ligatures}' for \cs{SetTracking} to disable
+% selected or all ligatures (with \pdftex\ 1.40.4) (see section~\ref{sub:tracking})
+% \item New keys `\texttt{spacing}' and `\texttt{outer spacing}' for
+% \cs{SetTracking} to customise interword spacing (see section~\ref{sub:tracking})
+% \item Possibility to expand a font with different parameters (with \pdftex\ 1.40.4)
+% ^^A ; new option `\opt{copyfonts}'
+% (see section~\ref{sub:expansion})
+% \item New optional argument for \cs{DisableLigatures} to disable selected ligatures only
+% (see section~\ref{sec:disable-ligatures})
+% \item New command \cs{DeclareMicrotypeVariants} to specify variant suffixes
+% (see section~\ref{sub:config-file})
+% \item New command \cs{textmicrotypecontext} as a wrapper for \cs{microtypecontext}
+% (see section~\ref{sec:context})
+% \item Protrusion settings for Bitstream Letter Gothic
+% \item Basic support for \luatex\ (if generated with the |lua| option)
+%
+%\Version{2.1}{2007/01/21}
% \item New command \cs{lslig} to protect ligatures in letterspaced text
% (see section~\ref{sec:lettersp})
%
@@ -2161,7 +2412,7 @@
% change font defaults before loading \microtype, or to put it the other
% way round, \microtype\ may now be loaded at any time
% \item Inside the preamble, \cs{microtypesetup} accepts all package options
-% (see section~\ref{sec:options-cmd})
+% (see section~\ref{sub:options-cmd})
% \item Protrusion settings for <T5> encoded Charter
%
%\Version{1.9}{2005/10/28}
@@ -2232,7 +2483,6 @@
% \item New option `\opt{selected}' to enable selected expansion
% (see sections~\ref{sub:options-expansion} and \ref{sub:expansion});
% default is: |false|
-%\ifcharter\pagebreak\fi ^^A layout
% \item New default for expansion option `\opt{step}': 4 (min(\opt{stretch},\opt{shrink})/5)
% (see section~\ref{sub:options-expansion})
% \item Protrusion settings for Bitstream Charter
@@ -2248,7 +2498,7 @@
% (therefore, no risk of overlooking fonts anymore, and the package may
% be loaded at any time)
% \item \cs{microtypesetup} now sets the correct level of protrusion
-% (see chapter~\ref{sec:options-cmd})
+% (see chapter~\ref{sub:options-cmd})
% \item New option: `\opt{final}'
%
%\VersionDate{1.3}{2004/10/27}
@@ -2293,7 +2543,7 @@
% \let\LPPLparagraph\textit
% \let\LPPLfile\file
% \def\textsc##1{\acronym{\MakeUppercase{##1}}}
-% \lstset{gobble=2,basicstyle=\MacroFont\tiny,aboveskip=\smallskipamount}
+% \lstset{gobble=2,basicstyle=\MacroFont\tiny,commentstyle=,aboveskip=\smallskipamount}
% \let\oldmakeatletter\makeatletter
% \long\def\makeatletter##1\makeatother{\let\makeatletter\oldmakeatletter}
% \MakePercentComment
@@ -2338,53 +2588,60 @@
% \if@tempswa\@newiftrue\else\@newiffalse\fi
%}
%
+%
%\DoNotIndex{\!,\",\',\(,\),\*,\+,\,,\-,\.,\/,\:,\;,\<,\=,\>,\?,\[,\\,\],\`,
% \#,\$,\&,\^,\_,\|,\~,\ ,
-% \advance,\aftergroup,\begingroup,\catcode,\char,\chardef,\csname,\def,\divide,
-% \edef,\else,\endcsname,\endgroup,\endinput,\escapechar,\expandafter,\fi,\gdef,
-% \global,\hbox,\if,\ifcase,\ifcat,\ifdim,\iffalse,\ifhbox,\ifnum,\iftrue,\ifx,
-% \input,\inputlineno,\jobname,\kern,\let,\lowercase,\meaning,\multiply,\newcount,
-% \newdimen,\newif,\newtoks,\noexpand,\number,\or,\relax,\setbox,\space,\string,
-% \the,\uppercase,\wd,\xdef}
-%^^A\DoNotIndex{\font,\fontdimen,\nullfont,\sfcode} ^^A TeX
-%\DoNotIndex{\detokenize,\eTeXversion,\ifcsname,\ifdefined,\numexpr}
-%^^A\DoNotIndex{\fontcharwd,\iffontchar} ^^A e-TeX
-%^^A\DoNotIndex{\(ef,lp,rp,kn(bc,ac),(kn,sh,st)bs)code,\(left,right)marginkern,\pdf*} ^^A pdfTeX
+% \advance,\afterassignment,\aftergroup,\begingroup,\catcode,\char,\chardef,
+% \csname,\def,\divide,\edef,\egroup,\else,\endcsname,\endgroup,\endinput,
+% \escapechar,\expandafter,\fi,\futurelet,\gdef,\global,\hbox,\hskip,\if,
+% \ifcase,\ifcat,\ifdim,\iffalse,\ifhbox,\ifnum,\iftrue,\ifx,\input,\inputlineno,
+% \jobname,\kern,\lastskip,\let,\lowercase,\meaning,\multiply,\newcount,
+% \newdimen,\newif,\newskip,\newtoks,\noexpand,\number,\or,\relax,\setbox,
+% \space,\string,\the,\unkern,\unskip,\uppercase,\wd,\xdef}
+%^^A\DoNotIndex{\font,\fontdimen,\nullfont,\sfcode} ^^A tex
+%\DoNotIndex{\detokenize,\dimexpr,\eTeXversion,\ifcsname,\ifdefined,\numexpr}
+%^^A\DoNotIndex{\fontcharwd,\iffontchar} ^^A e-tex
+%\DoNotIndex{\pdfannot,\pdfescapestring,\pdfmatch,\pdfoutput,\pdfstrcmp,
+% \pdftexrevision,\pdftexversion}
+%^^A\DoNotIndex{\(ef,lp,rp,kn(bc,ac),(kn,sh,st)bs)code,\(left,right)marginkern,
+%^^A \letterspacefont,\pdfadjustinterwordglue,\pdfadjustspacing,\pdfappendkern,
+%^^A \pdffontexpand,\pdfnoligatures,\pdfprependkern,\pdfprotrudechars,\tagcode}^^A pdftex
+%\DoNotIndex{\directlua,\luaescapestring} ^^A luatex
%\DoNotIndex{\@backslashchar,\@cclv,\@cclvi,\@classoptionslist,\@currext,\@currname,
% \@defaultunits,\@empty,\@expandtwoargs,\@firstofone,\@firstoftwo,\@gobble,
-% \@gobbletwo,\@ifnextchar,\@ifpackagelater,\@ifpackageloaded,\@ifpackagewith,
-% \@ifstar,\@ifundefined,\@m,\@makeother,\@nameuse,\@ne,\@nil,\@nnil,\@onelevel@sanitize,
-% \@onlypreamble,\@ptionlist,\@removeelement,\@secondoftwo,\@spaces,\@tempa,
-% \@tempb,\@tempc,\@tempcnta,\@tempcntb,\@tempdima,\@undefined,\@unprocessedoptions,
-% \@unusedoptionlist,\g@addto@macro,\m@ne,\on@line,\p@,\set@display@protect,
-% \strip@prefix,\strip@pt,\thr@@,\tw@,\z@,\zap@space,
-% \active,\leavevmode,\makeatletter,\newcommand,\nonfrenchspacing,\normalsize,
-% \renewcommand,\AtBeginDocument,\AtEndOfPackage,\CheckCommand,\CurrentOption,
-% \DeclareRobustCommand,\IfFileExists,\InputIfFileExists,\MessageBreak,
-% \PackageError,\PackageInfo,\PackageWarning,\RequirePackage}
+% \@gobbletwo,\@ifl@aded,\@ifpackagelater,\@ifpackageloaded,\@ifstar,\@ifundefined,
+% \@let@token,\@m,\@makeother,\@minus,\@nameuse,\@ne,\@nil,\@nnil,\@onelevel@sanitize,
+% \@onlypreamble,\@percentchar,\@pkgextension,\@plus,\@ptionlist,\@removeelement,
+% \@secondoftwo,\@spaces,\@sptoken,\@tempa,\@tempb,\@tempc,\@tempcnta,\@tempcntb,
+% \@tempdima,\@undefined,\@unprocessedoptions,\@unusedoptionlist,\@xobeysp,\check@icr,
+% \g@addto@macro,\hmode@bgroup,\m@ne,\maybe@ic,\maybe@ic@,\on@line,\p@,\set@display@protect,
+% \strip@prefix,\strip@pt,\tw@,\z@,\zap@space,\active,\leavevmode,\makeatletter,\newcommand,
+% \nobreak,\nonfrenchspacing,\normalsize,\renewcommand,\AtBeginDocument,\AtEndOfPackage,
+% \CheckCommand,\CurrentOption,\DeclareRobustCommand,\IfFileExists,\InputIfFileExists,
+% \MessageBreak,\PackageError,\PackageInfo,\PackageWarning,\RequirePackage}
%^^A\DoNotIndex{\@@enc@update,\add@accent,\cf@encoding,\curr@fontshape,
%^^A \define@newfont,\do@subst@correction,\f@encoding,\f@size,\font@name,
-%^^A \normalfont,\pickup@font,\selectfont,\set@fontsize} ^^A LaTeX
-%\DoNotIndex{\normalpdfoutput,\normalpdftexversion,\normalpdftexrevision} ^^A TeXLive
+%^^A \normalfont,\pickup@font,\selectfont,\set@fontsize} ^^A latex
+%\DoNotIndex{\normalpdfoutput,\normalpdftexversion,\normalpdftexrevision} ^^A texlive
%\DoNotIndex{\foreign@language,\languagename,\select@language,\shorthandoff} ^^A babel
-%\DoNotIndex{\percentsign} ^^A babel/spanish
-%\DoNotIndex{\CJK@ifundefined,\CJK@plane} ^^A CJK
-%\DoNotIndex{\@disablequotes} ^^A csquotes
-%\DoNotIndex{\pdfstringdefDisableCommands,\pdfstringdefWarn}^^A hyperref
-%\DoNotIndex{\@inpenc@undefined@,\IeC} ^^A inputenc
-%\DoNotIndex{\UTFviii@defined} ^^A inputenc/utf8
-%\DoNotIndex{\define@key,\KV@@sp@def,\setkeys} ^^A keyval
-%\DoNotIndex{\lst@ProcessLetter} ^^A listings
-%\DoNotIndex{\l@dunhbox@line} ^^A ledmac,ledpar
-%\DoNotIndex{\py@macron} ^^A pinyin
-%\DoNotIndex{\soulregister} ^^A soul
-%\DoNotIndex{\conditionally@traceoff} ^^A trace
+%\DoNotIndex{\percentsign} ^^A babel/spanish,galician
+%\DoNotIndex{\CJK@ifundefined,\CJK@plane} ^^A CJK
+%\DoNotIndex{\@disablequotes} ^^A csquotes
+%\DoNotIndex{\pdfstringdefDisableCommands,\pdfstringdefWarn} ^^A hyperref
+%\DoNotIndex{\@inpenc@undefined@,\IeC,\inputencoding,\inputencodingname} ^^A inputenc
+%\DoNotIndex{\UTFviii@defined} ^^A inputenc/utf8
+%\DoNotIndex{\define@key,\KV@@sp@def,\setkeys} ^^A keyval
+%\DoNotIndex{\l@dunhbox@line} ^^A ledmac,ledpar
+%\DoNotIndex{\lst@ProcessLetter} ^^A listings
+%\DoNotIndex{\py@macron} ^^A pinyin
+%\DoNotIndex{\soulregister} ^^A soul
+%\DoNotIndex{\conditionally@traceoff} ^^A trace
%\DoNotIndex{\color@begingroup,\color@endgroup,\everypar,\hbadness,\hsize,\maxdimen,
-% \parfillskip,\pretolerance,\showboxdepth,\tolerance,\vbox,\z@skip} ^^A \showhyphens
-%\DoNotIndex{\x,\y,\C,\H,\A,\R,\MT@dinfo,\MT@dinfo@nl,\tracingmicrotype,\tracingmicrotypeinpdf,
-% \iftracingmicrotypeinpdfall,\tracingmicrotypeinpdfalltrue,\tracingmicrotypeinpdfallfalse,
-% \MT@pdf@annot,\ifMT@inannot,\MT@inannottrue,\MT@inannotfalse,\MT@addto@annot,\MT@show@pdfannot,
-% \DeclareMicroTypeSet,\DeclareMicroTypeAlias,\LoadMicroTypeFile,\MicroType@Hook,\UseMicroTypeSet} ^^A microtype
+% \parfillskip,\pretolerance,\showboxdepth,\tolerance,\vbox,\z@skip} ^^A \showhyphens
+%\DoNotIndex{\x,\y,\C,\H,\A,\R,\X,\MT@dinfo,\MT@dinfo@nl,\tracingmicrotype,\tracingmicrotypeinpdf,
+% \iftracingmicrotypeinpdfall,\tracingmicrotypeinpdfalltrue,\tracingmicrotypeinpdfallfalse,
+% \MT@pdf@annot,\ifMT@inannot,\MT@inannottrue,\MT@inannotfalse,\MT@addto@annot,\MT@show@pdfannot,
+% \DeclareMicroTypeSet,\DeclareMicroTypeAlias,\LoadMicroTypeFile,\MicroType@Hook,\UseMicroTypeSet} ^^A microtype
%
% ^^A -------------------------------------------------------------------------
%
@@ -2401,6 +2658,7 @@
% \begin{description}
% \item[|debug|] Code for additional output in the log file.\\
% Used for -- surprise! -- debugging purposes.
+% \item[|lua|] Code for \luatex\ (by default disabled)
% \item[|letterspace|] The code for the \pkg{letterspace} package
% (\file{letterspace.sty}).
% \end{description}
@@ -2410,6 +2668,7 @@
% \begin{description}
% \item[|m-t|] The main configuration file (\file{microtype.cfg}).
% \item[|bch|] Settings for Bitstream Charter (\file{mt-bch.cfg}).
+% \item[|blg|] Settings for Bitstream Letter Gothic (\file{mt-blg.cfg}).
% \item[|cmr|] Settings for Computer Modern Roman (\file{mt-cmr.cfg}).
% \item[|pad|] Settings for Adobe Garamond (\file{mt-pad.cfg}).
% \item[|ppl|] Settings for Palatino (\file{mt-ppl.cfg}).
@@ -2453,28 +2712,31 @@
\newcommand*\DeclareMicrotypeSetDefault[2][]{}
\newcommand*\SetProtrusion[3][]{}
\newcommand*\SetExpansion[3][]{}
-\newcommand*\SetExtraSpacing[3][]{}
-\newcommand*\SetExtraKerning[3][]{}
\newcommand*\SetTracking[3][]{}
-\newcommand*\DisableLigatures[1]{}
+\newcommand*\SetExtraKerning[3][]{}
+\newcommand*\SetExtraSpacing[3][]{}
+\newcommand*\DisableLigatures[2][]{}
\newcommand*\DeclareCharacterInheritance[3][]{}
+\newcommand*\DeclareMicrotypeVariants[1]{}
\newcommand*\DeclareMicrotypeAlias[2]{}
\newcommand*\LoadMicrotypeFile[1]{}
\newcommand*\DeclareMicrotypeBabelHook[2]{}
\newcommand*\microtypesetup[1]{}
\newcommand*\microtypecontext[1]{}
+\newcommand*\textmicrotypecontext[2]{#2}
\@ifpackageloaded{letterspace}{\let\MT@textls\relax}{%
%</package>
\newcommand*\lsstyle{}
\newcommand\textls[2][]{}
-\def\textls#1#{\@firstofone}
+\def\textls#1#{}
\newcommand*\lslig[1]{#1}
%<*package>
}
% \end{macrocode}
-% This command also has a starred version.
+% These commands also have a starred version.
% \begin{macrocode}
\def\DeclareMicrotypeSet#1#{\@gobbletwo}
+\def\DeclareMicrotypeVariants#1#{\@gobble}
% \end{macrocode}
% Set declarations are only allowed in the preamble (resp. the main
% configuration file). The configuration commands, on the other hand, must be
@@ -2485,12 +2747,12 @@
\@onlypreamble\UseMicrotypeSet
\@onlypreamble\DeclareMicrotypeSetDefault
\@onlypreamble\DisableLigatures
+\@onlypreamble\DeclareMicrotypeVariants
\@onlypreamble\DeclareMicrotypeBabelHook
% \end{macrocode}
%\begin{macro}{\MT@old@cmd}
% The old command names had one more hunch.
-%\changes{v1.8}{2005/04/28}{renamed commands from \cs{..MicroType..} to
-% \cs{..Microtype..}}
+%\changes{v1.8}{2005/04/28}{renamed commands from \cs{..MicroType..} to \cs{..Microtype..}}
% \begin{macrocode}
\def\MT@old@cmd#1#2{%
\newcommand*#1{\MT@warning{%
@@ -2504,11 +2766,14 @@
\MT@old@cmd\DeclareMicroTypeSet \DeclareMicrotypeSet
\MT@old@cmd\UseMicroTypeSet \UseMicrotypeSet
\MT@old@cmd\LoadMicroTypeFile \LoadMicrotypeFile
+%</package>
% \end{macrocode}
%\begin{macro}{\MT@MT}
% This is us.
% \begin{macrocode}
-\def\MT@MT{microtype}
+\def\MT@MT
+%<package> {microtype}
+%<letterspace> {letterspace}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@info}
@@ -2522,19 +2787,12 @@
%\begin{macro}{\MT@error}
% Communicate.
% \begin{macrocode}
-%<*!debug>
-\def\MT@info{\PackageInfo\MT@MT}
-\def\MT@info@nl#1{\MT@info{#1\@gobble}}
-\let\MT@vinfo\@gobble
\def\MT@warning{\PackageWarning\MT@MT}
\def\MT@warning@nl#1{\MT@warning{#1\@gobble}}
-%</!debug>
-%</package>
-%<*letterspace>
-\def\MT@warning{\PackageWarning{letterspace}}
-\def\MT@warning@nl#1{\MT@warning{#1\@gobble}}
-%</letterspace>
%<*package>
+\def\MT@info{\PackageInfo\MT@MT}
+\def\MT@info@nl#1{\MT@info{#1\@gobble}}
+\let\MT@vinfo\@gobble
\def\MT@warn@err#1{\MT@error{#1}{%
This error message appears because you loaded the `\MT@MT'\MessageBreak
package with the option `verbose=errors'. Consult the documentation\MessageBreak
@@ -2555,17 +2813,18 @@
%\begin{macro}{\MT@dinfo}
%\begin{macro}{\MT@dinfo@nl}
% Cases for \cs{tracingmicrotype}:
-%\begin{itemize}
-% \item[|0|:] almost none
-% \item[|1|:] + sets \& lists
-% \item[|2|:] + heirs
-% \item[|3|:] + slots
-% \item[|4|:] + factors
-%\end{itemize}
+%\begin{enum}
+% \item almost none
+% \item + sets \& lists
+% \item + heirs
+% \item + slots
+% \item + factors
+%\end{enum}
% \begin{macrocode}
%<*debug>
+\MT@warning@nl{This is the debug version}
\newcount\tracingmicrotype
-\tracingmicrotype=\tw@
+\tracingmicrotype=2
\def\MT@info#1{\PackageInfo\MT@MT{#1}\MT@addto@annot{#1}}%
\def\MT@info@nl#1{\PackageInfo\MT@MT{#1\@gobble}\MT@addto@annot{#1}}%
\let\MT@vinfo\MT@info@nl
@@ -2583,16 +2842,16 @@
% small caret, an accompanying popup text box displaying all debug messages.
%
% Cases for \cs{tracingmicrotypeinpdf}:
-%\begin{itemize}
-% \item[|1|:] show new fonts
-% \item[|2|:] + show known fonts
-%\end{itemize}
+%\begin{enum}[1]
+% \item show new fonts
+% \item + show known fonts
+%\end{enum}
% \begin{macrocode}
\newcount\tracingmicrotypeinpdf
% \end{macrocode}
%\end{macro}
%\ifpdf\ifx\tracingmicrotypeinpdf\undefined
-% [If \file{microtype.sty} had been generated with the |debug| option, this
+% [If \file{microtype.sty} had been generated with the `|debug|' option, this
% method would be demonstrated here.]
%\else
% Let's see how it works~\dots
@@ -2639,8 +2898,10 @@
\pdfannot height 4pt width 4pt depth 2pt {%
/Subtype/Caret
/T(\expandafter\string\font@name)
- \ifcase#1\or /Subj(New font)/C[1 0 0]
- \else /Subj(Known font)/C[0 1 0]
+ \ifcase#1\or
+ /Subj(New font)/C[1 0 0]
+ \else
+ /Subj(Known font)/C[0 1 0]
\fi
/Contents(\MT@pdf@annot)
}%
@@ -2664,27 +2925,33 @@
% test which \pdftex\ we're using, if any. \cs{MT@pdftex@no} will be used
% throughout the package to respectively do the right thing.
%
-% Currently, we have to distinguish between six cases for \pdftex:
-%\begin{itemize}
-% \item[|0|:] not running \pdftex
-% \item[|1|:] \pdftex\ (\textless\ 0.14f)
-% \item[|2|:] + micro-typographic extensions (0.14f, 0.14g)
-% \item[|3|:] + protrusion relative to 1em (\textgeq\ 0.14h)
-% \item[|4|:] + automatic font expansion;
-% default \cmd\efcode\,=\,1000 (\textgeq\ 1.20)
+% Currently, we have to distinguish seven cases for \pdftex:
+%\begin{enum}
+% \item not running \pdftex
+% \item \pdftex\ (\textless\ 0.14f)
+% \item + micro-typographic extensions (0.14f, 0.14g)
+% \item + protrusion relative to 1em (\textgeq~0.14h)
+% \item + automatic font expansion;
+% default \cmd\efcode\,=\,1000 (\textgeq~1.20)
%\changes{v1.8}{2005/04/15}{case 5: \pdftex\ 1.30}
-% \item[|5|:] + \cmd{\(left,right)marginkern};
-% \cmd\pdfnoligatures;
-% \cmd\pdfstrcmp;
-% \cmd\pdfescapestring\ (\textgeq\ 1.30)
-%\changes{v2.0}{2005/08/20}{case 6: \pdftex\ 1.40 (beta:1)}
-% \item[|6|:] + adjustment of interword spacing;
-% extra kerning;
-% \cmd\letterspacefont;
-% \cmd\pdfmatch\footnote{This command was actually introduced
-% in 1.30, but was still buggy then.}
-% (\textgeq\ 1.40)
-%\end{itemize}
+% \item + \cmd{\(left,right)marginkern};
+% \cmd\pdfnoligatures;
+% \cmd\pdfstrcmp;
+% \cmd\pdfescapestring\ (\textgeq~1.30)
+%\changes{v2.0}{2005/08/20}{(beta:1) case 6: \pdftex\ 1.40}
+% \item + adjustment of interword spacing;
+% extra kerning;
+% \cmd\letterspacefont;
+% \cmd\pdftracingfonts;
+% \cmd\pdfmatch\footnote{This command was actually introduced
+% in 1.30, but was still buggy then.};
+% always \etex\
+% (\textgeq~1.40)
+%\changes{v2.2}{2007/02/23}{case 7: \pdftex\ 1.40.4}
+% \item + \cmd\letterspacefont\ doesn't disable ligatures and kerns;
+% \cmd\pdfcopyfont\
+% (\textgeq~1.40.4)
+%\end{enum}
%\changes{v1.1}{2004/09/13}{fix concerning version check
% (reported by \contributor Harald Harders <h.harders\at tu-bs.de>)}
% \begin{macrocode}
@@ -2708,26 +2975,34 @@
% \begin{macrocode}
\ifx\pdftexversion\@undefined \else
\ifx\pdftexversion\relax \else
-%<debug> \MT@dinfo@nl{0}{running pdftex \the\pdftexversion(\pdftexrevision)}
- \def\MT@pdftex@no{6}
- \ifnum\pdftexversion < 140
- \def\MT@pdftex@no{5}
+%<debug>\MT@dinfo@nl{0}{this is pdftex \the\pdftexversion(\pdftexrevision)}
+ \def\MT@pdftex@no{7}
%<*package>
- \ifnum\pdftexversion < 130
- \def\MT@pdftex@no{4}
- \ifnum\pdftexversion < 120
- \def\MT@pdftex@no{3}
- \ifnum\pdftexversion = 14
- \ifnum \expandafter`\pdftexrevision < `h
- \def\MT@pdftex@no{2}
- \ifnum \expandafter`\pdftexrevision < `f
+ \ifnum\pdftexversion = 140
+ \ifnum\pdftexrevision < 4
+ \def\MT@pdftex@no{6}
+ \fi
+ \else
+%</package>
+ \ifnum\pdftexversion < 140
+ \def\MT@pdftex@no{5}
+%<*package>
+ \ifnum\pdftexversion < 130
+ \def\MT@pdftex@no{4}
+ \ifnum\pdftexversion < 120
+ \def\MT@pdftex@no{3}
+ \ifnum\pdftexversion = 14
+ \ifnum \expandafter`\pdftexrevision < `h
+ \def\MT@pdftex@no{2}
+ \ifnum \expandafter`\pdftexrevision < `f
+ \def\MT@pdftex@no{1}
+ \fi
+ \fi
+ \else
+ \ifnum\pdftexversion < 14
\def\MT@pdftex@no{1}
\fi
\fi
- \else
- \ifnum\pdftexversion < 14
- \def\MT@pdftex@no{1}
- \fi
\fi
\fi
\fi
@@ -2735,32 +3010,37 @@
\fi
\fi
\fi
-%<debug>\MT@dinfo@nl{0}{pdftex no.: \number\MT@pdftex@no}
+%<debug>\MT@dinfo@nl{0}{pdftex no.: \MT@pdftex@no}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@clear@options}
% If we are not using \pdftex\ or in case it is too old, we disable everything
% and exit here.
% \begin{macrocode}
-%<letterspace>\ifnum\MT@pdftex@no<6
-%<package>\ifnum\MT@pdftex@no<2
- \AtEndOfPackage{\let\@unprocessedoptions\relax}
+\def\MT@clear@options{%
+ \AtEndOfPackage{\let\@unprocessedoptions\relax}%
\let\CurrentOption\@empty
- \MT@warning@nl{%
+}
+% \end{macrocode}
+%\end{macro}
+% \begin{macrocode}
+\ifnum\MT@pdftex@no <
+%<package> 2
+%<letterspace> 6
+ \MT@clear@options
+ \MT@warning@nl{You
\ifcase\MT@pdftex@no
- You don't seem to be using pdftex.\MessageBreak
+ don't seem to be using pdftex.\MessageBreak
+ `\MT@MT' only works with pdftex.\MessageBreak
+ Try running `pdflatex' instead of `latex'%
\else
-%<*package>
- You are using a pdftex version older than 0.14f.\MessageBreak
- `\MT@MT' won't work with such antiquated versions.\MessageBreak
- Please install a newer version of pdftex.\MessageBreak
-%</package>
-%<*letterspace>
- You are using a pdftex version older than 1.40.\MessageBreak
- Sorry, but robust letterspacing doesn't work with\MessageBreak
- this version. Please upgrade%
-%</letterspace>
+ are using a pdftex version older than
+%<package> 0.14f%
+%<letterspace> 1.40%
+ .\MessageBreak
+ `\MT@MT' does not work with this version.\MessageBreak
+ Please install a newer version of pdftex%
\fi
-%<package> All micro-typographic features will be disabled%
}
\endinput\fi
%<*package>
@@ -2981,40 +3261,82 @@
%
%\subsubsection{Auxiliary Macros}
%
-%\begin{macro}{\MT@requires@etex}
+%\begin{macro}{\MT@maybe@etex}
+%\changes{v2.2}{2007/05/01}{use catcode trickery}
+%\begin{macro}{\MT@maybe@etex@}
% For definitions that depend on \etex\ features.
% \begin{macrocode}
-\expandafter\let\expandafter\MT@requires@etex
+\def\MT@maybe@etex{%
\ifcase 0%
\ifx\eTeXversion\@undefined 1\else
\ifx\eTeXversion\relax 1\else
\ifcase\eTeXversion 1\fi
\fi
- \fi\space
- \@firstoftwo
+ \fi
+ \catcode`Q=14 \catcode`X=9
\else
- \@secondoftwo
+ \catcode`Q=9 \catcode`X=14
\fi
-%<debug>\MT@dinfo@nl{0}{\MT@requires@etex{}{not }running etex}
+ \MT@maybe@etex@
+}
+\def\MT@maybe@etex@#1{#1%
+ \catcode`Q=11 \catcode`X=11
+}
+%<debug>\MT@maybe@etex{\MT@dinfo@nl{0}{this is
+%<debug>Q not
+%<debug> etex}}
% \end{macrocode}
%\end{macro}
+%\end{macro}
%\begin{macro}{\MT@requires@pdftex}
% For definitions that depend on a particular \pdftex\ version.
% \begin{macrocode}
\def\MT@requires@pdftex#1{%
- \ifnum\MT@pdftex@no<#1
- \expandafter\@secondoftwo
- \else
- \expandafter\@firstoftwo
- \fi
+ \ifnum\MT@pdftex@no<#1 \expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
+}
+%<debug>\MT@requires@pdftex6{\pdftracingfonts=1}\relax
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@requires@luatex}
+%\changes{v2.2}{2007/05/10}{(basic) support for \luatex}
+% For definitions that depend on \luatex.
+% \begin{macrocode}
+%<*lua>
+\def\MT@requires@luatex{%
+ \ifx\directlua\@undefined\expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
}
+%<debug>\MT@dinfo@nl0{this is \MT@requires@luatex{}{not }luatex}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@lua}
+% Is zero the correct number for the |lua| state?
+% \begin{macrocode}
+\def\MT@lua{\directlua\z@}
+%</lua>
+%</package>
% \end{macrocode}
%\end{macro}
+% Since \luatex\ is still heavily experimental, we don't support it by default.
+% Also, at the time of this writing, \luatex\ ignores \cmd\letterspacefont.
+% \begin{macrocode}
+%<*!lua>
+\ifx\directlua\@undefined\else
+%<!letterspace> \MT@error
+%<letterspace> \MT@warning@nl
+ {`\MT@MT'
+%<!letterspace> only works with luatex if you generate\MessageBreak
+%<!letterspace> the package with the `lua' option%
+%<letterspace> doesn't currently work with luatex.\MessageBreak Bye bye%
+ }
+%<!letterspace> {}
+%<letterspace> \MT@clear@options\expandafter\endinput
+\fi
+%</!lua>
+% \end{macrocode}
%\begin{macro}{\MT@glet}
%\changes{v1.9f}{2006/08/09}{new macro}
% The forgotten primitive.
% \begin{macrocode}
-%</package>
\def\MT@glet{\global\let}
%<*package>
% \end{macrocode}
@@ -3044,9 +3366,7 @@
%\begin{macro}{\MT@let@nc}
% \cmd\let\ a \cmd\csname\ sequence to a command.
% \begin{macrocode}
-%</package>
\def\MT@let@nc#1{\expandafter\let\csname #1\endcsname}
-%<*package>
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@let@cn}
@@ -3102,35 +3422,29 @@
% If we are running \etex, we will use its primitives \cs{ifdefined} and
% \cs{ifcsname}, which decreases memory use substantially.
% \begin{macrocode}
-\MT@requires@etex{
- \def\MT@ifdefined@c@T#1{\ifdefined#1%
- \expandafter\@firstofone\else\expandafter\@gobble\fi
+\MT@maybe@etex{
+ \def\MT@ifdefined@c@T#1{%
+X \ifdefined#1\expandafter\@firstofone\else\expandafter\@gobble\fi
+Q \ifx#1\@undefined\expandafter\@gobble\else\expandafter\@firstofone\fi
}
%</package>
- \def\MT@ifdefined@c@TF#1{\ifdefined#1%
- \expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi
+%<letterspace>\catcode`\X=9
+ \def\MT@ifdefined@c@TF#1{%
+X \ifdefined#1\expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi
+%<package>Q \ifx#1\@undefined
+%<package>Q \expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
}
- \def\MT@ifdefined@n@T#1{\ifcsname#1\endcsname
- \expandafter\@firstofone\else\expandafter\@gobble\fi
+ \def\MT@ifdefined@n@T#1{%
+X \ifcsname#1\endcsname\expandafter\@firstofone\else\expandafter\@gobble\fi
+%<package>Q \begingroup\MT@exp@two@c\endgroup\ifx\csname #1\endcsname\relax
+%<package>Q \expandafter\@gobble\else\expandafter\@firstofone\fi
}
+%<letterspace>\catcode`\X=11
%<*package>
- \def\MT@ifdefined@n@TF#1{\ifcsname#1\endcsname
- \expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi
- }
-}{
- \def\MT@ifdefined@c@T#1{\ifx#1\@undefined
- \expandafter\@gobble\else\expandafter\@firstofone\fi
- }
- \def\MT@ifdefined@c@TF#1{\ifx#1\@undefined
- \expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
- }
- \def\MT@ifdefined@n@T#1{\begingroup\MT@exp@two@c\endgroup
- \ifx\csname #1\endcsname\relax
- \expandafter\@gobble\else\expandafter\@firstofone\fi
- }
- \def\MT@ifdefined@n@TF#1{\begingroup\MT@exp@two@c\endgroup
- \ifx\csname #1\endcsname\relax
- \expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
+ \def\MT@ifdefined@n@TF#1{%
+X \ifcsname#1\endcsname\expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi
+Q \begingroup\MT@exp@two@c\endgroup\ifx\csname #1\endcsname\relax
+Q \expandafter\@secondoftwo\else\expandafter\@firstoftwo\fi
}
}
% \end{macrocode}
@@ -3141,19 +3455,22 @@
%\begin{macro}{\MT@detokenize@n}
%\changes{v1.9d}{2006/03/08}{new macro: use \cmd\detokenize\ if available}
%\begin{macro}{\MT@detokenize@c}
-%\changes{v1.9}{2005/08/17}{fix the non-\etex\ version}
+%\changes{v1.9}{2005/08/17}{fix the \nonetex\ version}
% Translate a macro into a token list. With \etex, we can use \cmd\detokenize\
% (and \cmd\expandafter\cmd\string\ to get rid of the trailing space). The
-% non-\etex\ version requires some more fiddling (and the \cmd\string\ isn't
+% \nonetex\ version requires some more fiddling (and the \cmd\string\ isn't
% perfect, of course).
% \begin{macrocode}
-\MT@requires@etex{
- \def\MT@detokenize@n#1{\detokenize\expandafter{\string#1}}
- \def\MT@detokenize@c#1{\detokenize
- \expandafter\expandafter\expandafter{\expandafter\string#1}}
-}{
- \def\MT@detokenize@n#1{\string#1}
- \def\MT@detokenize@c#1{\MT@exp@two@c\zap@space\strip@prefix\meaning#1 \@empty}
+\MT@maybe@etex{
+ \def\MT@detokenize@n#1{%
+X \detokenize\expandafter{%
+ \string#1%
+X }%
+ }
+ \def\MT@detokenize@c#1{%
+X \detokenize\expandafter\expandafter\expandafter{\expandafter\string#1}%
+Q \MT@exp@two@c\zap@space\strip@prefix\meaning#1 \@empty
+ }
}
% \end{macrocode}
%\end{macro}
@@ -3176,23 +3493,40 @@
\fi
}
\endgroup
+%<*package>
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@ifint}
% Test whether argument is an integer, using an old trick by Mr. Arseneau,
%\changes{v1.9a}{2005/11/03}{use \cmd\pdfmatch\ if available}
-% or the latest and greatest from \pdftex\ (which also allows negative numbers,
-% as required by the \opt{letterspace} option).
+% or the latest and greatest from \pdftex\
+%\changes{v2.2}{2007/05/10}{employ \luatex\ features if available}
+% or \luatex\ (which also allows negative numbers, as required by the
+% \opt{letterspace} option).
% \begin{macrocode}
-%<package>\MT@requires@pdftex6{
- \def\MT@ifint#1{%
- \ifcase\pdfmatch{^-*[0-9]+ *$}{#1}\relax
- \expandafter\@secondoftwo
- \else
- \expandafter\@firstoftwo
- \fi
- }
+\MT@requires@pdftex6{
+%<*lua>
+ \MT@requires@luatex{
+ \def\MT@ifint#1{%
+ \csname
+ \MT@lua{if string.find("\luaescapestring{#1}","^-*[0-9]+ *$")
+ then tex.write("@firstoftwo")
+ else tex.write("@secondoftwo")
+ end}%
+ \endcsname
+ }
+ }{
+%</lua>
+%</package>
+ \def\MT@ifint#1{%
+ \ifcase\pdfmatch{^-*[0-9]+ *$}{#1}\relax
+ \expandafter\@secondoftwo
+ \else
+ \expandafter\@firstoftwo
+ \fi
+ }
%<*package>
+%<lua> }
}{
\def\MT@ifint#1{%
\if!\ifnum9<1#1!\else?\fi
@@ -3211,17 +3545,32 @@
% (suggested by \contributor Andreas B\"uhmann <andreas.buehmann\at web.de>)}
% ^^A private mail, 15/03/2005
%\changes{v1.9b}{2006/01/05}{use \cmd\pdfmatch\ if available}
-% (|nd| and |nc| are new Didot resp. Cicero, added in \pdftex\ 1.30; |px| is a pixel, it seems.)
+% (|nd| and |nc| are new Didot resp. Cicero, added in \pdftex\ 1.30; |px| is a pixel.)
+%\changes{v2.2}{2007/05/10}{employ \luatex\ features if available}
% \begin{macrocode}
\MT@requires@pdftex6{
- \def\MT@ifdimen#1{%
- \ifcase\pdfmatch{^([0-9]+([.,][0-9]+)?|[.,][0-9]+)%
- (em|ex|cm|mm|in|pc|pt|dd|cc|bp|sp|nd|nc|px)? *$}{#1}\relax
- \expandafter\@secondoftwo
- \else
- \expandafter\@firstoftwo
- \fi
- }
+%<*lua>
+ \MT@requires@luatex{
+ \def\MT@ifdimen#1{%
+ \csname % fix expression!
+ \MT@lua{if (string.find("\luaescapestring{#1}","^-*[0-9]+(\@percentchar a*) *$") or
+ string.find("\luaescapestring{#1}","^-*[0-9]*[.,][0-9]+(\@percentchar a*) *$"))
+ then tex.write("@firstoftwo")
+ else tex.write("@secondoftwo")
+ end}%
+ \endcsname
+ }
+ }{
+%</lua>
+ \def\MT@ifdimen#1{%
+ \ifcase\pdfmatch{^([0-9]+([.,][0-9]+)?|[.,][0-9]+)%
+ (em|ex|cm|mm|in|pc|pt|dd|cc|bp|sp|nd|nc|px)? *$}{#1}\relax
+ \expandafter\@secondoftwo
+ \else
+ \expandafter\@firstoftwo
+ \fi
+ }
+%<lua> }
}{
\def\MT@ifdimen#1{%
\setbox\z@=\hbox{%
@@ -3251,20 +3600,37 @@
%\begin{macro}{\MT@ifstreq}
% Test whether two strings (fully expanded) are equal.
%\changes{v1.9a}{2005/11/03}{use \cmd\pdfstrcmp\ if available}
+%\changes{v2.2}{2007/03/07}{fix: \nonetex\ version shouldn't use \cmd\x\ and \cmd\y\
+% (found by \contributor Wiebke Petersen <petersew\at uni-duesseldorf.de>)}
+% ^^A MID: <esmd6k$954$1@news1.rz.uni-duesseldorf.de>
+%\changes{v2.2}{2007/05/10}{employ \luatex\ features if available}
% \begin{macrocode}
\MT@requires@pdftex5{
- \def\MT@ifstreq#1#2{%
- \ifcase\pdfstrcmp{#1}{#2}\relax
- \expandafter\@firstoftwo
- \else
- \expandafter\@secondoftwo
- \fi
- }
+%<*lua>
+ \MT@requires@luatex{
+ \def\MT@ifstreq#1#2{%
+ \csname
+ \MT@lua{if "\luaescapestring{#1}" == "\luaescapestring{#2}"
+ then tex.write("@firstoftwo")
+ else tex.write("@secondoftwo")
+ end}%
+ \endcsname
+ }
+ }{
+%</lua>
+ \def\MT@ifstreq#1#2{%
+ \ifcase\pdfstrcmp{#1}{#2}\relax
+ \expandafter\@firstoftwo
+ \else
+ \expandafter\@secondoftwo
+ \fi
+ }
+%<lua> }
}{
\def\MT@ifstreq#1#2{%
- \edef\x{#1}%
- \edef\y{#2}%
- \ifx\x\y
+ \edef\MT@res@a{#1}%
+ \edef\MT@res@b{#2}%
+ \ifx\MT@res@a\MT@res@b
\expandafter\@firstoftwo
\else
\expandafter\@secondoftwo
@@ -3490,21 +3856,19 @@
% The \etex\ way is slightly faster.
% \begin{macrocode}
\newcount\MT@count
-\MT@requires@etex{
- \def\MT@increment#1{\edef#1{\number\numexpr #1 + 1\relax}}
-}{
+\MT@maybe@etex{
\def\MT@increment#1{%
- \MT@count=#1\relax
- \advance\MT@count \@ne
- \edef#1{\number\MT@count}%
+X \edef#1{\number\numexpr #1 + 1\relax}%
+Q \MT@count=#1\relax
+Q \advance\MT@count \@ne
+Q \edef#1{\number\MT@count}%
}
-}
% \end{macrocode}
%\end{macro}
%\end{macro}
%\begin{macro}{\MT@scale}
%\changes{v1.7}{2005/02/12}{new macro: use \etex's \cs{numexpr} if available}
-%\changes{v1.8}{2005/03/30}{fix: remove spaces in non-\etex\ variant
+%\changes{v1.8}{2005/03/30}{fix: remove spaces in \nonetex\ variant
% (reported by \contributor Mark Rossi <mark.rossi\at de.bosch.com>)}
% ^^A MID: <d6uhag$qoi$1@ns2.fe.internet.bosch.com>
% Multiply and divide a counter. If we are using \etex, we will use its
@@ -3513,31 +3877,18 @@
% instead of truncated. Therefore, we'll get a different (more accurate)
% result in about half of the cases.
% \begin{macrocode}
-\MT@requires@etex{
\def\MT@scale#1#2#3{%
+Q \multiply #1 #2\relax
\ifnum #3 = \z@
- #1=\numexpr #1 * #2\relax
+X #1=\numexpr #1 * #2\relax
\else
- #1=\numexpr #1 * #2 / #3\relax
- \fi
- }
-}{
- \def\MT@scale#1#2#3{%
- \multiply #1 #2\relax
- \ifnum #3 = \z@ \else
- \divide #1 #3\relax
+X #1=\numexpr #1 * #2 / #3\relax
+Q \divide #1 #3\relax
\fi
}
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@make@string}
-%\changes{v1.8}{2005/05/07}{use \cmd\@onelevel@sanitize}
-% Set the category code of all characters to 12.
-% \begin{macrocode}
-\let\MT@make@string\@onelevel@sanitize
-% \end{macrocode}
-%\end{macro}
%\changes{v1.7}{2005/03/07}{shorter command names}
%\begin{macro}{\MT@abbr@pr}
%\begin{macro}{\MT@abbr@ex}
@@ -3648,9 +3999,22 @@
% \item \cmd\showhyphens
%\end{itemize}
%
+% The \pkg{wordcount} package redefines the font-switching commands, which will
+% break \microtype. Since \microtype\ doesn't have an effect on the number of
+% words in the document anyway, we will simply disable ourselves.
+%\changes{v2.2}{2007/02/11}{disable \microtype\ if \pkg{wordcount} is loaded
+% (reported by \contributor Ross Hetherington <ross\at heth.eclipse.co.uk>)}
+% ^^A MID: <A9-dnaHX5LxN01LYnZ2dnUVZ8tqqnZ2d@eclipse.net.uk>
+% \begin{macrocode}
+\@ifl@aded{tex}{wordcount}{%
+ \MT@warning@nl{Detected the `wordcount' utility.\MessageBreak
+ Disabling `\MT@MT', since it wouldn't work}%
+ \MT@clear@options\endinput}\relax
+% \end{macrocode}
%\begin{macro}{\MT@setup@}
%\changes{v1.9a}{2005/11/21}{defer setup until the end of the preamble}
-%\changes{v1.9e}{2006/07/06}{empty \cs{MT@setup@} after use (compatibility with the \pkg{combine} class)}
+%\changes{v1.9e}{2006/07/06}{empty \cs{MT@setup@} after use
+% (compatibility with the \pkg{combine} class)}
% The setup is deferred until the end of the preamble. This has a couple of
% advantages: \cs{microtypesetup} can be used to change options later on in the
% preamble, and fonts don't have to be set up before \microtype.
@@ -3670,29 +4034,24 @@
% \begin{macrocode}
\AtBeginDocument{\MT@setup@ \MT@glet\MT@setup@\@empty}
% \end{macrocode}
-%\begin{macro}{\MT@with@package}
-%\begin{macro}{\MT@with@babel@and}
+%\begin{macro}{\MT@with@package@T}
% We almost never do anything if a package is not loaded.
% \begin{macrocode}
-\def\MT@with@package#1{\@ifpackageloaded{#1}\@firstofone\@gobble}
+\def\MT@with@package@T#1{\@ifpackageloaded{#1}\@firstofone\@gobble}
%<*package>
-\def\MT@with@babel@and#1{\@ifpackagewith{babel}{#1}\@firstofone\@gobble}
% \end{macrocode}
%\end{macro}
-%\end{macro}
-%\begin{macro}{\MT@pdfcprot@error}
-%\changes{v1.4}{2004/11/04}{check for \pkg{pdfcprot}}
-% Our competitor, the \pkg{pdfcprot} package, must not be tolerated!
+%\begin{macro}{\MT@with@babel@and@T}
+%\changes{v2.2}{2007/05/25}{also inspect class options}
+% \LaTeX's \cmd\@ifpackagewith\ ignores the class options.
% \begin{macrocode}
-\def\MT@pdfcprot@error{%
- \MT@error{Detected the `pdfcprot' package!\MessageBreak
- `\MT@MT' and `pdfcprot' may not be used together}{%
-The `pdfcprot' package provides an interface to character protrusion.\MessageBreak
-So does the `\MT@MT' package. Using both packages at the same\MessageBreak
-time will almost certainly lead to undesired results. Have your choice!}%
- \let\MT@pdfcprot@error\relax
+\def\MT@with@babel@and@T#1{%
+ \MT@ifdefined@n@T{opt@babel.\@pkgextension}{%
+ \@expandtwoargs\MT@in@clist{#1}
+ {\csname opt@babel.\@pkgextension\endcsname,\@classoptionslist}%
+ \ifMT@inlist@\expandafter\@gobble\fi
+ }\@gobble
}
-\MT@with@package{pdfcprot}\MT@pdfcprot@error
% \end{macrocode}
%\end{macro}
% Don't load \pkg{letterspace}.
@@ -3761,7 +4120,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\end{macro}
%\begin{macro}{\MT@restore@p@h}
-% Restore meaning of \cmd\# and \cmd\%.
+% Restore meaning of \cmd\% and \cmd\#.
% \begin{macrocode}
\def\MT@restore@p@h{\chardef\%`\% \chardef\#`\# }
% \end{macrocode}
@@ -3797,18 +4156,20 @@ time will almost certainly lead to undesired results. Have your choice!}%
% --- No longer needed, either.
%\fi
%\changes{v1.8}{2005/03/30}{restore percent character if Spanish \pkg{babel} is loaded}
-% Spanish \pkg{babel} modifies \cmd\%, storing the original meaning in
-% \cmd\percentsign.
+%\changes{v2.2}{2007/02/02}{restore percent character if Galician \pkg{babel} is loaded}
+% Spanish and Galician \pkg{babel} modify \cmd\%, storing the original meaning
+% in \cmd\percentsign.
% \begin{macrocode}
- \MT@with@babel@and{spanish}{\MT@ifdefined@c@T\percentsign{\let\%\percentsign}}%
+ \MT@with@babel@and@T{spanish} {\MT@ifdefined@c@T\percentsign{\let\%\percentsign}}%
+ \MT@with@babel@and@T{galician}{\MT@ifdefined@c@T\percentsign{\let\%\percentsign}}%
% \end{macrocode}
%\changes{v1.8}{2005/04/22}{restore \pkg{csquotes}'s active characters}
% Using \cmd\@disablequotes, we can restore the original meaning of all
% characters made active by \pkg{csquotes}.
% (It would be doable for older versions, too, but we won't bother.)
% \begin{macrocode}
- \MT@with@package{csquotes}{%
- \@ifpackagelater{csquotes}{2005/05/11}\@disablequotes\relax}%
+ \MT@with@package@T{csquotes}
+ {\@ifpackagelater{csquotes}{2005/05/11}\@disablequotes\relax}%
% \end{macrocode}
% \pkg{hyperref} redefines \cmd\% and \cmd\# inside a \cmd\url. We restore
% the original meanings (which we can only hope are correct).
@@ -3816,10 +4177,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Same for \pkg{tex4ht}.
%\changes{v1.9d}{2006/02/27}{restore \cmd\% and \cmd\# when \pkg{tex4ht} is loaded
% (reported by \contributor Peter Dyballa <Peter_Dyballa\at Web.DE>)}
-% ^^A private mail, 26/2/2006
+% ^^A private mail, 26/02/2006
% \begin{macrocode}
- \@ifpackageloaded{hyperref}\MT@restore@p@h{%
- \MT@with@package{tex4ht}\MT@restore@p@h}%
+ \@ifpackageloaded{hyperref}\MT@restore@p@h
+ {\MT@with@package@T{tex4ht}\MT@restore@p@h}%
}
% \end{macrocode}
%\end{macro}
@@ -3828,17 +4189,31 @@ time will almost certainly lead to undesired results. Have your choice!}%
%</package>
\MT@addto@setup{%
%<*package>
- \MT@with@package{pdfcprot}\MT@pdfcprot@error
- \MT@with@package{ledmac}\MT@ledmac@setup
+% \end{macrocode}
+%\changes{v1.4}{2004/11/04}{check for \pkg{pdfcprot}}
+% Our competitor, the \pkg{pdfcprot} package, must not be tolerated!
+% \begin{macrocode}
+ \MT@with@package@T{pdfcprot}{%
+ \MT@error{Detected the `pdfcprot' package!\MessageBreak
+ `\MT@MT' and `pdfcprot' may not be used together}{%
+The `pdfcprot' package provides an interface to character protrusion.\MessageBreak
+So does the `\MT@MT' package. Using both packages at the same\MessageBreak
+time will almost certainly lead to undesired results. Have your choice!}%
+ }
+ \MT@with@package@T{ledmac}\MT@ledmac@setup
% \end{macrocode}
% We can clean up \cs{MT@setupfont@hook} now.
% \begin{macrocode}
\let\MT@setupfont@hook\@empty
- \MT@with@babel@and{spanish}{%
+ \MT@with@babel@and@T{spanish}{%
\g@addto@macro\MT@setupfont@hook{%
\MT@ifdefined@c@T\percentsign{\let\%\percentsign}}%
}
- \MT@with@package{csquotes}{%
+ \MT@with@babel@and@T{galician}{%
+ \g@addto@macro\MT@setupfont@hook{%
+ \MT@ifdefined@c@T\percentsign{\let\%\percentsign}}%
+ }
+ \MT@with@package@T{csquotes}{%
\@ifpackagelater{csquotes}{2005/05/11}{%
\g@addto@macro\MT@setupfont@hook\@disablequotes
}{%
@@ -3847,36 +4222,34 @@ time will almost certainly lead to undesired results. Have your choice!}%
numbers, try upgrading the `csquotes' package}%
}%
}
+ \@ifpackageloaded
%</package>
- \@ifpackageloaded{hyperref}{%
+%<letterspace> \MT@with@package@T
+ {hyperref}{%
%<package> \g@addto@macro\MT@setupfont@hook\MT@restore@p@h
% \end{macrocode}
% We disable \microtype's additions inside \pkg{hyperref}'s \cmd\pdfstringdef,
% which redefines lots of commands.
%\changes{v1.9}{2005/09/10}{disable \microtype\ setup inside \pkg{hyperref}'s \cmd\pdfstringdef\
% (reported by \contributor\thanh{} <hanthethanh\at gmail.com>)}
-% ^^A private mail, 10/09/05
+% ^^A private mail, 10/09/2005
% \begin{macrocode}
\pdfstringdefDisableCommands{%
%<package> \let\pickup@font\MT@orig@pickupfont
\def\lsstyle{\pdfstringdefWarn\lsstyle}%
\def\textls#1#{\pdfstringdefWarn\textls}%
}%
- }{%
-%<*package>
- \MT@with@package{tex4ht}{%
- \g@addto@macro\MT@setupfont@hook\MT@restore@p@h
- }%
-%</package>
}
%<*package>
+ {\MT@with@package@T{tex4ht}
+ {\g@addto@macro\MT@setupfont@hook\MT@restore@p@h}}%
% \end{macrocode}
%\changes{v1.9b}{2005/12/19}{compatibility with \pkg{listings}: sanitise more catcodes
% (reported by \contributor Holger Uhr <huhr\at uni-paderborn.de>)}
% ^^A MID: <do4gvo$tv$1@news.uni-paderborn.de>
% The \pkg{listings} package makes numbers and letters active,
% \begin{macrocode}
- \MT@with@package{listings}{%
+ \MT@with@package@T{listings}{%
\g@addto@macro\MT@normal@catcodes{%
\MT@while@num{"30}{"3A}{\catcode\@tempcnta 12\relax}%
\MT@while@num{"41}{"5B}{\catcode\@tempcnta 11\relax}%
@@ -3902,14 +4275,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}
% \end{macrocode}
-%\changes{v2.0}{2005/12/21}{compatibility with \pkg{soul}: register \cs{textls} and \cs{lsstyle} (beta:3)}
+%\changes{v2.0}{2005/12/21}{(beta:3) compatibility with \pkg{soul}: register \cs{textls} and \cs{lsstyle}}
% Of course, using both \pkg{soul}'s and \microtype's letterspacing mechanisms
% at the same time doesn't make much sense. But \pkg{soul} can do more, \eg,
% underlining. The optional argument to \cs{textls} may not be used.
% \begin{macrocode}
%
%</package>
- \MT@with@package{soul}{%
+ \MT@with@package@T{soul}{%
\soulregister\lsstyle 0%
\soulregister\textls 1%
}
@@ -3918,21 +4291,21 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\changes{v2.1}{2007/01/15}{compatibility with \pkg{pinyin}: disable \microtype\ in \cmd\py@macron\
% (reported by \contributor Sven Naumann <svenau\at gmx.net>)}
% ^^A MID: <87d55hxxdd.fsf@linux.site>
-% Compatibility with \pkg{pinyin} (\pkg{CJK}) package: Disable \microtype\ in
+% Compatibility with \pkg{pinyin} (\pkg{CJK}) package: disable \microtype\ in
% \cmd\py@macron, which loads a different font for the accent.
% In older versions of \pkg{pinyin}, \cmd\py@macron\ had only one argument.
% \begin{macrocode}
- \MT@with@package{pinyin}{%
- \let\MT@py@macron\py@macron
+ \MT@with@package@T{pinyin}{%
+ \let\MT@orig@py@macron\py@macron
\@ifpackagelater{pinyin}{2006/10/17}{% 4.7.0
\def\py@macron#1#2{%
\let\pickup@font\MT@orig@pickupfont
- \MT@py@macron{#1}{#2}%
+ \MT@orig@py@macron{#1}{#2}%
\let\pickup@font\MT@pickupfont}%
}{%
\def\py@macron#1{%
\let\pickup@font\MT@orig@pickupfont
- \MT@py@macron{#1}%
+ \MT@orig@py@macron{#1}%
\let\pickup@font\MT@pickupfont}%
}%
}
@@ -3946,7 +4319,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\expandafter\ifx\the\font\nullfont\normalfont\fi
% \end{macrocode}
%
-%\subsection{Font Setup}
+%\subsection{Font Setup}\label{ssec:font-setup}
%
%\begin{macro}{\MT@setupfont}
% Setting up a font entails checking for each feature whether it should be
@@ -3957,10 +4330,17 @@ time will almost certainly lead to undesired results. Have your choice!}%
% We might have to disable stuff when used together with adventurous packages.
% \begin{macrocode}
\MT@setupfont@hook
+}
+% \end{macrocode}
+% This will use a copy of the font (allowing for expansion parameter variation).
+% \begin{macrocode}
+\MT@requires@pdftex7
+ {\g@addto@macro\MT@setupfont\MT@copy@font}\relax
% \end{macrocode}
% The font properties must be extracted from \cs{MT@font}, since the current
% value of \cmd\f@encoding\ and friends may be wrong!
% \begin{macrocode}
+\g@addto@macro\MT@setupfont{%
\MT@exp@two@c\MT@split@name\string\MT@font/\@nil
% \end{macrocode}
% Try to find a configuration file for the current font family.
@@ -3975,36 +4355,46 @@ time will almost certainly lead to undesired results. Have your choice!}%
% later, in \cs{MT@get@slot}), which isn't the case when \cmd\selectfont\
% chooses a new encoding (this would be done a second later in
% \cmd\selectfont, anyway -- three lines, to be exact).
-% (I think, I do not need this anymore -- however, I'm too afraid to remove it.)
+% (I think, I do not need this anymore -- however, I'm too afraid to remove it.
+% \dots\ Oops, I did it. Let's see whether anybody complains.)
+%\changes{v2.2}{2007/04/15}{don't call \cmd\@@enc@update\ anymore}
% \begin{macrocode}
- \ifx\f@encoding\cf@encoding\else\@@enc@update\fi
+% \ifx\f@encoding\cf@encoding\else\@@enc@update\fi
+}
% \end{macrocode}
% Tracking has to come first, since it means actually loading a different font.
+%\changes{v2.2}{2007/04/15}{only add features that are available with the respective \pdftex}
% \begin{macrocode}
- \MT@tracking
+\MT@requires@pdftex6
+ {\g@addto@macro\MT@setupfont\MT@tracking}\relax
+\g@addto@macro\MT@setupfont{%
\MT@check@font
\ifMT@inlist@
%<debug>\MT@show@pdfannot2%
\else
\MT@vinfo{Setting up font `\MT@@font'\on@line}%
% \end{macrocode}
-% Now we can begin setting up the font for all features. The following commands
-% are \cmd\let\ to \cmd\relax\ if the respective feature is generally
-% disabled.
+% Now we can begin setting up the font for all features that the current
+% \pdftex\ provides. The following commands are \cmd\let\ to \cmd\relax\ if the
+% respective feature is disabled via package options.
%
-% Protrusion has to be set up first, says Th\`anh!
+% For versions older than 1.20, protrusion has to be set up first, since then,
+% the order doesn't matter.
% \begin{macrocode}
- \MT@protrusion
- \MT@expansion
+ \MT@protrusion
+ \MT@expansion
+}
% \end{macrocode}
-% Interword spacing and kerning.
+% Interword spacing and kerning (\pdftex\ 1.40).
% \begin{macrocode}
- \MT@spacing
- \MT@kerning
+\MT@requires@pdftex6
+ {\g@addto@macro\MT@setupfont{\MT@spacing\MT@kerning}}\relax
% \end{macrocode}
-% Disable ligatures?
+% Disable ligatures (\pdftex\ 1.30).
% \begin{macrocode}
- \MT@noligatures
+\MT@requires@pdftex5
+ {\g@addto@macro\MT@setupfont\MT@noligatures}\relax
+\g@addto@macro\MT@setupfont{%
% \end{macrocode}
% Debugging.
% \begin{macrocode}
@@ -4018,6 +4408,102 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@copy@font}
+%\changes{v2.2}{2007/07/03}{optionally work on copies of fonts}
+%\begin{macro}{\MT@copy@font@}
+% The new \cmd\pdfcopyfont\ command allows to expand a font with different
+% parameters. It will be used when we find a context for \cs{SetExpansion} in
+% the preamble, or when the package has been loaded with the \opt{copyfonts}
+% option.
+% \begin{macrocode}
+\MT@requires@pdftex7{
+\let\MT@copy@font\relax
+\def\MT@copy@font@{%
+% \end{macrocode}
+%\begin{macro}{\MT@font@copy}
+% For every new expansion context, we create a new copy.
+% \begin{macrocode}
+ \xdef\MT@font@copy{\csname\MT@@font/\MT@ex@context\endcsname}%
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@font@orig}
+% \pdftex\ doesn't allow to copy a font that has already been copied and
+% expanded/letterspaced. Hence, we have to get the original.
+% \begin{macrocode}
+ \expandafter\ifx\MT@font@copy\relax
+ \edef\MT@font@orig{\csname\expandafter\string\font@name @orig\endcsname}%
+ \expandafter\ifx\MT@font@orig\relax
+ \MT@exp@two@c\MT@glet\MT@font@orig\font@name
+ \else
+ \MT@exp@two@c\let\font@name\MT@font@orig
+ \fi
+ \global\MT@exp@two@c\pdfcopyfont\MT@font@copy\font@name
+%<debug>\MT@dinfo1{creating new copy: \MT@font@copy}%
+% \end{macrocode}
+%\end{macro}
+% Since it's a new font, we have to remove it from the context lists.
+% \begin{macrocode}
+ \MT@map@clist@c\MT@active@features{%
+ \expandafter\ifx\csname MT@\@nameuse{MT@abbr@##1}\endcsname\relax\else
+ \def\@tempa{##1}%
+ \expandafter\MT@map@tlist@c
+ \csname MT@##1@doc@contexts\endcsname
+ \MT@rem@from@list
+ \fi
+ }%
+ \fi
+ \MT@exp@two@c\let\MT@font\MT@font@copy
+% \end{macrocode}
+% We only need the font identifier for letterspacing.
+% \begin{macrocode}
+ \let\font@name\MT@font@copy
+% \end{macrocode}
+% But we have to properly substitute the font after we're done.
+% \begin{macrocode}
+ \aftergroup\let\aftergroup\font@name\aftergroup\MT@font@copy
+}
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\begin{macro}{\MT@rem@from@list}
+% \begin{macrocode}
+\def\MT@rem@from@list#1{%
+ \expandafter\ifx\csname MT@\@tempa @#1font@list\endcsname\relax\else
+ \expandafter\MT@exp@one@n\expandafter\MT@rem@from@clist\expandafter
+ \MT@font \csname MT@\@tempa @#1font@list\endcsname
+ \fi
+}
+}\relax
+% \end{macrocode}
+%\end{macro}
+%\ifpdf\phantomsection\fi\label{exp-hack}
+%\paragraph{Here's the promised dirty trick}
+% for users of older \pdftex\ versions, which works around the problem that the
+% use of the same font with different expansion parameters is prohibited. If
+% you do not want to create a clone of the font setup (this would require
+% duplicating the \file{tfm}/\file{vf} files under a new name, and writing new
+% \file{fd} files and \file{map} entries), you can load a minimally larger font
+% for the paragraph in question. E.\,g., for a document typeset in 10pt:
+%\begin{verbatim}[gobble=2,morekeywords={[0]{\expandpar}}]
+% \SetExpansion
+% [ stretch = 30,
+% shrink = 60,
+% step = 5 ]
+% { encoding = *,
+% size = 10.001 }
+% { }
+% \newcommand{\expandpar}[1]{{%
+% \fontsize{10.001}{\baselineskip}\selectfont #1\par}}
+% % ...
+% \expandpar{This paragraph contains an `unnecessary' widow.}
+%\end{verbatim}
+% Note that the \cmd\expandpar\ command can only be applied to complete
+% paragraphs. If you are using Computer Modern Roman, you have to load the
+% \pkg{fix-cm} package to be able to select fonts in arbitrary sizes. Finally,
+% the reason I suggest to use a larger font, and not a smaller one, is to
+% prevent a different design size being selected.
+%
+%\bigskip
%\begin{macro}{\MT@split@name}
%\changes{v1.7}{2005/02/27}{don't define \cs{MT@encoding} \&c. \cmd\global ly}
%\changes{v2.0}{2006/12/19}{adjust to possible letterspacing}
@@ -4026,7 +4512,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@series}
%\begin{macro}{\MT@shape}
%\begin{macro}{\MT@size}
-% Split up the font name (\meta{\#6} may be the tracking amount).
+% Split up the font name (\meta{\#6} may be an expansion context and/or a
+% letterspacing amount).
% \begin{macrocode}
\def\MT@split@name#1/#2/#3/#4/#5/#6\@nil{%
\def\MT@encoding{#1}%
@@ -4073,6 +4560,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% (except for |font|).
% \begin{macrocode}
\MT@dotrue
+ \edef\@tempa{\csname MT@#1@setname\endcsname}%
\MT@map@clist@n{font,encoding,family,series,shape,size}{%
\MT@ifdefined@n@TF{MT@checklist@##1}%
{\csname MT@checklist@##1\endcsname}%
@@ -4097,15 +4585,15 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\end{macro}
%\begin{macro}{\MT@checklist@}
-% The generic test.
+% The generic test (\meta{\#1} is the axis, \meta{\#2} the feature, \cmd\@tempa\
+% contains the set name).
% \begin{macrocode}
\def\MT@checklist@#1#2{%
- \edef\@tempa{\csname MT@#2@setname\endcsname}%
%<!debug> \MT@ifdefined@n@T
%<debug> \MT@ifdefined@n@TF
{MT@#2list@#1@\@tempa}{%
% \end{macrocode}
-% Begin a \cmd\expandafter\ orgy to test whether the font attribute is in
+% Begin an \cmd\expandafter\ orgy to test whether the font attribute is in
% the list.
% \begin{macrocode}
\expandafter\MT@exp@one@n\expandafter\MT@in@clist
@@ -4128,45 +4616,12 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@checklist@font}
-% If the font matches, we skip the rest of the test.
-% \begin{macrocode}
-\def\MT@checklist@font#1{%
- \edef\@tempa{\csname MT@#1@setname\endcsname}%
-%<!debug> \MT@ifdefined@n@T
-%<debug> \MT@ifdefined@n@TF
- {MT@#1list@font@\@tempa}{%
-% \end{macrocode}
-% There mustn't be a space after the font name, hence we have to stringify it.
-% There surely is a better way than this silly chain, however, I'm beginning to
-% be haunted by \cmd\expandafter s in my dreams, so I have to leave it at
-% that.
-% \begin{macrocode}
- \expandafter\expandafter\expandafter\MT@exp@one@n
- \expandafter\expandafter\expandafter\MT@in@clist
- \expandafter\expandafter\expandafter{%
- \expandafter\expandafter\expandafter\string
- \expandafter\MT@font\expandafter}%
- \csname MT@#1list@font@\@tempa\endcsname
- \ifMT@inlist@
-%<debug>\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font `\MT@@font' in list}%
- \expandafter\MT@clist@break
- \else
-%<debug>\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font `\MT@@font' not in list}%
- \MT@dofalse
- \fi
- }%
-%<debug> {\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font list empty}}%
-}
-% \end{macrocode}
-%\end{macro}
%\begin{macro}{\MT@checklist@family}
% Also test for the alias font, if the original font is not in the list.
%\changes{v1.4b}{2004/11/22}{fix: don't try alias family name if encoding failed}
%\changes{v1.9}{2005/07/12}{fix: add two missing \cmd\expandafter s}
% \begin{macrocode}
\def\MT@checklist@family#1{%
- \edef\@tempa{\csname MT@#1@setname\endcsname}%
%<!debug> \MT@ifdefined@n@T
%<debug> \MT@ifdefined@n@TF
{MT@#1list@family@\@tempa}{%
@@ -4200,12 +4655,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Test whether font size is in list of size ranges.
% \begin{macrocode}
\def\MT@checklist@size#1{%
- \edef\@tempa{\csname MT@#1@setname\endcsname}%
%<!debug> \MT@ifdefined@n@T
%<debug> \MT@ifdefined@n@TF
{MT@#1list@size@\@tempa}{%
- \expandafter\MT@in@rlist
- \csname MT@#1list@size@\@tempa\endcsname
+ \expandafter\MT@in@rlist\csname MT@#1list@size@\@tempa\endcsname
\ifMT@inlist@
%<debug>\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: size `\MT@size' in list}%
\MT@dotrue
@@ -4219,6 +4672,33 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@checklist@font}
+% If the font matches, we skip the rest of the test.
+% \begin{macrocode}
+\def\MT@checklist@font#1{%
+%<!debug> \MT@ifdefined@n@T
+%<debug> \MT@ifdefined@n@TF
+ {MT@#1list@font@\@tempa}{%
+% \end{macrocode}
+% Since \cs{MT@font} may be appended with context and/or letterspacing specs,
+% we construct the name from the font characteristics.
+%\changes{v2.2}{2007/07/03}{fix: construct font name from characteristics}
+% \begin{macrocode}
+ \edef\@tempb{\MT@encoding/\MT@family/\MT@series/\MT@shape/\MT@size}%
+ \expandafter\MT@exp@one@n\expandafter\MT@in@clist\expandafter
+ \@tempb \csname MT@#1list@font@\@tempa\endcsname
+ \ifMT@inlist@
+%<debug>\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font `\MT@@font' in list}%
+ \expandafter\MT@clist@break
+ \else
+%<debug>\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font `\MT@@font' not in list}%
+ \MT@dofalse
+ \fi
+ }%
+%<debug> {\MT@dinfo@nl{1}{\@nameuse{MT@abbr@#1}: font list empty}}%
+}
+% \end{macrocode}
+%\end{macro}
%
%\subsubsection{Protrusion}
%
@@ -4266,19 +4746,20 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@set@all@pr}
+%\changes{v2.2}{2007/06/16}{(et al.) allow empty values}
% Set all protrusion codes of the font.
% \begin{macrocode}
\def\MT@set@all@pr#1#2{%
-%<debug>\MT@dinfo@nl{3}{-- lp/rp: setting all to \number#1/\number#2}%
- \MT@do@font{%
- \lpcode\MT@font\@tempcnta=#1\relax
- \rpcode\MT@font\@tempcnta=#2\relax
- }%
+%<debug>\MT@dinfo@nl{3}{-- lp/rp: setting all to #1/#2}%
+ \let\MT@temp\@empty
+ \MT@ifempty{#1}\relax{\g@addto@macro\MT@temp{\lpcode\MT@font\@tempcnta=#1\relax}}%
+ \MT@ifempty{#2}\relax{\g@addto@macro\MT@temp{\rpcode\MT@font\@tempcnta=#2\relax}}%
+ \MT@do@font\MT@temp
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@reset@pr@codes}
%\begin{macro}{\MT@reset@pr@codes@}
+%\begin{macro}{\MT@reset@pr@codes}
% All protrusion codes are zero for new fonts. However, if we have to reload
% the font due to different contexts, we have to reset them.
% This command will be changed by \cs{microtypecontext} if necessary.
@@ -4288,6 +4769,30 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%\end{macro}
+%\begin{macro}{\MT@compensate@tr@}
+%\begin{macro}{\MT@compensate@tr}
+%\changes{v2.2}{2007/04/05}{adjust protrusion of letterspaced fonts}
+% If the font is letterspaced, we have to add the letterspacing amount to
+% the margin kerns. This command will be activated in \cs{MT@set@tr@codes}.
+% \begin{macrocode}
+\MT@requires@pdftex6{
+ \g@addto@macro\MT@set@pr@codes\MT@compensate@tr
+ \let\MT@compensate@tr\relax
+ \def\MT@compensate@tr@{%
+%<debug>\MT@dinfo@nl{2}{... compensating for tracking (\number\MT@letterspace@)}%
+ \MT@do@font{\MT@compensate@tr@@\lpcode \MT@compensate@tr@@\rpcode}%
+ }
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\begin{macro}{\MT@compensate@tr@@}
+% \begin{macrocode}
+ \def\MT@compensate@tr@@#1{%
+ #1\MT@font\@tempcnta=\numexpr#1\MT@font\@tempcnta + \MT@letterspace@/2\relax
+ }
+}\relax
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@gobble@settings}
%\begin{macro}{\MT@dimen@six}
%\begin{macro}{\MT@get@font@dimen@six}
@@ -4386,20 +4891,21 @@ time will almost certainly lead to undesired results. Have your choice!}%
% The unit is in \cs{MT@count}, the desired factor in \cmd\@tempb, and the
% result will be returned in \cmd\@tempcntb.
% \begin{macrocode}
-\MT@requires@pdftex3{
- \def\MT@scale@to@em{%
- \@tempcntb=\MT@count\relax
+\MT@maybe@etex{
+ \MT@requires@pdftex3{
+ \def\MT@scale@to@em{%
+ \@tempcntb=\MT@count\relax
% \end{macrocode}
% For really huge fonts (100pt or so), an arithmetic overflow could occur with
% vanilla \TeX. Using \etex, this can't happen, since the intermediate value
% is 64 bit, which could only be reached with a character width larger than
% \cs{maxdimen}.
% \begin{macrocode}
- \MT@scale\@tempcntb \@tempb \MT@dimen@six
- \ifnum\@tempcntb=\z@ \else
- \MT@scale@factor
- \fi
- }
+ \MT@scale\@tempcntb \@tempb \MT@dimen@six
+ \ifnum\@tempcntb=\z@ \else
+ \MT@scale@factor
+ \fi
+ }
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@get@charwd}
@@ -4408,33 +4914,41 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\changes{v1.6}{2005/01/19}{use \etex's \cmd\fontcharwd, if available}
%\changes{v1.8}{2005/05/25}{warning for missing (resp. zero-width) characters}
% \begin{macrocode}
- \MT@requires@etex{
\def\MT@get@charwd{%
- \MT@count=\fontcharwd\MT@font\MT@char\relax
+X \MT@count=\fontcharwd\MT@font\MT@char\relax
+Q \setbox\z@=\hbox{\MT@font \char\MT@char}%
+Q \MT@count=\wd\z@
\ifnum\MT@count=\z@ \MT@info@missing@char \fi
}
+% \end{macrocode}
+%\changes{v2.2}{2007/04/05}{subtract letterspacing amount from width}
+% For letterspaced fonts, we have to subtract the letterspacing amount from the
+% characters' widths. The protrusion amounts will be adjusted at the end of
+% \cs{MT@set@pr@codes}, in \cs{MT@compensate@tr}.
+% The letterspaced font is already loaded so that 1em = \fontdim6.
+% \begin{macrocode}
+ \MT@requires@pdftex6{
+ \g@addto@macro\MT@get@charwd{%
+ \MT@ifdefined@c@T\MT@letterspace@
+ {\advance\MT@count -\dimexpr\MT@letterspace@ sp *\dimexpr 1em/1000\relax}%
+ }
+ }\relax
}{
- \def\MT@get@charwd{%
- \setbox\z@=\hbox{\MT@font \char\MT@char}%
- \MT@count=\wd\z@\relax
- \ifnum\MT@count=\z@ \MT@info@missing@char \fi
- }
- }
% \end{macrocode}
%\end{macro}
% No adjustment with versions 0.14f and 0.14g.
% \begin{macrocode}
-}{
- \def\MT@scale@to@em{%
- \MT@count=\@tempb\relax
- \ifnum\MT@count=\z@ \else
- \MT@scale@factor
- \fi
- }
+ \def\MT@scale@to@em{%
+ \MT@count=\@tempb\relax
+ \ifnum\MT@count=\z@ \else
+ \MT@scale@factor
+ \fi
+ }
% \end{macrocode}
% We need this in \cs{MT@warn@code@too@large} (neutralised).
% \begin{macrocode}
- \def\MT@get@charwd{\MT@count=\MT@dimen@six}
+ \def\MT@get@charwd{\MT@count=\MT@dimen@six}
+ }
}
% \end{macrocode}
%\begin{macro}{\MT@get@font@dimen}
@@ -4444,7 +4958,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@get@font@dimen#1{%
\ifnum\fontdimen#1\MT@font=\z@
\MT@warning@nl{Font `\MT@@font' does not specify its\MessageBreak
- \@backslashchar fontdimen \number#1 (it's zero)!\MessageBreak
+ \@backslashchar fontdimen #1 (it's zero)!\MessageBreak
You should use a different `unit' for \MT@curr@list@name}%
\else
\MT@count=\fontdimen#1\MT@font
@@ -4455,22 +4969,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@info@missing@char}
%\changes{v1.9a}{2005/11/17}{info instead of warning
% (after \contributor Michael Hoppe <mh\at michael-hoppe.de> reported that
-% the `fl' ligature is missing in Palatino \textsc{sc})}
+% the `fl' ligature is missing in Palatino <SC>)}
% ^^A MID: <1h64d0x.16xsx9n1151dieN%mh@michael-hoppe.de>
% Info about missing characters, or characters with zero width.
% \begin{macrocode}
-\MT@requires@etex{
+\MT@maybe@etex{
\def\MT@info@missing@char{%
- \MT@info@nl{Character `\the\MT@toks' \iffontchar\MT@font\MT@char
- has a width of 0pt \else is missing \fi in font\MessageBreak
- `\MT@@font'. Ignoring protrusion settings\MessageBreak
- for this character}%
- }
-}{
- \def\MT@info@missing@char{%
- \MT@info@nl{%
- Character `\the\MT@toks' has a width of 0pt\MessageBreak
- (it's probably missing) in font `\MT@@font'.\MessageBreak
+ \MT@info@nl{Character `\the\MT@toks'
+X \iffontchar\MT@font\MT@char
+ has a width of 0pt
+X \else is missing\fi
+Q \MessageBreak (it's probably missing)
+ \MessageBreak in font `\MT@@font'.\MessageBreak
Ignoring protrusion settings for this character}%
}
}
@@ -4643,8 +5153,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\begin{macro}{\MT@set@inputenc}
% The configurations may be under the regime of an input encoding.
-%\changes{v1.9f}{2006/08/03}{fix: input encoding must be set after the inheritance
-% list has been parsed}
% \begin{macrocode}
\def\MT@set@inputenc#1{%
% \end{macrocode}
@@ -4655,26 +5163,47 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
% \begin{macrocode}
- \MT@ifdefined@n@T{%
- MT@\MT@feat @#1@\csname MT@\MT@feat @#1@name\endcsname @inputenc}{%
- \MT@ifdefined@c@TF\inputencoding{%
+ \edef\@tempa{MT@\MT@feat @#1@\csname MT@\MT@feat @#1@name\endcsname @inputenc}%
+ \MT@ifdefined@n@T\@tempa\MT@set@inputenc@
+}
% \end{macrocode}
-% Set up normal catcodes, since, \eg, \pkg{listings} would otherwise want to
-% typeset the \pkg{inputenc} file when it is loaded inside a listing.
-%\changes{v2.0}{2006/09/15}{sanitise catcodes before loading input encoding
-% (problem with \pkg{listings})}
+%\end{macro}
+%\begin{macro}{\MT@set@inputenc@}
+%\changes{v2.2}{2007/06/08}{only load \pkg{inputenc} files if necessary}
+% More recent versions of \pkg{inputenc} remember the current encoding, so that
+% we can test whether we really have to load the encoding file.
% \begin{macrocode}
- \MT@normal@catcodes
-%<debug>\MT@dinfo@nl{1}{input encoding: \@nameuse{%
-%<debug>MT@\MT@feat @#1@\csname MT@\MT@feat @#1@name\endcsname @inputenc}}%
- \inputencoding{\@nameuse{%
- MT@\MT@feat @#1@\csname MT@\MT@feat @#1@name\endcsname @inputenc}}%
- }{%
+\MT@addto@setup{%
+ \@ifpackageloaded{inputenc}{
+ \@ifpackagelater{inputenc}{2006/02/22}{
+ \def\MT@set@inputenc@{%
+ \MT@ifstreq\inputencodingname{\csname\@tempa\endcsname}\relax
+ \MT@load@inputenc
+ }
+ }{
+ \let\MT@set@inputenc@\MT@load@inputenc
+ }
+ }{
+ \def\MT@set@inputenc@{%
\MT@error{Key `inputenc' used in \MT@curr@list@name, but the `inputenc'
\MessageBreak package isn't loaded. Ignoring key}%
{You must load the `inputenc' package before you can use the `inputenc' key.}%
- }%
- }%
+ }
+ }
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@load@inputenc}
+% Set up normal catcodes, since, \eg, \pkg{listings} would otherwise want to
+% actually typeset the \pkg{inputenc} file when it is being loaded inside a
+% listing.
+%\changes{v2.0}{2006/09/15}{sanitise catcodes before loading input encoding
+% (problem with \pkg{listings})}
+% \begin{macrocode}
+\def\MT@load@inputenc{%
+ \MT@normal@catcodes
+%<debug>\MT@dinfo@nl{1}{loading input encoding: \@nameuse{\@tempa}}%
+ \inputencoding{\@nameuse{\@tempa}}%
}
% \end{macrocode}
%\end{macro}
@@ -4684,11 +5213,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@set@pr@heirs#1{%
\lpcode\MT@font#1=\lpcode\MT@font\MT@char
\rpcode\MT@font#1=\rpcode\MT@font\MT@char
-%<*debug>
- \MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
- \MT@dinfo@nl{4}{;;; lp/rp (#1): \number\lpcode\MT@font\MT@char/%
- \number\rpcode\MT@font\MT@char}%
-%</debug>
+%<debug>\MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
+%<debug>\MT@dinfo@nl{4}{;;; lp/rp (#1): \number\lpcode\MT@font\MT@char/%
+%<debug> \number\rpcode\MT@font\MT@char}%
}
% \end{macrocode}
%\end{macro}
@@ -4705,10 +5232,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@warn@preset@towidth{pr}%
\let\MT@preset@aux\MT@preset@aux@factor
\else
- \let\MT@preset@aux\MT@preset@aux@space
+ \def\MT@preset@aux{\MT@preset@aux@space2}%
\fi
- \MT@preset@aux{#1}\@tempa
- \MT@preset@aux{#2}\@tempb
+ \MT@ifempty{#1}{\let\@tempa\@empty}{\MT@preset@aux{#1}\@tempa}%
+ \MT@ifempty{#2}{\let\@tempb\@empty}{\MT@preset@aux{#2}\@tempb}%
\MT@set@all@pr\@tempa\@tempb
}
% \end{macrocode}
@@ -4717,6 +5244,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@preset@aux}
%\begin{macro}{\MT@preset@aux@factor}
%\begin{macro}{\MT@preset@aux@space}
+%\changes{v2.2}{2007/06/16}{generalised}
% Auxiliary macro for presetting. Store value \meta{\#1} in macro \meta{\#2}.
% \begin{macrocode}
\def\MT@preset@aux@factor#1#2{%
@@ -4724,11 +5252,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@scale@factor
\edef#2{\number\@tempcntb}%
}
-\def\MT@preset@aux@space#1#2{%
- \def\@tempb{#1}%
- \MT@get@space@unit\tw@
+\def\MT@preset@aux@space#1#2#3{%
+ \def\@tempb{#2}%
+ \MT@get@space@unit#1%
\MT@scale@to@em
- \edef#2{\number\@tempcntb}%
+ \edef#3{\number\@tempcntb}%
}
% \end{macrocode}
%\end{macro}
@@ -4770,7 +5298,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@set@listname
\MT@let@cn\@tempc{MT@ex@c@\MT@ex@c@name}%
\expandafter\MT@ex@do\@tempc,\relax,%
- \pdffontexpand\MT@font \MT@stretch@ \MT@shrink@ \MT@step@ \MT@auto@\relax
+ \MT@expandfont
}\relax
}
% \end{macrocode}
@@ -4799,7 +5327,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\let\MT@ex@factor@\MT@ex@factor
}%
\MT@reset@ef@codes
- \pdffontexpand\MT@font \MT@stretch@ \MT@shrink@ \MT@step@ \MT@auto@\relax
+ \MT@expandfont
\MT@nonselectedfalse
}
% \end{macrocode}
@@ -4813,6 +5341,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
\let\MT@set@ex@codes\MT@set@ex@codes@n
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@expandfont}
+% Expand the font.
+% \begin{macrocode}
+\def\MT@expandfont{%
+ \pdffontexpand\MT@font \MT@stretch@ \MT@shrink@ \MT@step@ \MT@auto@\relax
+}
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@set@all@ex}
%\begin{macro}{\MT@reset@ef@codes@}
% At first, all expansion factors for the characters will be set to 1000
@@ -4874,7 +5410,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
\fi
\efcode\MT@font\MT@char=\@tempcntb
-%<debug> \MT@dinfo@nl{4}{::: ef (\MT@char): \number\efcode\MT@font\MT@char: [#2]}%
+%<debug>\MT@dinfo@nl{4}{::: ef (\MT@char): \number\efcode\MT@font\MT@char: [#2]}%
% \end{macrocode}
% Heirs, heirs, I love thy heirs.
% \begin{macrocode}
@@ -4950,10 +5486,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\MT@set@ex@heirs#1{%
\efcode\MT@font#1=\efcode\MT@font\MT@char
-%<*debug>
- \MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
- \MT@dinfo@nl{4}{::: ef (#1) \number\efcode\MT@font\MT@char}%
-%</debug>
+%<debug>\MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
+%<debug>\MT@dinfo@nl{4}{::: ef (#1) \number\efcode\MT@font\MT@char}%
}
% \end{macrocode}
%\end{macro}
@@ -5018,7 +5552,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@split@val}
+%\begin{macro}{\MT@sp@split@val}
% If |unit=space|, \cs{MT@get@space@unit} will be defined to fetch the
% corresponding fontdimen (2 for the first, 3 for the second and 4 for the
% third argument).
@@ -5026,14 +5560,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@sp@split@val#1,#2,#3\relax{%
\def\@tempb{#1}%
\MT@ifempty\@tempb\relax{%
- \MT@get@space@unit\tw@
+ \MT@get@space@unit2%
\MT@scale@to@em
\knbscode\MT@font\MT@char=\@tempcntb
%<debug>\MT@dinfo@nl{4}{;;; knbs (\MT@char): \number\knbscode\MT@font\MT@char: [#1]}%
}%
\def\@tempb{#2}%
\MT@ifempty\@tempb\relax{%
- \MT@get@space@unit\thr@@
+ \MT@get@space@unit3%
\MT@scale@to@em
\stbscode\MT@font\MT@char=\@tempcntb
%<debug>\MT@dinfo@nl{4}{;;; stbs (\MT@char): \number\stbscode\MT@font\MT@char: [#2]}%
@@ -5061,12 +5595,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\knbscode\MT@font#1=\knbscode\MT@font\MT@char
\stbscode\MT@font#1=\stbscode\MT@font\MT@char
\shbscode\MT@font#1=\shbscode\MT@font\MT@char
-%<*debug>
- \MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
- \MT@dinfo@nl{4}{;;; knbs/stbs/shbs (#1): \number\knbscode\MT@font\MT@char/%
- \number\stbscode\MT@font\MT@char/%
- \number\shbscode\MT@font\MT@char}%
-%</debug>
+%<debug>\MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
+%<debug>\MT@dinfo@nl{4}{;;; knbs/stbs/shbs (#1): \number\knbscode\MT@font\MT@char/%
+%<debug> \number\stbscode\MT@font\MT@char/\number\shbscode\MT@font\MT@char}%
}
% \end{macrocode}
%\end{macro}
@@ -5075,12 +5606,12 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@reset@sp@codes@}
% \begin{macrocode}
\def\MT@set@all@sp#1#2#3{%
-%<debug>\MT@dinfo@nl{3}{-- knbs/stbs/shbs: setting all to \number#1/\number#2/\number#3}%
- \MT@do@font{%
- \knbscode\MT@font\@tempcnta=#1\relax
- \stbscode\MT@font\@tempcnta=#2\relax
- \shbscode\MT@font\@tempcnta=#3\relax
- }%
+%<debug>\MT@dinfo@nl{3}{-- knbs/stbs/shbs: setting all to #1/#2/#3}%
+ \let\MT@temp\@empty
+ \MT@ifempty{#1}\relax{\g@addto@macro\MT@temp{\knbscode\MT@font\@tempcnta=#1\relax}}%
+ \MT@ifempty{#2}\relax{\g@addto@macro\MT@temp{\stbscode\MT@font\@tempcnta=#2\relax}}%
+ \MT@ifempty{#3}\relax{\g@addto@macro\MT@temp{\shbscode\MT@font\@tempcnta=#3\relax}}%
+ \MT@do@font\MT@temp
}
\def\MT@reset@sp@codes@{\MT@set@all@sp\z@\z@\z@}
\let\MT@reset@sp@codes\relax
@@ -5098,31 +5629,20 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@preset@sp@#1,#2,#3\@nil{%
\ifx\MT@sp@unit@\@empty
\MT@warn@preset@towidth{sp}%
- \MT@preset@aux@factor{#1}\@tempa
- \MT@preset@aux@factor{#2}\@tempc
- \MT@preset@aux@factor{#3}\@tempb
+ \MT@ifempty{#1}{\let\@tempa\@empty}{\MT@preset@aux@factor{#1}\@tempa}%
+ \MT@ifempty{#2}{\let\@tempc\@empty}{\MT@preset@aux@factor{#2}\@tempc}%
+ \MT@ifempty{#3}{\let\@tempb\@empty}{\MT@preset@aux@factor{#3}\@tempb}%
\else
- \MT@preset@aux@space{#1}\@tempa
- \def\@tempb{#2}%
- \MT@get@space@unit\thr@@
- \MT@scale@to@em
- \edef\@tempc{\number\@tempcntb}%
- \def\@tempb{#3}%
- \MT@get@space@unit4%
- \MT@scale@to@em
- \edef\@tempb{\number\@tempcntb}%
+ \MT@ifempty{#1}{\let\@tempa\@empty}{\MT@preset@aux@space2{#1}\@tempa}%
+ \MT@ifempty{#2}{\let\@tempc\@empty}{\MT@preset@aux@space3{#2}\@tempc}%
+ \MT@ifempty{#3}{\let\@tempb\@empty}{\MT@preset@aux@space4{#3}\@tempb}%
\fi
\MT@set@all@sp\@tempa\@tempc\@tempb
}
+}\relax
% \end{macrocode}
%\end{macro}
%\end{macro}
-% Only for sufficiently new versions of \pdftex.
-% \begin{macrocode}
-}{
- \let\MT@spacing\relax
-}
-% \end{macrocode}
%
%\subsubsection{Additional Kerning}
%
@@ -5182,14 +5702,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@kn@split@val#1,#2\relax{%
\def\@tempb{#1}%
\MT@ifempty\@tempb\relax{%
- \MT@get@space@unit\tw@
+ \MT@get@space@unit2%
\MT@scale@to@em
\knbccode\MT@font\MT@char=\@tempcntb
%<debug>\MT@dinfo@nl{4}{;;; knbc (\MT@char): \number\knbccode\MT@font\MT@char: [#1]}%
}%
\def\@tempb{#2}%
\MT@ifempty\@tempb\relax{%
- \MT@get@space@unit\tw@
+ \MT@get@space@unit2%
\MT@scale@to@em
\knaccode\MT@font\MT@char=\@tempcntb
%<debug>\MT@dinfo@nl{4}{;;; knac (\MT@char): \number\knaccode\MT@font\MT@char: [#2]}%
@@ -5209,11 +5729,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@set@kn@heirs#1{%
\knbccode\MT@font#1=\knbccode\MT@font\MT@char
\knaccode\MT@font#1=\knaccode\MT@font\MT@char
-%<*debug>
- \MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
- \MT@dinfo@nl{4}{;;; knbc (#1): \number\knbccode\MT@font\MT@char/%
- \number\knaccode\MT@font\MT@char}%
-%</debug>
+%<debug>\MT@dinfo@nl{2}{-- heir of \MT@char: #1}%
+%<debug>\MT@dinfo@nl{4}{;;; knbc (#1): \number\knbccode\MT@font\MT@char/%
+%<debug> \number\knaccode\MT@font\MT@char}%
}
% \end{macrocode}
%\end{macro}
@@ -5222,11 +5740,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@reset@kn@codes@}
% \begin{macrocode}
\def\MT@set@all@kn#1#2{%
-%<debug>\MT@dinfo@nl{3}{-- knac/knbc: setting all to \number#1/\number#2}%
- \MT@do@font{%
- \knbccode\MT@font\@tempcnta=#1\relax
- \knaccode\MT@font\@tempcnta=#2\relax
- }%
+%<debug>\MT@dinfo@nl{3}{-- knac/knbc: setting all to #1/#2}%
+ \let\MT@temp\@empty
+ \MT@ifempty{#1}\relax{\g@addto@macro\MT@temp{\knbccode\MT@font\@tempcnta=#1\relax}}%
+ \MT@ifempty{#2}\relax{\g@addto@macro\MT@temp{\knaccode\MT@font\@tempcnta=#2\relax}}%
+ \MT@do@font\MT@temp
}
\def\MT@reset@kn@codes@{\MT@set@all@kn\z@\z@}
\let\MT@reset@kn@codes\relax
@@ -5246,178 +5764,414 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@warn@preset@towidth{kn}%
\let\MT@preset@aux\MT@preset@aux@factor
\else
- \let\MT@preset@aux\MT@preset@aux@space
+ \def\MT@preset@aux{\MT@preset@aux@space2}%
\fi
- \MT@preset@aux{#1}\@tempa
- \MT@preset@aux{#2}\@tempb
+ \MT@ifempty{#1}{\let\@tempa\@empty}{\MT@preset@aux{#1}\@tempa}%
+ \MT@ifempty{#2}{\let\@tempb\@empty}{\MT@preset@aux{#2}\@tempb}%
\MT@set@all@kn\@tempa\@tempb
}
+}\relax
% \end{macrocode}
%\end{macro}
%\end{macro}
-% \begin{macrocode}
-}{
- \let\MT@kerning\relax
-}
-%</package>
-% \end{macrocode}
%
%\subsubsection{\lsstyle Tracking}
%
-%\begin{macro}{\lsstyle}
% This only works with \pdftex\ 1.40.
-%\changes{v2.0}{2005/09/21}{new command: letterspacing (beta:1)}
-%\changes{v2.0}{2006/09/19}{fix: font switches don't pose a problem anymore (beta:8)}
-%\changes{v2.0}{2006/09/21}{fix: letterspacing commands may be nested (beta:8)}
-%\changes{v2.0}{2006/12/28}{totally redone, using the new \cmd\letterspacefont}
% \begin{macrocode}
-%<package>\MT@requires@pdftex6{
- \DeclareRobustCommand\lsstyle{%
-%<*package>
- \MT@trackingtrue
- \def\MT@tr@setname{all}%
+\MT@requires@pdftex6{
+% \end{macrocode}
+%\begin{macro}{\MT@tracking}
+%\changes{v2.2}{2007/02/23}{remember fonts that shouldn't be letterspaced}
+%\begin{macro}{\MT@tracking@}
+%\changes{v2.2}{2007/06/16}{fix: tracking couldn't be re-enabled}
+%\begin{macro}{\MT@tr@font@list}
+% We only check whether a font should not be letterspaced at all, not whether
+% we've already done that (because we have to do it again).
+% \begin{macrocode}
+\let\MT@tr@font@list\@empty
+\def\MT@tracking@{%
+ \MT@exp@one@n\MT@in@clist\MT@font\MT@tr@font@list
+ \ifMT@inlist@\else
+ \MT@maybe@do{tr}%
+ \ifMT@do\else
+ \xdef\MT@tr@font@list{\MT@tr@font@list\MT@font,}%
+ \fi
+ \fi
+}
+\let\MT@tracking\MT@tracking@
%</package>
- \let\MT@tracking\MT@tracking@
+%<letterspace>\let\MT@tracking\relax
% \end{macrocode}
-% Enable the (protected) \cs{lslig} command.
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\begin{macro}{\MT@set@tr@codes}
+% The tracking amount is determined by the optional argument to \cs{textls},
+% settings from \cs{SetTracking}, or the global \opt{letterspace} option, in
+% this order.
% \begin{macrocode}
- \MT@let@nc{lslig }\MT@lslig
- \selectfont
+\def\MT@set@tr@codes{%
+%<*package>
+ \MT@vinfo{Tracking font `\MT@@font'\on@line}%
+ \MT@get@font@dimen@six
+ \MT@if@list@exists{%
+ \MT@set@listname
+ \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name}{%
+ \MT@let@cn\MT@letterspace{MT@tr@c@\MT@tr@c@name}%
% \end{macrocode}
-% Possibly remove the first kern (for \cs{textls*}). Use scaling to avoid a
-% `Dimension too large'.
+%\begin{macro}{\MT@tr@unit@}
+% Different unit?
% \begin{macrocode}
- \MT@lskern=\dimexpr\MT@ifdefined@c@TF\MT@letterspace@
- \MT@letterspace@\MT@letterspace sp
- * \fontdimen6\MT@lsfont/2000\relax
- \MT@ls@adjust
- }
+ \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name @unit}{%
+ \MT@let@cn\MT@tr@unit@{MT@tr@c@\MT@tr@c@name @unit}%
+ \ifdim\MT@tr@unit@=1em
+ \let\MT@tr@unit@\@undefined
+ \else
+ \MT@let@cn\@tempb{MT@tr@c@\MT@tr@c@name}%
+ \MT@get@unit\MT@tr@unit@
+ \let\MT@tr@factor@\@m
+ \MT@scale@to@em
+ \edef\MT@letterspace{\number\@tempcntb}%
+ \fi
+ }%
+ }%
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@tracking}
-%\begin{macro}{\MT@tracking@}
-% We do not check whether we've already seen the font!
+%\changes{v2.2}{2007/02/23}{disable ligatures in letterspaced fonts manually
+% (due to change in \pdftex\ 1.40.4)}
+%\begin{macro}{\MT@tr@ligatures}
+% Which ligatures should we disable (empty means all, undefined none)?
% \begin{macrocode}
- \def\MT@tracking@{%
-%<package> \ifMT@tracking\MT@maybe@do{tr}\fi
-%<letterspace> \MT@set@tr@codes
- }
-%<package> \let\MT@tracking\MT@tracking@
-%<letterspace> \let\MT@tracking\relax
+ \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name @noligatures}%
+ {\MT@let@cn\MT@tr@ligatures{MT@tr@c@\MT@tr@c@name @noligatures}}%
+% \end{macrocode}
+%\end{macro}
+%\changes{v2.2}{2007/06/16}{possibility to customise interword spacing}
+%\begin{macro}{\MT@tr@ispace}
+%\begin{macro}{\MT@tr@ospace}
+% Adjust interword spacing.
+% \begin{macrocode}
+ \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name @spacing}%
+ {\MT@let@cn\MT@tr@ispace{MT@tr@c@\MT@tr@c@name @spacing}}%
+ \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name @outerspacing}%
+ {\MT@let@cn\MT@tr@ospace{MT@tr@c@\MT@tr@c@name @outerspacing}}%
% \end{macrocode}
%\end{macro}
%\end{macro}
-%\begin{macro}{\MT@set@tr@codes}
-% The tracking amount is determined by the optional argument to \cs{textls},
-% settings from \cs{SetTracking}, or the global \opt{letterspace} option,
-% in this order.
% \begin{macrocode}
- \def\MT@set@tr@codes{%
- \MT@ifdefined@c@TF\MT@letterspace@\relax{%
- \let\MT@letterspace@\MT@letterspace
-%<*package>
- \MT@if@list@exists{%
- \MT@set@listname
- \MT@let@cn\MT@letterspace@{MT@tr@c@\MT@tr@c@name}%
+ }\relax
% \end{macrocode}
-% Different unit?
+% Activate protrusion adjustment.
% \begin{macrocode}
- \MT@ifdefined@n@T{MT@tr@c@\MT@tr@c@name @unit}{%
- \MT@let@cn\MT@tr@unit@{MT@tr@c@\MT@tr@c@name @unit}%
- \ifdim\MT@tr@unit@=1em\else
- \MT@get@font@dimen@six
- \MT@let@cn\@tempb{MT@tr@c@\MT@tr@c@name}%
- \MT@get@unit\MT@tr@unit@
- \let\MT@tr@factor@\@m
- \MT@scale@to@em
- \edef\MT@letterspace@{\number\@tempcntb}%
- \fi
- }%
- }\relax
+ \let\MT@compensate@tr\MT@compensate@tr@
%</package>
- }%
- \ifnum\MT@letterspace@=\z@\else
+ \MT@ifdefined@c@TF\MT@letterspace@\relax{\let\MT@letterspace@\MT@letterspace}%
+ \ifnum\MT@letterspace@=\z@\else
+%<package> \MT@vinfo{... Tracking by \number\MT@letterspace@}%
+% \end{macrocode}
+% Letterspacing only works in <PDF> mode.
+% \begin{macrocode}
+ \MT@warn@tracking@DVI
% \end{macrocode}
%\begin{macro}{\MT@lsfont}
% The letterspaced font instances are saved in macros
% |\|\meta{font name}|/|\meta{letterspacing amount}|ls|.
+%
+%\changes{v2.2}{2007/03/07}{use \cmd\font@name, not \cs{MT@font}}
+% In contrast to \cs{MT@font}, which may reflect the font characteristics more
+% accurately (taking substitutions into account), \cmd\font@name\ is guaranteed
+% to correspond to an actual font identifier.
% \begin{macrocode}
- \xdef\MT@lsfont{%
-%<package> \expandafter\csname\expandafter\string\MT@font
-%<letterspace> \csname\curr@fontshape\f@size
- /\number\MT@letterspace@ ls\endcsname}%
- \expandafter\ifx\MT@lsfont\relax
+ \xdef\MT@lsfont{\csname\expandafter\string\font@name
+ /\number\MT@letterspace@ ls\endcsname}%
+ \expandafter\ifx\MT@lsfont\relax
+%<debug>\MT@dinfo@nl{1}{... new letterspacing instance}%
% \end{macrocode}
%\end{macro}
% In case of nested letterspacing with different amounts, we have to extract
% the base font again.
% \begin{macrocode}
- \MT@get@ls@basefont
-%<debug>\MT@dinfo@nl{1}{... new letterspacing instance}%
- \global\expandafter\letterspacefont\MT@lsfont\font@name \MT@letterspace@
+ \MT@get@ls@basefont
+ \global\expandafter\letterspacefont\MT@lsfont\font@name\MT@letterspace@
% \end{macrocode}
-% Scale interword spacing (\fontdim2).
+% Scale interword spacing (not configurable in \pkg{letterspace}).
% \begin{macrocode}
- \fontdimen2\MT@lsfont=\dimexpr\numexpr 1000+\MT@letterspace@\relax sp
- * \fontdimen2\MT@lsfont/1000\relax
- \fi
%<*package>
- \MT@vinfo{Tracking font `\MT@@font' by \number\MT@letterspace@
- \space\on@line}%
- \let\MT@font\MT@lsfont
- \aftergroup
+ \MT@ifdefined@c@TF\MT@tr@ispace
+ {\let\@tempa\MT@tr@ispace}
+ {\edef\@tempa{\MT@letterspace@*,,}}%
+ \MT@ifdefined@c@TF\MT@tr@ospace
+ {\edef\@tempa{\@tempa,\MT@tr@ospace}}
+ {\edef\@tempa{\@tempa,,,}}%
+ \expandafter\MT@tr@adjust@space\@tempa,%
%</package>
- \MT@set@lsfont
+%<*letterspace>
+ \fontdimen2\MT@lsfont=\dimexpr\numexpr 1000+\MT@letterspace@\relax sp
+ * \fontdimen2\MT@lsfont/1000\relax
+%</letterspace>
+% \end{macrocode}
+% Disable ligatures (not configurable in \pkg{letterspace}).
+% \begin{macrocode}
+%<package> \MT@ifdefined@c@T\MT@tr@ligatures\MT@tr@noligatures
+%<letterspace> \tagcode\MT@lsfont`f=\m@ne
\fi
- }
+% \end{macrocode}
+% Finally, let the letterspaced font propagate.
+% \begin{macrocode}
+ \aftergroup\MT@set@lsfont
+%<*package>
+ \let\MT@font\MT@lsfont
+% \end{macrocode}
+% Adjust surrounding spacing.
+% \begin{macrocode}
+ \ifx\MT@ls@adjust\relax
+ \global\MT@outer@space=\csname MT@outer@space\MT@@font\endcsname
+ \MT@tr@outer@l
+ \aftergroup\aftergroup\aftergroup\MT@tr@outer@r
+ \fi
+%</package>
+ \fi
+}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@set@lsfont}
% Redefine \cmd\font@name, which will be called a second later (in
% \cmd\selectfont).
% \begin{macrocode}
- \def\MT@set@lsfont{\MT@exp@two@c\let\font@name\MT@lsfont}
+\def\MT@set@lsfont{\MT@exp@two@c\let\font@name\MT@lsfont}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\lsstyle}
+%\changes{v2.0}{2005/09/21}{(beta:1) new command: letterspacing}
+%\changes{v2.0}{2006/09/19}{(beta:8) fix: font switches don't pose a problem anymore}
+%\changes{v2.0}{2006/09/21}{(beta:8) fix: letterspacing commands may be nested}
+%\changes{v2.0}{2006/12/28}{totally redone, using the new \cmd\letterspacefont}
+% Disable the tests whether the font should be letterspaced, then trigger the
+% setup.
+% \begin{macrocode}
+\DeclareRobustCommand\lsstyle{%
+%<package> \def\MT@feat{tr}%
+ \let\MT@tracking\MT@set@tr@codes
+ \selectfont
+% \end{macrocode}
+% Possibly remove the first and last kerns (for \cs{textls*}). Use scaling to
+% avoid a `Dimension too large'.
+% \begin{macrocode}
+ \MT@lskern=\dimexpr\MT@ifdefined@c@TF\MT@letterspace@
+ \MT@letterspace@\MT@letterspace sp
+ * \fontdimen6\MT@lsfont/2000\relax
+ \MT@ls@adjust
+}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\lslig}
%\changes{v2.1}{2007/01/17}{new command: protect ligatures in letterspaced text}
+%\changes{v2.2}{2007/02/25}{always defined}
%\begin{macro}{\MT@lslig}
% For Fraktur fonts, some ligatures shouldn't be broken up. This command will
-% temporarily select the base font and insert the correct kerning. It will be
-% redefined by \cs{lsstyle}.
+% temporarily select the base font and insert the correct kerning.
% \begin{macrocode}
- \DeclareRobustCommand\lslig{\@firstofone}
- \def\MT@lslig#1{%
- \MT@get@ls@basefont
- \kern\MT@lskern{\font@name #1}\kern\MT@lskern
- }
+\DeclareRobustCommand\lslig[1]{%
+ \kern\MT@lskern
+ {\MT@get@ls@basefont\font@name #1}%
+ \kern\MT@lskern
+}
% \end{macrocode}
%\end{macro}
%\end{macro}
%\begin{macro}{\MT@get@ls@basefont}
%\changes{v2.1}{2007/01/19}{redone: use \cmd\pdfmatch\ to make it bullet-proof}
-% \pdftex\ cannot letterspace fonts that are already letterspaced. Therefore,
-% we have to extract the base font, if we find that \cmd\font@name\ contains a
-% `|+|' or a `|-|' (with \cmd\pdfmatch\ bullet-proof even if the font name
-% contains one of these letters).
-% \begin{macrocode}
- \def\MT@get@ls@basefont{%
- \ifcase\pdfmatch{^select font (.*)[+-][0-9]*ls( at .*)?$}
- {\expandafter\meaning\font@name}\relax
- \else
+% \pdftex\ cannot letterspace fonts that already are letterspaced. Therefore,
+% we have to save the base font in |\|\meta{font name}|@base|.
+%
+%\changes{v2.2}{2007/02/18}{fix again: remember base font in a macro}
+% The previous solution (checking the macro's meaning with \cmd\pdfmatch),
+% where we were loading the base font via the \cmd\font\ primitive again,
+% could destroy all previously set up micro-typographic features of the font.
+% \begin{macrocode}
+\def\MT@get@ls@basefont{%
+ \escapechar\m@ne
+ \edef\MT@ls@basefont{\csname\expandafter\string\font@name @base\endcsname}%
+ \expandafter\ifx\MT@ls@basefont\relax
+ \MT@exp@two@c\MT@glet\MT@ls@basefont\font@name
+ \else
%<debug>\MT@dinfo@nl{1}{... fixing base font}%
- \global\expandafter\font\font@name
- \expandafter\strip@prefix\pdflastmatch1
- \expandafter\strip@prefix\pdflastmatch2\relax
+ \MT@exp@two@c\let\font@name\MT@ls@basefont
+ \fi
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@tr@noligatures}
+% \pdftex\ 1.40.0--1.40.3 disabled all ligatures in letterspaced fonts.
+% \begin{macrocode}
+%<*package>
+\MT@requires@pdftex7{
+ \def\MT@tr@noligatures{%
+ \ifx\MT@tr@ligatures\@empty
+ \MT@noligatures@\MT@lsfont\@undefined
+ \else
+ \MT@noligatures@\MT@lsfont\MT@tr@ligatures
\fi
}
-%<*package>
+}{
+ \def\MT@tr@noligatures{%
+ \MT@warning@nl{%
+ Disabling selected ligatures is only possible since\MessageBreak
+ pdftex 1.40.4. Disabling all ligatures instead}%
+ \global\let\MT@tr@noligatures\relax
+ }
+}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@outer@space}
+% A new skip for outer spacing.
+% \begin{macrocode}
+\newskip\MT@outer@space
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@tr@adjust@space}
+% Adjust interword spacing (\fontdim2--4) for inner and outer space.
+% For inner spacing, the font dimensions will be adjusted, the settings for
+% outer spacing will be remembered in a macro.
+% \begin{macrocode}
+\def\MT@tr@adjust@space#1,#2,#3,#4,#5,#6,{%
+ \let\MT@temp\@empty
+ \MT@adjust@space@{#1}{#4}{2}\@empty
+ \MT@adjust@space@{#2}{#5}{3}\@plus
+ \MT@adjust@space@{#3}{#6}{4}\@minus
+ \global\MT@let@nc{MT@outer@space\expandafter\string\MT@lsfont}\MT@temp
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@adjust@space@}
+% If outer spacing settings don't exist, they will be inherited from the inner
+% spacing settings.
+% \begin{macrocode}
+\def\MT@adjust@space@#1#2#3#4{%
+ \MT@ifempty{#2}{%
+ \MT@ifempty{#1}{%
+ \edef\MT@temp{\MT@temp#4\the\fontdimen#3\MT@lsfont}%
+ }{%
+ \MT@tr@get@space{#1}{#3}{1000}%
+ \edef\MT@temp{\MT@temp#4\the\@tempdima}%
+ \fontdimen#3\MT@lsfont=\@tempdima
+ }%
+ }{%
+ \MT@tr@get@space{#2}{#3}{2000}%
+ \edef\MT@temp{\MT@temp#4\the\@tempdima}%
+ \MT@ifempty{#1}\relax{%
+ \MT@tr@get@space{#1}{#3}{1000}%
+ \fontdimen#3\MT@lsfont=\@tempdima
+ }%
+ }%
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@tr@get@space}
+% If the value is followed by an asterisk, the fontdimen will be scaled by the
+% respective amount, otherwise the value denotes the desired dimension in the
+% respective unit.
+% \begin{macrocode}
+\def\MT@tr@get@space#1#2#3{%
+ \MT@test@ast#1*\@nil{%
+ \MT@ifdefined@c@TF\MT@tr@unit@
+ {\edef\@tempb{#1}\MT@scale@to@em}
+ {\@tempcntb=#1\relax}%
+ \@tempdima=\dimexpr \dimexpr\@tempcntb sp*\MT@dimen@six/1000\relax
+ -\fontdimen#2\MT@lsfont\relax
+% \end{macrocode}
+% For \fontdim2, we also have to subtract the kerning that letterspacing adds
+% to the sides of the characters (only half if it's for outer spacing).
+% \begin{macrocode}
+ \ifnum#2=\tw@
+ \advance\@tempdima -\dimexpr\MT@letterspace@ sp*\MT@dimen@six/#3\relax
+ \fi
+ \@tempdima=\dimexpr \fontdimen#2\MT@lsfont+\@tempdima\relax
+ }{%
+ \MT@ifempty\@tempa{\let\@tempa\MT@letterspace@}\relax
+ \@tempdima=\dimexpr \numexpr1000+\@tempa sp *\fontdimen#2\MT@lsfont/1000\relax
+ }%
+%<debug>\MT@dinfo2{... adjusting font dimen #2 (#1): \the\@tempdima}%
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@tr@outer@l}
+% Recall the last skip (must really be a space, not just a marker).
+% \begin{macrocode}
+\def\MT@tr@outer@l{%
+ \ifdim\lastskip>5sp
+ \unskip \hskip\MT@outer@space
+ \fi
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@tr@outer@r}
+%\begin{macro}{\MT@tr@outer@r@}
+%\begin{macro}{\MT@tr@outer@next}
+% The following is borrowed from \pkg{soul}. I've added the cases for italic
+% correction, since tracking may also be triggered by text commands (\eg,
+% \cmd\textsc).
+% \begin{macrocode}
+\def\MT@tr@outer@r{%
+ \futurelet\MT@tr@outer@next\MT@tr@outer@r@
+}
+\def\MT@tr@outer@r@{%
+ \def\MT@temp*##1{\hskip\MT@outer@space}%
+ \ifcat\egroup\noexpand\MT@tr@outer@next
+ \unkern\egroup
+ \def\MT@temp*{\afterassignment\MT@tr@outer@r\let\x=}%
+ \else
+% \end{macrocode}
+% If the next token is \cmd\maybe@ic\ (from an enclosing text command), we
+% gobble it, read the next one, feed it to \cmd\maybe@ic@\ (via
+% \cs{MT@tr@outer@icr}) and then call ourselves again.
+% \begin{macrocode}
+ \ifx\maybe@ic\MT@tr@outer@next
+ \def\MT@temp*{\afterassignment\MT@tr@outer@icr\let\x=}%
+ \else
+% \end{macrocode}
+% If the next token is \cmd\check@icr\ (from an inner text command), we insert
+% ourselves just before it. This will then call \cmd\maybe@ic\ again the next
+% round (which however will always insert an italic correction, since it
+% doesn't read beyond our group).
+% \begin{macrocode}
+ \ifx\check@icr\MT@tr@outer@next
+ \def\MT@temp*{\aftergroup\MT@tr@outer@r\check@icr\let\x=}%
+ \else
+ \ifx\@sptoken\MT@tr@outer@next
+ \def\MT@temp* {\hskip\MT@outer@space}%
+ \else
+ \ifx~\MT@tr@outer@next
+ \def\MT@temp*~{\nobreak\hskip\MT@outer@space}%
+ \else
+ \ifx\ \MT@tr@outer@next \else
+ \ifx\space\MT@tr@outer@next \else
+ \ifx\@xobeysp\MT@tr@outer@next \else
+ \def\MT@temp*{}%
+ \let\MT@tr@outer@next\relax
+ \fi\fi\fi\fi\fi\fi\fi\fi
+ \MT@temp*%
+}
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\begin{macro}{\MT@tr@outer@icr}
+%\begin{macro}{\MT@tr@outer@icr@}
+% Helper macros for the italic correction mess.
+% \begin{macrocode}
+\def\MT@tr@outer@icr{\afterassignment\MT@tr@outer@icr@\MT@tr@outer@r}
+\def\MT@tr@outer@icr@{%
+ \let\@let@token= \MT@tr@outer@next
+ \maybe@ic@
+}
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
% For older \pdftex\ versions, let it relax.
% \begin{macrocode}
}{
- \let\MT@tracking\relax
\DeclareRobustCommand\lsstyle{%
\MT@warning{Letterspacing only works with pdftex version 1.40\MessageBreak
or newer. You might want to use the `soul' package\MessageBreak
@@ -5428,15 +6182,15 @@ time will almost certainly lead to undesired results. Have your choice!}%
%</package>
% \end{macrocode}
%\begin{macro}{\textls}
-%\changes{v2.0}{2005/09/21}{new command: letterspacing (beta:1)}
+%\changes{v2.0}{2005/09/21}{(beta:1) new command: letterspacing}
%\changes{v2.0}{2006/12/28}{starred version: remove spaces around text}
%\changes{v2.1}{2007/01/19}{fix: use \cmd\hmode@bgroup}
% This command may be used like the other text commands.
% \begin{macrocode}
\DeclareRobustCommand\textls{%
\hmode@bgroup
- \@ifstar{\let\MT@ls@adjust\MT@ls@adjust@\MT@textls}%
- {\let\MT@ls@adjust\relax \MT@textls}%
+ \@ifstar{\let\MT@ls@adjust\MT@ls@adjust@\MT@textls}%
+ {\let\MT@ls@adjust\relax \MT@textls}%
}
% \end{macrocode}
%\end{macro}
@@ -5445,12 +6199,12 @@ time will almost certainly lead to undesired results. Have your choice!}%
% The optional argument may be used to change the letterspacing factor.
% \begin{macrocode}
\newcommand\MT@textls[2][]{%
- \MT@ifempty{#1}%
- {\let\MT@letterspace@\@undefined}%
- {\KV@@sp@def\MT@letterspace@{#1}%
- \MT@ls@too@large\MT@letterspace@}%
- \lsstyle #2%
- \MT@ls@adjust
+ \MT@ifempty{#1}%
+ {\let\MT@letterspace@\@undefined}%
+ {\KV@@sp@def\MT@letterspace@{#1}%
+ \MT@ls@too@large\MT@letterspace@}%
+ \lsstyle #2%
+ \MT@ls@adjust
\egroup
}
% \end{macrocode}
@@ -5504,15 +6258,40 @@ time will almost certainly lead to undesired results. Have your choice!}%
{nl}%
}%
\ifMT@do
- \pdfnoligatures\MT@font
- \MT@vinfo{... Disabling ligatures}%
+ \MT@noligatures@\MT@font\MT@nl@ligatures
\fi
}
-}{
- \let\MT@noligatures\relax
-}
+% \end{macrocode}
+%\begin{macro}{\MT@noligatures@}
+% This is also used by \cs{MT@set@tr@codes}.
+% \begin{macrocode}
+ \def\MT@noligatures@#1#2{%
+ \MT@ifdefined@c@TF#2{%
+% \end{macrocode}
+% Early MiK\TeX\ versions (before 2.5.2579) didn't know \cmd\tagcode.
+% \begin{macrocode}
+ \MT@ifdefined@c@TF\tagcode{%
+ \MT@map@clist@c#2{%
+ \def\@tempa{##1}\MT@get@slot
+ \ifnum\MT@char > \m@ne
+ \tagcode#1\MT@char=\m@ne\fi
+ }%
+ \MT@vinfo{... Disabling ligatures for characters: #2}%
+ }{%
+ \pdfnoligatures#1%
+ \MT@warning{Cannot disable selected ligatures (pdftex doesn't\MessageBreak
+ know \@backslashchar tagcode). Disabling all ligatures of\MessageBreak
+ the font instead}%
+ }%
+ }{%
+ \pdfnoligatures#1%
+ \MT@vinfo{... Disabling ligatures}%
+ }%
+ }
+}\relax
% \end{macrocode}
%\end{macro}
+%\end{macro}
%
%\subsubsection{Loading the Configuration}
%
@@ -5548,6 +6327,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\changes{v1.1}{2004/09/13}{configuration file names in lowercase
% (suggested by \contributor Harald Harders <h.harders\at tu-bs.de>)}
+% ^^A private mail, 13/09/2004
%\begin{macro}{\MT@find@file}
%\changes{v1.1}{2004/09/14}{fix: also check whether the file for the base
% font family has already been loaded}
@@ -5576,9 +6356,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@vinfo{... Loading configuration file \MT@curr@file}%
\MT@xadd\MT@file@list{#1,}%
}{%
- \expandafter\MT@get@basefamily#1\relax\relax\relax
+ \MT@get@basefamily#1\@empty\@empty\@empty\@nil
\MT@exp@one@n\MT@in@clist\@tempa\MT@file@list
- \ifMT@inlist@\else
+ \ifMT@inlist@
+ \MT@xadd\MT@file@list{#1,}%
+ \else
\InputIfFileExists{mt-\@tempa.cfg}{%
\edef\MT@curr@file{mt-\@tempa.cfg}%
\MT@vinfo{... Loading configuration file \MT@curr@file}%
@@ -5628,9 +6410,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\catcode`\}\tw@
\catcode`\#6%
\catcode`\%14%
- \MT@map@tlist@n
- {\!\"\$\&\'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\[\]\_\`\|\~}%
- \@makeother
+ \MT@map@tlist@n{\!\"\$\&\'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\[\]\_\`\|\~}\@makeother
}
% \end{macrocode}
%\end{macro}
@@ -5660,24 +6440,40 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@get@basefamily}
% The family name might have a suffix
%\changes{v1.1}{2004/09/14}{only remove suffix, if it is `x' or `j'}
-% for expert or old style number font set
+% \eg, for expert set (|x|), old style numbers (|j|)
%\changes{v1.2}{2004/09/26}{also remove `w' (swash capitals)}
-% or for swash capitals (|x|, |j| or |w|). We mustn't simply remove the last
-% letter, as this would make for instance |cms| out of |cmss| \textit{and}
-% |cmsy| (OK, |cmex| will still become |cme|~\dots).
+% swash capitals (|w|) etc. We mustn't simply remove the last letter, as this
+% would make for instance |cms| out of |cmss| \textit{and} |cmsy| (OK, |cmex|
+% will still become |cme|~\dots).
%\changes{v1.4b}{2004/11/25}{fix: failed for font names of the form \texttt{abczz}
% (reported by \contributor Georg Verweyen <Georg.Verweyen\at WEB.DE>)}
% ^^A MID: <41A64DC7.7040404@web.de>
+%\changes{v2.2}{2007/02/04}{redone, working on font names and suffixes of arbitrary length}
+%
+% We only work on the font name if it is longer than three characters.
% \begin{macrocode}
-\def\MT@get@basefamily#1#2#3#4\relax{%
- \ifx#2\relax \def\@tempa{#1}\else
- \ifx#3\relax \def\@tempa{#1#2}\else
- \def\@tempa{#1#2#3}%
- \ifx\relax#4\relax \else
- \MT@ifstreq{#4}{\string x}\relax{%
- \MT@ifstreq{#4}{\string j}\relax{%
- \MT@ifstreq{#4}{\string w}\relax{%
- \def\@tempa{#1#2#3#4}}}}\fi\fi\fi
+\def\MT@get@basefamily#1#2#3#4\@nil{%
+ \ifx\@empty#4%
+ \def\@tempa{#1#2#3}%
+ \else
+ \let\@tempa\@empty
+ \edef\@tempb{#1#2#3#4}%
+ \expandafter\MT@get@basefamily@\@tempb\@nil
+ \fi
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@get@basefamily@}
+% This will only remove one suffix (the longest match), so that
+% \emph{combinations} of suffixes would have be to added manually (\eg,
+% |\DeclareMicrotypeVariants*{aw}|). But otherwise, something like `|padx|'
+% would be truncated to `|p|'.
+% \begin{macrocode}
+\def\MT@get@basefamily@#1#2\@nil{%
+ \edef\@tempa{\@tempa#1}%
+ \ifx\\#2\\\expandafter\@gobble\else\expandafter\@firstofone\fi
+ {\MT@in@tlist{#2}\MT@variants
+ \ifMT@inlist@\else\MT@get@basefamily@#2\@nil\fi}%
}
% \end{macrocode}
%\end{macro}
@@ -5690,6 +6486,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\changes{v1.2}{2004/09/30}{alternatively check for alias font name}
%\changes{v1.7}{2005/03/15}{use \cmd\@tfor\
% (\contributor Andreas B\"uhmann <andreas.buehmann\at web.de>'s idea)}
+% ^^A private mail, 12/03/2005
%\changes{v1.8}{2005/04/16}{made recursive}
% \begin{macrocode}
\def\MT@get@listname#1{%
@@ -5849,13 +6646,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\MT@get@inh@list{%
\let\MT@context\@empty
+% \end{macrocode}
+%\end{macro}
+% \begin{macrocode}
\MT@get@listname{\MT@feat @inh}%
\MT@ifdefined@c@TF\MT@listname{%
\MT@edef@n{MT@\MT@feat @inh@name}{\MT@listname}%
-%<*debug>
- \MT@dinfo@nl{1}{... Using \@nameuse{MT@abbr@\MT@feat} inheritance list
- `\MT@listname'}%
-%</debug>
+%<debug>\MT@dinfo@nl{1}{... Using \@nameuse{MT@abbr@\MT@feat} inheritance list
+%<debug> `\MT@listname'}%
\MT@let@cn\@tempc{MT@\MT@feat @inh@\MT@listname}%
% \end{macrocode}
% If the list is \cmd\@empty, it has already been parsed.
@@ -5865,6 +6663,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<debug>\MT@dinfo@nl{1}{parsing inheritance list ...}%
% \end{macrocode}
% The group is only required in case an input encoding is given.
+%\changes{v1.9f}{2006/08/03}{fix: input encoding must be set after the inheritance
+% list has been parsed}
% \begin{macrocode}
\begingroup
\edef\MT@curr@list@name{inheritance list\noexpand\MessageBreak`\MT@listname'}%
@@ -5879,7 +6679,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\end{macro}
%
% \subsubsection{Translating Characters into Slots}
%
@@ -5887,7 +6686,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Get the slot number of the character in the current encoding.
%
%\begin{macro}{\MT@get@slot}
-%\changes{v1.2}{2004/09/26}{fix: group must also include \cs{MT@get@composite}}
+%^^A\changes{v1.2}{2004/09/26}{fix: group must also include \cs{MT@get@composite}}
%\changes{v1.4b}{2004/11/22}{don't define \cs{MT@char} globally (save stack problem)}
%\changes{v1.6a}{2005/01/30}{completely redone, hopefully more robust
% (compatible with \pkg{frenchpro}; problem reported by
@@ -5979,14 +6778,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%\begin{macro}{\ifMT@norest}
-%\begin{macro}{\MT@testrest}
-% Switch and test whether all of the string has been used up.
+% Test whether all of the string has been used up.
% \begin{macrocode}
\newif\ifMT@norest
-\def\MT@testrest#1#2{\MT@ifstreq{#1}{#2}\relax\MT@norestfalse}
% \end{macrocode}
%\end{macro}
-%\end{macro}
%\begin{macro}{\MT@is@letter}
% Input is a letter, a character or a number.
%\changes{v1.8}{2005/04/04}{warning for non-<ASCII> characters}
@@ -6020,6 +6816,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Numbers may be specified as a three-digit decimal number (|029|),
%\changes{v1.1}{2004/09/13}{numbers may also be specified in hexadecimal or octal
% (suggested by \contributor Harald Harders <h.harders\at tu-bs.de>)}
+% ^^A private mail, 13/09/2004
% as a hexadecimal number (prefixed with~|"|: |"1D|) or as a octal number
% (prefixed with~|'|: |'35|). They must consist of at least three characters
% (including the prefix), that is, |"F| is not permitted.
@@ -6155,16 +6952,17 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\MT@is@symbol{%
\expandafter\def\expandafter\MT@char\expandafter
- {\csname\MT@encoding\MT@detokenize@c\@tempa\endcsname}%
+ {\csname\MT@encoding\MT@detokenize@c\@tempa\endcsname}%
\expandafter\MT@exp@two@c\expandafter\MT@is@char\expandafter
\meaning\expandafter\MT@char\MT@charstring\relax\relax\relax
\ifnum\MT@char@ < \z@
% \end{macrocode}
+%\changes{v2.2}{2007/03/07}{expand once more (for \pkg{frenchpro})}
% \dots~or, if it hasn't been defined by \cs{DeclareTextSymbol}, a letter
% (\eg, \cmd\i, when using \pkg{frenchpro}). ^^A as noted by Bernard Gaulle
% ^^A private mail, 28/01/2005
% \begin{macrocode}
- \expandafter\MT@is@letter\MT@char\relax\relax
+ \expandafter\expandafter\expandafter\MT@is@letter\MT@char\relax\relax
\fi
}
% \end{macrocode}
@@ -6174,7 +6972,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% A helper macro that inspects the \cmd\meaning\ of its argument.
% \begin{macrocode}
\begingroup
- \catcode`\/=0
+ \catcode`\/=\z@
% \end{macrocode}
%\SpecialEscapechar{\/}
% \begin{macrocode}
@@ -6186,10 +6984,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
/ifx/relax##1/relax
/if##3\/relax
/edef/MT@char@{/number"##2}%
- /MT@testrest/MT@charstring{##3##4}%
+ /MT@ifstreq/MT@charstring{##3##4}/relax/MT@norestfalse
/else
/edef/MT@char@{/number"##2##3}%
- /MT@testrest/MT@charstring{##4}%
+ /MT@ifstreq/MT@charstring{##4}/relax/MT@norestfalse
/fi
%<debug> /MT@dinfo@nl{3}{> `/the/MT@toks' is a \char (/MT@char@)}%
/fi
@@ -6204,23 +7002,23 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Here, we are dealing with accented characters, specified as two tokens.
%\changes{v1.7}{2005/03/10}{new macro: construct command for composite character;
% no uncontrolled expansion}
+%\changes{v2.2}{2007/06/08}{more robust: expand exactly once}
% \begin{macrocode}
\def\MT@is@composite#1#2\relax{%
\ifx\\#2\\\else
% \end{macrocode}
% Again, we construct a control sequence, this time of the form:
% |\\|\meta{encoding}\allowbreak|\|\meta{accent}|-|\meta{character}, \eg,
-% |\\T1\"-a|, which expands to a letter if it has been defined by
-% \cs{DeclareTextComposite}. This should be robust, finally, especially, since
-% we also \cmd\detokenize\ the input instead of only \cmd\string ifying it.
-% Thus, we will die gracefully even on wrong Unicode input without |utf8|.
+% |\\T1\"-a|, which we then expand once to see if it is a letter (if it has
+% been defined by \cs{DeclareTextComposite}). This should be robust, finally,
+% especially, since we also \cmd\detokenize\ the input instead of only
+% \cmd\string ifying it. Thus, we will die gracefully even on wrong Unicode
+% input without |utf8|.
%\begin{macrocode}
- \edef\MT@char{\expandafter\csname\expandafter
+ \expandafter\def\expandafter\MT@char\expandafter{\csname\expandafter
\string\csname\MT@encoding\endcsname
- \MT@detokenize@n{#1}-%
- \MT@detokenize@n{#2}%
- \endcsname}%
- \expandafter\MT@is@letter\MT@char\relax\relax
+ \MT@detokenize@n{#1}-\MT@detokenize@n{#2}\endcsname}%
+ \expandafter\expandafter\expandafter\MT@is@letter\MT@char\relax\relax
\fi
}
% \end{macrocode}
@@ -6347,8 +7145,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
% and by the substitution macros
%\end{itemize}
%
+%\iffalse
%\changes{v1.2}{2004/10/02}{check for packages that might load fonts}
%\changes{v1.4}{2004/11/04}{no need to check for packages that might load fonts anymore}
+%\fi
%\changes{v1.4}{2004/11/04}{use \cmd\pickup@font\ instead of \cmd\define@newfont\
% as the hook for \cs{MT@setupfont}}
% Up to version 1.3 of this package, we were using \cmd\define@newfont\ as the
@@ -6369,25 +7169,26 @@ time will almost certainly lead to undesired results. Have your choice!}%
% substitute font, not the selected one}
%\changes{v1.9}{2005/10/03}{allow context-specific font setup}
%\begin{macro}{\MT@font@list}
+%\begin{macro}{\MT@font}
% We use a comma separated list.
% \begin{macrocode}
\let\MT@font@list\@empty
+\let\MT@font\@empty
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@font}
+%\end{macro}
+%\begin{macro}{\do@subst@correction}
% Additionally, we hook into \cmd\do@subst@correction, which is called if
% a substitution has taken place, to record the name of the ersatz font.
% Unfortunately, this will only work for one-level substitutions.
%
% All this is done at the beginning of the document.
% \begin{macrocode}
-\let\MT@font\@empty
%</package>
\MT@addto@setup{%
%<*package>
- \g@addto@macro\do@subst@correction{%
- \xdef\MT@font{\csname \curr@fontshape/\f@size\endcsname}%
- }
+ \g@addto@macro\do@subst@correction
+ {\xdef\MT@font{\csname \curr@fontshape/\f@size\endcsname}}
%</package>
% \end{macrocode}
%\end{macro}
@@ -6395,6 +7196,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\begin{macro}{\MT@orig@pickupfont}
% Check whether \cmd\pickup@font\ is defined as expected.
% The warning issued by \cmd{\CheckCommand*} would be a bit too generic.
+% \microtype\ also seems to work with \pkg{CJK}.
% \begin{macrocode}
\@ifpackageloaded{CJK}{
\@ifpackagelater{CJK}{2006/10/17}
@@ -6419,8 +7221,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\pickup@font}
% Then we append our stuff. Everything is done inside a group.
-%<*package>
+%\changes{v2.2}{2007/04/15}{\file{letterspace.sty}: setup inside group}
% \begin{macrocode}
\g@addto@macro\pickup@font{\begingroup}
% \end{macrocode}
@@ -6428,17 +7231,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
% setup, which is extremely noisy.
%\changes{v1.9e}{2006/05/25}{no tracing with \pkg{trace} package}
% \begin{macrocode}
- \MT@with@package{trace}{\g@addto@macro\pickup@font{\conditionally@traceoff}}
-%</package>
+ \MT@with@package@T{trace}{\g@addto@macro\pickup@font{\conditionally@traceoff}}
\g@addto@macro\pickup@font{%
-%<letterspace> \MT@tracking
-%<*package>
-%<*debug>
- \global\MT@inannottrue
- \MT@glet\MT@pdf@annot\@empty
- \MT@addto@annot{(line \number\inputlineno)}%
-%</debug>
\escapechar\m@ne
+%<*package>
+%<debug> \global\MT@inannottrue
+%<debug> \MT@glet\MT@pdf@annot\@empty
+%<debug> \MT@addto@annot{(line \number\inputlineno)}%
% \end{macrocode}
% If \cs{MT@font} is empty, no substitution has taken place, hence
% \cmd\font@name\ is correct. Otherwise, if they are different,
@@ -6455,29 +7254,29 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
\fi
\MT@setupfont
- \endgroup
%</package>
+%<letterspace> \MT@tracking
+ \endgroup
}
%<*package>
% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@pickupfont}
% Remember the patched command for later.
% \begin{macrocode}
\let\MT@pickupfont\pickup@font
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@orig@add@accent}
+%\begin{macro}{\add@accent}
%\changes{v1.8}{2005/06/14}{fix: disable micro-typographic setup inside \cmd\add@accent\
% (reported by \contributor Stephan Hennig <stephanhennig\at arcor.de>)}
% ^^A MID: <42adb0e3$0$27784$9b4e6d93@newsread2.arcor-online.net>
+%\begin{macro}{\MT@orig@add@accent}
% Inside \cmd\add@accent, we have to disable \microtype's setup, since the
% grouping in the patched \cmd\pickup@font\ would break the accent if
% different fonts are used for the base character and the accent. Fortunately,
% \LaTeX\ takes care that the fonts used for the \cmd\accent\ are already set
% up, so that we cannot be overlooking them.
-% At first, I was going to change \cmd\hmode@bgroup\ only, but that is also
-% used in the commands defined by \cmd\DeclareTextFontCommand, \ie,
-% \cmd\textit\ etc.
% \begin{macrocode}
\let\MT@orig@add@accent\add@accent
\def\add@accent#1#2{%
@@ -6490,8 +7289,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<*package>
% \end{macrocode}
%\end{macro}
-% Consequently, we are the last one to change these commands, therefore there
-% is no need to check whether our definition has survived.
+%\end{macro}
+% Consequently, we are (if all goes well) the last ones to change these
+% commands, therefore there is no need to check whether our definition has
+% survived.
%\changes{v1.6}{2004/12/29}{test whether \cmd\pickup@font\ has changed}
%\changes{v1.9a}{2005/11/21}{remove superfluous test whether \cmd\pickup@font\ has changed}
%
@@ -6572,17 +7373,17 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\@tempa{##1}%
\expandafter\MT@map@tlist@c
\csname MT@##1@doc@contexts\endcsname
- \MT@rem@from@lists
+ \MT@maybe@rem@from@list
\fi
}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@rem@from@lists}
+%\begin{macro}{\MT@maybe@rem@from@list}
% Recurse through all context font lists of the document and remove the font,
% unless it's the current context.
% \begin{macrocode}
-\def\MT@rem@from@lists#1{%
+\def\MT@maybe@rem@from@list#1{%
\MT@ifstreq{\@tempa/#1}{\@tempa/\csname MT@\@tempa @context\endcsname}\relax{%
\expandafter\MT@exp@one@n\expandafter\MT@rem@from@clist\expandafter
\MT@font \csname MT@\@tempa @#1font@list\endcsname
@@ -6611,6 +7412,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\textmicrotypecontext}
+%\changes{v2.2}{2007/07/03}{new command: wrapper around \cs{microtypecontext}}
+% This is just a wrapper around \cs{microtypecontext}.
+% \begin{macrocode}
+\def\textmicrotypecontext#1#2{{\microtypecontext{#1}#2}}
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@reset@context}
%\changes{v1.9f}{2006/08/03}{only reset context if it has actually been changed}
%\begin{macro}{\MT@reset@context@}
@@ -6641,19 +7449,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@define@context}
+% Define context keys.
% \begin{macrocode}
-\def\MT@define@context#1{%
+\MT@map@clist@c\MT@features@long{%
\define@key{MTC}{#1}[]{%
- \KV@@sp@def\@tempb{#1}%
- \edef\@tempb{\@nameuse{MT@rbba@\@tempb}}%
+ \edef\@tempb{\@nameuse{MT@rbba@#1}}%
\MT@exp@one@n\MT@in@clist\@tempb\MT@active@features
\ifMT@inlist@
% \end{macrocode}
% Using an empty context is only asking for trouble, therefore we choose the
% `|@|' instead (hoping for the \LaTeX\ users' natural awe of this character).
% \begin{macrocode}
- \MT@ifempty{##1}{\def\MT@val{@}}{\KV@@sp@def\MT@val{##1}}%
+ \MT@ifempty{##1}{\def\MT@val{@}}{\def\MT@val{##1}}%
\expandafter\ifx\csname MT@\@tempb @context\endcsname\MT@val
%<debug>\MT@dinfo{1}{>>> no change of #1 context: `\MT@val'}%
\else
@@ -6680,10 +7487,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}
% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@map@clist@c\MT@features@long{\MT@define@context{#1}}
-% \end{macrocode}
%\begin{macro}{\MT@pr@context}
%\begin{macro}{\MT@ex@context}
%\begin{macro}{\MT@tr@context}
@@ -6732,31 +7535,16 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\DeclareMicrotypeSet{%
\@ifstar
- {\@ifnextchar[\MT@DeclareSetAndUseIt
- {\MT@DeclareSetAndUseIt[]}}%
- {\@ifnextchar[\MT@DeclareSet
- {\MT@DeclareSet[]}}%
+ \MT@DeclareSetAndUseIt
+ \MT@DeclareSet
}
% \end{macrocode}
%\end{macro}
%\end{macro}
%\begin{macro}{\MT@DeclareSet}
-%\begin{macro}{\MT@DeclareSetAndUseIt}
-% \begin{macrocode}
-\def\MT@DeclareSet[#1]{%
- \MT@DeclareSet@{#1}%
-}
-\def\MT@DeclareSetAndUseIt[#1]#2#3{%
- \MT@DeclareSet@{#1}{#2}{#3}%
- \UseMicrotypeSet[#1]{#2}%
-}
-% \end{macrocode}
-%\end{macro}
-%\end{macro}
-%\begin{macro}{\MT@DeclareSet@}
%\changes{v1.1}{2004/09/15}{remove spaces around first argument}
% \begin{macrocode}
-\def\MT@DeclareSet@#1#2#3{%
+\newcommand\MT@DeclareSet[3][]{%
\KV@@sp@def\@tempa{#1}%
\MT@ifempty\@tempa{%
\MT@map@clist@c\MT@features{{\MT@declare@sets{##1}{#2}{#3}}}%
@@ -6774,6 +7562,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@DeclareSetAndUseIt}
+% \begin{macrocode}
+\newcommand\MT@DeclareSetAndUseIt[3][]{%
+ \MT@DeclareSet[#1]{#2}{#3}%
+ \UseMicrotypeSet[#1]{#2}%
+}
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@curr@set@name}
% We need to remember the name of the set currently being declared.
% \begin{macrocode}
@@ -6799,19 +7595,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@define@set@keys}
-% Define the \pkg{keyval} keys for font sets.
-% \begin{macrocode}
-\def\MT@define@set@keys#1{%
- \MT@define@set@key@{encoding}{#1}%
- \MT@define@set@key@{family}{#1}%
- \MT@define@set@key@{series}{#1}%
- \MT@define@set@key@{shape}{#1}%
- \MT@define@set@key@size{#1}%
- \MT@define@set@key@font{#1}%
-}
-% \end{macrocode}
-%\end{macro}
%\begin{macro}{\MT@define@set@key@}
% \meta{\#1} = font axis, \meta{\#2} = feature.
%\changes{v1.8}{2005/04/16}{use comma lists instead of token lists}
@@ -6848,7 +7631,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \cmd\rmdefault\ resp. \cmd\bfdefault\ being expanded/protruded.
% \begin{macrocode}
\def\MT@get@highlevel#1{%
- \expandafter\MT@test@ast\MT@val*\@nil{%
+ \expandafter\MT@test@ast\MT@val*\@nil\relax{%
% \end{macrocode}
% And `|family = *|' will become \cmd\familydefault.
% \begin{macrocode}
@@ -6866,12 +7649,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@test@ast}
-% Test whether last character is an asterisk.
+% It the last character is an asterisk, execute the second argument, otherwise
+% the first one.
%\changes{v1.7}{2005/03/10}{make it simpler}
% \begin{macrocode}
\def\MT@test@ast#1*#2\@nil{%
\def\@tempa{#1}%
- \MT@ifempty{#2}\@gobble\@firstofone
+ \MT@ifempty{#2}%
}
% \end{macrocode}
%\end{macro}
@@ -6882,7 +7666,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\let\MT@font@sets\@empty
\def\MT@fix@font@set#1{%
\xdef#1{#1}%
- \global\MT@make@string#1%
+ \global\@onelevel@sanitize#1%
}
% \end{macrocode}
%\end{macro}
@@ -7037,19 +7821,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\MT@get@font#1/#2/#3/#4/#5/#6\@nil{%
\MT@ifempty{#1#2#3#4#5}\relax{%
- \let\@tempb\@empty
- \def\MT@temp{#1/#2/#3/#4/#5}%
- \MT@get@axis{encoding}{#1}%
- \MT@get@axis{family}{#2}%
- \MT@get@axis{series}{#3}%
- \MT@get@axis{shape}{#4}%
- \MT@ifempty{#5}{%
- \MT@warn@axis@empty{size}{\string\normalsize}%
- \def\MT@val{*}%
- }{%
- \def\MT@val{#5}%
- }%
- \MT@get@size
+ \MT@get@font@{#1}{#2}{#3}{#4}{#5}{0}%
\ifx\MT@val\relax\def\MT@val{0}\fi
\expandafter\g@addto@macro\expandafter\@tempb\expandafter{\MT@val}%
\let\MT@val\@tempb
@@ -7057,6 +7829,27 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\MT@get@font@}
+% Helper macro, also used by \cs{MT@get@font@and@size}.
+% \begin{macrocode}
+\def\MT@get@font@#1#2#3#4#5#6{%
+ \let\@tempb\@empty
+ \def\MT@temp{#1/#2/#3/#4/#5}%
+ \MT@get@axis{encoding}{#1}%
+ \MT@get@axis{family} {#2}%
+ \MT@get@axis{series} {#3}%
+ \MT@get@axis{shape} {#4}%
+ \ifnum#6>\z@\edef\@tempb{\@tempb*}\fi
+ \MT@ifempty{#5}{%
+ \MT@warn@axis@empty{size}{\string\normalsize}%
+ \def\MT@val{*}%
+ }{%
+ \def\MT@val{#5}%
+ }%
+ \MT@get@size
+}
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\MT@get@axis}
% \begin{macrocode}
\def\MT@get@axis#1#2{%
@@ -7080,12 +7873,16 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
% We have finally assembled all pieces to define \cs{DeclareMicrotypeSet}'s
% keys.
-% \begin{macrocode}
-\MT@map@clist@c\MT@features{\MT@define@set@keys{#1}}
-% \end{macrocode}
% It is also used for \cs{DisableLigatures}.
% \begin{macrocode}
-\MT@define@set@keys{nl}
+\MT@exp@one@n\MT@map@clist@n{\MT@features,nl}{%
+ \MT@define@set@key@{encoding}{#1}%
+ \MT@define@set@key@{family}{#1}%
+ \MT@define@set@key@{series}{#1}%
+ \MT@define@set@key@{shape}{#1}%
+ \MT@define@set@key@size{#1}%
+ \MT@define@set@key@font{#1}%
+}
% \end{macrocode}
%\begin{macro}{\UseMicrotypeSet}
% To use a particular set we simply redefine |MT@|\meta{feature}|@setname|.
@@ -7098,7 +7895,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@ifempty\@tempa{%
\MT@map@clist@c\MT@features{{\MT@use@set{##1}{#2}}}%
}{%
- \MT@map@clist@c\@tempa{%
+ \MT@map@clist@c\@tempa{{%
\KV@@sp@def\@tempa{##1}%
\MT@ifempty\@tempa\relax{%
\MT@is@feature{activation of set `#2'}{%
@@ -7106,7 +7903,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{\csname MT@rbba@\@tempa\endcsname}{#2}%
}%
}%
- }%
+ }}%
}%
}
% \end{macrocode}
@@ -7144,32 +7941,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\end{macro}
%\end{macro}
-%\begin{macro}{\DisableLigatures}
-%\changes{v1.9}{2005/07/11}{new command: disable ligatures (requires \pdftex\ 1.30)}
-% This is really simple now: we can re-use the set definitions of
-% \cs{DeclareMicrotypeSet}; there can only be one set, which we'll call
-% `|no ligatures|'.
-% \begin{macrocode}
-\MT@requires@pdftex5{
- \renewcommand*\DisableLigatures[1]{%
- \edef\MT@active@features{\MT@active@features,nl}%
- \MT@noligaturestrue
- \MT@declare@sets{nl}{no ligatures}{#1}%
- \gdef\MT@nl@setname{no ligatures}%
- }
-}{
-% \end{macrocode}
-% If \pdftex\ is too old, we issue a warning and neutralise the command.
-% \begin{macrocode}
- \renewcommand*\DisableLigatures[1]{%
- \MT@warning{Disabling ligatures of a font is only possible\MessageBreak
- with pdftex version 1.30 or newer.\MessageBreak
- Ignoring \string\DisableLigatures}%
- \MT@glet\DisableLigatures\@gobble
- }
-}
-% \end{macrocode}
-%\end{macro}
%\begin{macro}{\DeclareMicrotypeSetDefault}
%\changes{v1.8}{2005/05/15}{new command: set default font set}
% This command can be used in the main configuration file to declare the
@@ -7219,16 +7990,45 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\end{macro}
%\end{macro}
+%
+%\subsubsection{Variants and Aliases}
+%
+%\begin{macro}{\DeclareMicrotypeVariants}
+%\changes{v2.2}{2007/02/04}{new command}
+%\begin{macro}{\MT@variants}
+% Specify suffixes for variants (see \file{fontname/variants.map}).
+% The starred version appends to the list.
+% \begin{macrocode}
+\let\MT@variants\@empty
+\def\DeclareMicrotypeVariants{%
+ \@ifstar
+ \MT@DeclareVariants
+ {\let\MT@variants\@empty\MT@DeclareVariants}%
+}
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\begin{macro}{\MT@DeclareVariants}
+% \begin{macrocode}
+\def\MT@DeclareVariants#1{%
+ \MT@map@clist@n{#1}{%
+ \KV@@sp@def\@tempa{##1}%
+ \@onelevel@sanitize\@tempa
+ \xdef\MT@variants{\MT@variants{\@tempa}}%
+ }%
+}
+% \end{macrocode}
+%\end{macro}
%\begin{macro}{\DeclareMicrotypeAlias}
-% This can be used to set an alias name for a font, so that the file (and the
-% settings) for the aliased font will be loaded.
+% This can be used to set an alias name for a font, so that the file and the
+% settings for the aliased font will be loaded.
%\changes{v1.5}{2004/12/03}{remove spaces around arguments}
%\changes{v1.8}{2005/05/09}{warning when overriding an alias font}
% \begin{macrocode}
\renewcommand*\DeclareMicrotypeAlias[2]{%
\KV@@sp@def\@tempa{#1}%
\KV@@sp@def\@tempb{#2}%
- \MT@make@string\@tempb
+ \@onelevel@sanitize\@tempb
\MT@ifdefined@n@T{MT@\@tempa @alias}{%
\MT@warning{Alias font family `\@tempb' will override
alias `\@nameuse{MT@\@tempa @alias}'\MessageBreak
@@ -7256,7 +8056,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
\def\LoadMicrotypeFile#1{%
\KV@@sp@def\@tempa{#1}%
- \MT@make@string\@tempa
+ \@onelevel@sanitize\@tempa
\MT@exp@one@n\MT@in@clist\@tempa\MT@file@list
\ifMT@inlist@
\MT@vinfo{... Configuration file mt-\@tempa.cfg already loaded}%
@@ -7276,13 +8076,56 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%
+%\subsubsection{Disabling Ligatures}
+%
+%\begin{macro}{\DisableLigatures}
+%\changes{v1.9}{2005/07/11}{new command: disable ligatures (requires \pdftex\ 1.30)}
+%\changes{v2.2}{2007/01/22}{new optional argument: disable selected ligatures only}
+%\begin{macro}{\MT@DisableLigatures}
+%\begin{macro}{\MT@nl@setname}
+%\begin{macro}{\MT@nl@ligatures}
+% This is really simple now: we can re-use the set definitions of
+% \cs{DeclareMicrotypeSet}; there can only be one set, which we'll call
+% `|no ligatures|'.
+%
+% The optional argument may be used to disable selected ligatures only.
+% \begin{macrocode}
+\MT@requires@pdftex5{
+ \def\DisableLigatures{%
+ \MT@begin@catcodes
+ \MT@DisableLigatures
+ }
+ \newcommand*\MT@DisableLigatures[2][]{%
+ \MT@ifempty{#1}\relax{\gdef\MT@nl@ligatures{#1}}%
+ \xdef\MT@active@features{\MT@active@features,nl}%
+ \global\MT@noligaturestrue
+ \MT@declare@sets{nl}{no ligatures}{#2}%
+ \gdef\MT@nl@setname{no ligatures}%
+ \MT@end@catcodes
+ }
+}{
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+% If \pdftex\ is too old, we issue a warning.
+% \begin{macrocode}
+ \renewcommand*\DisableLigatures[2][]{%
+ \MT@warning{Disabling ligatures of a font is only possible\MessageBreak
+ with pdftex version 1.30 or newer.\MessageBreak
+ Ignoring \string\DisableLigatures}%
+ }
+}
+% \end{macrocode}
+%\end{macro}
+%
%\subsubsection{Interaction with \pkg{babel}}
%
%\begin{macro}{\DeclareMicrotypeBabelHook}
% Declare the context that should be loaded when a \pkg{babel} language
% is selected. The command will not check whether a previous declaration will
% be overwritten.
-%\changes{v2.0}{2005/10/04}{new command: interaction with \pkg{babel} (beta:1)}
+%\changes{v2.0}{2005/10/04}{(beta:1) new command: interaction with \pkg{babel}}
% \begin{macrocode}
\def\DeclareMicrotypeBabelHook#1#2{%
\MT@map@clist@n{#1}{%
@@ -7300,9 +8143,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
% setting the character protrusion resp. expansion factors for a set of fonts.
%
%\begin{macro}{\SetProtrusion}
+%\changes{v1.9}{2005/07/13}{(et al.) new key: \texttt{font}}
%\changes{v1.9d}{2006/02/23}{(et al.) split keys of optional and mandatory argument}
%\changes{v1.9d}{2006/02/23}{(et al.) optimise: unify keys for mandatory argument}
-%\changes{v1.9e}{2006/07/26}{new key: \texttt{inputenc}}
+%\changes{v1.9e}{2006/07/26}{(et al.) new key: \texttt{inputenc}}
%\changes{v1.9f}{2006/08/10}{(et al.) set catcodes before parsing optional argument}
% This macro accepts three arguments: [options,] set of font attributes and
% list of character protrusion factors.
@@ -7393,6 +8237,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\begin{macro}{\SetTracking}
%\changes{v2.0}{2006/12/28}{new command: tracking}
+%\changes{v2.2}{2007/02/23}{third argument may be empty}
+%\changes{v2.2}{2007/02/23}{new key `\texttt{no ligatures}' to disable
+% ligatures of letterspaced fonts}
+%\changes{v2.2}{2007/06/16}{new keys `\texttt{spacing}' and `\texttt{outer spacing}'
+% to adjust interword spacing
+% (suggested by \contributor Steven E. Harris <seh\at panix.com>)}
+% ^^A private mail, 15/06/2007
% \begin{macrocode}
\def\SetTracking{%
\MT@begin@catcodes
@@ -7401,6 +8252,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
%\begin{macro}{\MT@SetTracking}
+% Third argument may be empty.
% \begin{macrocode}
\newcommand*\MT@SetTracking[3][]{%
\let\MT@extra@context\@empty
@@ -7409,13 +8261,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@permutelist{tr@c}%
\setkeys{MT@cfg}{#2}%
\MT@permute
- \MT@gdef@n{MT@tr@c@\MT@tr@c@name}{#3}%
+ \MT@ifempty{#3}\relax{\MT@gdef@n{MT@tr@c@\MT@tr@c@name}{#3}}%
\MT@end@catcodes
}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\SetExtraSpacing}
-%\changes{v2.0}{2005/09/28}{new command: adjustment of interword spacing (beta:1)}
+%\changes{v2.0}{2005/09/28}{(beta:1) new command: adjustment of interword spacing}
% \begin{macrocode}
\def\SetExtraSpacing{%
\MT@begin@catcodes
@@ -7445,7 +8297,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\todo{command to inhibit kerning etc.}
%\begin{macro}{\SetExtraKerning}
-%\changes{v2.0}{2005/09/28}{new command: additional kerning (beta:1)}
+%\changes{v2.0}{2005/09/28}{(beta:1) new command: additional kerning}
% \begin{macrocode}
\def\SetExtraKerning{%
\MT@begin@catcodes
@@ -7533,7 +8385,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\changes{v1.9}{2005/07/13}{\cs{SetProtrusion} and \cs{SetExpansion}: new key: \texttt{font}}
%\begin{macro}{\MT@define@code@key@font}
%\changes{v1.9c}{2006/01/25}{fix: context was ignored}
% \begin{macrocode}
@@ -7544,11 +8395,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\expandafter\MT@get@font@and@size\MT@val/////\@nil
\MT@xdef@n{MT@\MT@permutelist @\@tempb\MT@extra@context}%
{\csname MT@\MT@permutelist @name\endcsname}%
-%<*debug>
- \MT@dinfo@nl{1}{initialising: use list for font \@tempb=\MT@val
- \ifx\MT@extra@context\@empty\else\MessageBreak
- (context: \MT@extra@context)\fi}%
-%</debug>
+%<debug>\MT@dinfo@nl{1}{initialising: use list for font \@tempb=\MT@val
+%<debug> \ifx\MT@extra@context\@empty\else\MessageBreak
+%<debug> (context: \MT@extra@context)\fi}%
\expandafter\MT@xaddb
\csname MT@\MT@permutelist @\@tempb\MT@extra@context @sizes\endcsname
{{{\MT@val}{\m@ne}{\MT@curr@set@name}}}%
@@ -7561,25 +8410,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Translate any asterisks and split off the size.
% \begin{macrocode}
\def\MT@get@font@and@size#1/#2/#3/#4/#5/#6\@nil{%
- \MT@ifempty{#1#2#3#4#5}\relax{%
- \let\@tempb\@empty
- \def\MT@temp{#1/#2/#3/#4/#5}%
- \MT@get@axis{encoding}{#1}%
- \MT@get@axis{family}{#2}%
- \MT@get@axis{series}{#3}%
- \MT@get@axis{shape}{#4}%
-% \end{macrocode}
-% Append an asterisk for the size.
-% \begin{macrocode}
- \edef\@tempb{\@tempb*}%
- \MT@ifempty{#5}{%
- \MT@warn@axis@empty{size}{\string\normalsize}%
- \def\MT@val{*}%
- }{%
- \def\MT@val{#5}%
- }%
- \MT@get@size
- }%
+ \MT@ifempty{#1#2#3#4#5}\relax
+ {\MT@get@font@{#1}{#2}{#3}{#4}{#5}{1}}%
}
% \end{macrocode}
%\end{macro}
@@ -7591,17 +8423,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@define@code@key@size{cfg}
\MT@define@code@key@font{cfg}
% \end{macrocode}
-%\todo{use \pkg{xkeyval} instead of \pkg{keyval}?}
-%\begin{macro}{\MT@define@opt@keys}
+%\todo{use \pkg{xkeyval} instead of \pkg{keyval}? or \pkg{kvoptions}?}
+%\begin{macro}{\MT@define@opt@key}
+% \begin{macrocode}
+\def\MT@define@opt@key#1#2{%
+ \define@key{MT@#1@c}{#2}[]{\MT@ifempty{##1}\relax{%
+ \MT@xdef@n{MT@#1@c@\MT@curr@set@name @#2}{##1}}}%
+}
+% \end{macrocode}
+%\end{macro}
% The options in the optional first argument.
% \begin{macrocode}
-\def\MT@define@opt@keys#1{%
+\MT@map@clist@c\MT@features{%
% \end{macrocode}
%\changes{v1.9a}{2005/11/21}{`\meta{file name}\texttt{/}\meta{line number}' as default list name}
% Use file name and line number as the list name if the user didn't bother
% to invent one.
%\changes{v1.3}{2004/10/27}{fix: specifying \texttt{load} option does no
% longer require to give a \texttt{name}, too}
+%\changes{v2.2}{2007/01/28}{simplify key declarations}
% \begin{macrocode}
\define@key{MT@#1@c}{name}[]{%
\MT@ifempty{##1}{%
@@ -7624,24 +8464,50 @@ time will almost certainly lead to undesired results. Have your choice!}%
\define@key{MT@#1@c}{context}[]{\MT@ifempty{##1}\relax{\def\MT@extra@context{##1}}}%
}
% \end{macrocode}
-%\end{macro}
-%\begin{macro}{\MT@define@opt@key}
+% Automatically enable font copying if we find an expansion context.
+% After the preamble, check whether font copying is enabled.
+% For older \pdftex\ versions, disallow.
% \begin{macrocode}
-\def\MT@define@opt@key#1#2{%
- \define@key{MT@#1@c}{#2}[]{\MT@ifempty{##1}\relax{%
- \MT@xdef@n{MT@#1@c@\MT@curr@set@name @#2}{##1}}}%
+\MT@requires@pdftex7{
+ \define@key{MT@ex@c}{context}[]{\MT@ifempty{#1}\relax{%
+ \MT@glet\MT@copy@font\MT@copy@font@
+ \def\MT@extra@context{#1}}%
+ }
+ \MT@addto@setup{%
+ \define@key{MT@ex@c}{context}[]{%
+ \ifx\MT@copy@font\MT@copy@font@
+ \MT@ifempty{#1}\relax{\def\MT@extra@context{#1}}%
+ \else
+ \MT@error{\MT@MT\space isn't set up for expansion contexts.\MessageBreak
+ Ignoring `context' key\on@line}%
+ {Either move the settings inside the preamble,\MessageBreak
+ or load the package with the `copyfonts' option.}%
+ \fi
+ }
+ }
+}{
+ \define@key{MT@ex@c}{context}[]{%
+ \MT@error{Expansion contexts only work with pdftex 1.40.4\MessageBreak
+ or later. Ignoring `context' key\on@line}%
+ {Upgrade pdftex.}%
+ }
}
% \end{macrocode}
-%\end{macro}
+%\begin{macro}{\MT@warn@nodim}
% \begin{macrocode}
-\MT@map@clist@c\MT@features{\MT@define@opt@keys{#1}}
+\def\MT@warn@nodim#1{%
+ \MT@warning{`\@tempa' is not a dimension.\MessageBreak
+ Ignoring it and setting values relative to\MessageBreak #1}%
+}
% \end{macrocode}
-% Protrusion codes may be relative to character width, or to any dimension.
+%\end{macro}
%\changes{v1.8}{2005/04/14}{\cs{SetProtrusion}: new key: \texttt{unit}}
%\changes{v1.9}{2005/09/28}{\cs{SetProtrusion}: value `\texttt{relative}' renamed
% to `\texttt{character}' for key \texttt{unit}}
%\changes{v2.0}{2006/09/30}{option `\opt{unit}', \cs{SetProtrusion}:
% deprecate value `\texttt{relative}' completely}
+% Protrusion codes may be relative to character width, or to any dimension.
+%\todo{new key for unit: dimen (for kerning, especially)}
% \begin{macrocode}
\define@key{MT@pr@c}{unit}[character]{%
\global\MT@let@nc{MT@pr@c@\MT@curr@set@name @unit}\@empty
@@ -7651,13 +8517,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Test whether it's a dimension, but do not translate it into its final
% form here, since it may be font-specific.
% \begin{macrocode}
- \MT@ifdimen\@tempa{%
- \global\MT@let@nc{MT@pr@c@\MT@curr@set@name @unit}\@tempa
- }{%
- \MT@warning{`\@tempa' is not a dimension.\MessageBreak
- Ignoring it and setting values relative to\MessageBreak
- character widths}%
- }%
+ \MT@ifdimen\@tempa
+ {\global\MT@let@nc{MT@pr@c@\MT@curr@set@name @unit}\@tempa}%
+ {\MT@warn@nodim{character widths}}%
}%
}
% \end{macrocode}
@@ -7666,47 +8528,32 @@ time will almost certainly lead to undesired results. Have your choice!}%
\define@key{MT@tr@c}{unit}[1em]{%
\global\MT@let@nc{MT@tr@c@\MT@curr@set@name @unit}\@empty
\def\@tempa{#1}%
- \MT@ifdimen\@tempa{%
- \global\MT@let@nc{MT@tr@c@\MT@curr@set@name @unit}\@tempa
- }{%
- \MT@warning{`\@tempa' is not a dimension.\MessageBreak
- Ignoring it and setting values relative to\MessageBreak
- 1em}%
- \MT@gdef@n{MT@tr@c@\MT@curr@set@name @unit}{1em}%
- }%
+ \MT@ifdimen\@tempa
+ {\global\MT@let@nc{MT@tr@c@\MT@curr@set@name @unit}\@tempa}%
+ {\MT@warn@nodim{1em}%
+ \MT@gdef@n{MT@tr@c@\MT@curr@set@name @unit}{1em}}%
}
% \end{macrocode}
-%\begin{macro}{\MT@define@key@unit}
% Spacing and kerning codes may additionally be relative to space dimensions.
% \begin{macrocode}
-\def\MT@define@key@unit#1{%
+\MT@map@clist@n{sp,kn}{%
\define@key{MT@#1@c}{unit}[space]{%
\global\MT@let@nc{MT@#1@c@\MT@curr@set@name @unit}\@empty
\def\@tempa{##1}%
\MT@ifstreq\@tempa{character}\relax{%
\global\MT@let@nc{MT@#1@c@\MT@curr@set@name @unit}\m@ne
\MT@ifstreq\@tempa{space}\relax{%
- \MT@ifdimen\@tempa{%
- \global\MT@let@nc{MT@#1@c@\MT@curr@set@name @unit}\@tempa
- }{%
- \MT@warning{`\@tempa' is not a dimension.\MessageBreak
- Ignoring it and setting values relative to\MessageBreak
- width of space}%
- }%
+ \MT@ifdimen\@tempa
+ {\global\MT@let@nc{MT@#1@c@\MT@curr@set@name @unit}\@tempa}%
+ {\MT@warn@nodim{width of space}}%
}%
}%
}%
}
% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@define@key@unit{sp}
-\MT@define@key@unit{kn}
-% \end{macrocode}
-%\begin{macro}{\MT@define@ex@opt@key}
% The first argument to \cs{SetExpansion} accepts some more options.
% \begin{macrocode}
-\def\MT@define@ex@opt@key#1{%
+\MT@map@clist@n{stretch,shrink,step}{%
\define@key{MT@ex@c}{#1}[]{%
\MT@ifempty{##1}\relax{%
\MT@ifint{##1}{%
@@ -7722,21 +8569,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}%
}
-% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@define@ex@opt@key{stretch}
-\MT@define@ex@opt@key{shrink}
-\MT@define@ex@opt@key{step}
\define@key{MT@ex@c}{auto}[true]{%
\def\@tempa{#1}%
\csname if\@tempa\endcsname
% \end{macrocode}
% Don't use |autoexpand| for \pdftex\ version older than 1.20.
-%\changes{v1.7}{2005/03/07}{\cs{SetExpansion}: bug fix: remove
-% space after \texttt{autoexpand}}
-%\changes{v1.7}{2005/03/07}{\cs{SetExpansion}: don't allow automatic
-% expansion for old \pdftex\ versions}
+%\changes{v1.7}{2005/03/07}{fix: remove space after \texttt{autoexpand}}
+%\changes{v1.7}{2005/03/07}{don't allow automatic expansion for old \pdftex\ versions}
% \begin{macrocode}
\MT@requires@pdftex4{%
\MT@gdef@n{MT@ex@c@\MT@curr@set@name @auto}{autoexpand}%
@@ -7750,6 +8589,20 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
}
% \end{macrocode}
+% Tracking: Interword spacing.
+% The variant with space in case \cs{SetTracking} is called inside an argument
+% (\eg, to \cmd\IfFileExists).
+% \begin{macrocode}
+\MT@define@opt@key{tr}{spacing}
+\MT@define@opt@key{tr}{outerspacing}
+\define@key{MT@tr@c}{outer spacing}[]{\setkeys{MT@tr@c}{outerspacing={#1}}}
+% \end{macrocode}
+% Which ligatures should be disabled?
+% \begin{macrocode}
+\define@key{MT@tr@c}{noligatures}[]%
+ {\MT@xdef@n{MT@tr@c@\MT@curr@set@name @noligatures}{#1}}
+\define@key{MT@tr@c}{no ligatures}[]{\setkeys{MT@tr@c}{noligatures={#1}}}
+% \end{macrocode}
%
%\subsubsection{Character Inheritance}
%
@@ -7827,7 +8680,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
% Parse the second argument. \cs{DeclareCharacterInheritance} may also be set
% up for various combinations.
-%\changes{v1.2}{2004/09/29}{check whether only one encoding specified}
% \begin{macrocode}
\define@key{MT@inh}{encoding}[]{%
\def\MT@val{#1}%
@@ -7837,6 +8689,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\begin{macro}{\MT@encoding@check}
+%\changes{v1.2}{2004/09/29}{check whether only one encoding specified}
% But we only allow \emph{one} encoding.
% \begin{macrocode}
\def\MT@encoding@check#1,#2\@nil{%
@@ -7893,10 +8746,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
\fi
}%
-%<*debug>
- \MT@dinfo@nl{2}{children of #1 (\MT@val):
- \@nameuse{MT@inh@\MT@listname @\MT@val @}}%
-%</debug>
+%<debug>\MT@dinfo@nl{2}{children of #1 (\MT@val):
+%<debug> \@nameuse{MT@inh@\MT@listname @\MT@val @}}%
\fi
\fi
}
@@ -8012,18 +8863,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\changes{v1.8}{2005/04/20}{add ranges to the beginning of the lists}
% \begin{macrocode}
\MT@ifdefined@n@T{MT@\MT@permutelist @\@tempa\MT@extra@context @sizes}{%
- \MT@map@tlist@c
- \MT@tempsize
- \MT@check@rlist
+ \MT@map@tlist@c\MT@tempsize\MT@check@rlist
}%
\expandafter\MT@xaddb
\csname MT@\MT@permutelist @\@tempa\MT@extra@context @sizes\endcsname
\MT@tempsize
-%<*debug>
- \MT@dinfo@nl{1}{initialising: use list for font \@tempa,\MessageBreak
- sizes: \csname MT@\MT@permutelist @\@tempa\MT@extra@context
- @sizes\endcsname}%
-%</debug>
+%<debug>\MT@dinfo@nl{1}{initialising: use list for font \@tempa,\MessageBreak
+%<debug> sizes: \csname MT@\MT@permutelist @\@tempa\MT@extra@context
+%<debug> @sizes\endcsname}%
}{%
% \end{macrocode}
% Only one list can apply to a given combination.
@@ -8034,11 +8881,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
`\@nameuse{MT@\MT@permutelist @\@tempa\MT@extra@context}'
for font `\@tempa'}%
}%
-%<*debug>
- \MT@dinfo@nl{1}{initialising: use list for font \@tempa
- \ifx\MT@extra@context\@empty\else\MessageBreak
- (context: \MT@extra@context)\fi}%
-%</debug>
+%<debug>\MT@dinfo@nl{1}{initialising: use list for font \@tempa
+%<debug> \ifx\MT@extra@context\@empty\else\MessageBreak
+%<debug> (context: \MT@extra@context)\fi}%
}%
\MT@xdef@n{MT@\MT@permutelist @\@tempa\MT@extra@context}%
{\csname MT@\MT@permutelist @name\endcsname}%
@@ -8174,12 +9019,43 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\end{macro}
%\end{macro}
%\end{macro}
-%\begin{macro}{\MT@define@option}
+%\begin{macro}{\MT@optwarn@admissible}
+% Some warnings.
+% \begin{macrocode}
+\def\MT@optwarn@admissible#1#2{%
+ \MT@warning@nl{`#1' is not an admissible value for option\MessageBreak
+ `#2'. Assuming `false'}%
+}
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@optwarn@nan}
+% \begin{macrocode}
+%</package>
+\def\MT@optwarn@nan#1#2{%
+ \MT@warning@nl{Value `#1' for option `#2' is not a\MessageBreak number.
+ Using default value of \number\@nameuse{MT@#2@default}}%
+}
+%<*package>
+% \end{macrocode}
+%\end{macro}
+%\begin{macro}{\MT@opt@def@set}
+% \begin{macrocode}
+\def\MT@opt@def@set#1{%
+ \MT@ifdefined@n@TF{MT@\@tempb @set@@\MT@val}{%
+ \MT@xdef@n{MT@\@tempb @setname}{\MT@val}%
+ }{%
+ \MT@xdef@n{MT@\@tempb @setname}{\@nameuse{MT@default@\@tempb @set}}%
+ \MT@warning@nl{The #1 set `\MT@val' is undeclared.\MessageBreak
+ Using set `\@nameuse{MT@\@tempb @setname}' instead}%
+ }%
+}
+% \end{macrocode}
+%\end{macro}
% \opt{expansion} and \opt{protrusion} may be |true|, |false|, |compatibility|,
% |nocompatibility| and/or a \meta{set name}.
%\changes{v1.9}{2005/10/06}{fix: use \texttt{true} as the default value}
% \begin{macrocode}
-\def\MT@define@option#1{%
+\MT@map@clist@n{protrusion,expansion}{%
\define@key{MT}{#1}[true]{%
\csname MT@opt@#1true\endcsname
\MT@map@clist@n{##1}{%
@@ -8201,15 +9077,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
% If everything failed, it should be a set name.
% \begin{macrocode}
- \MT@ifdefined@n@TF{MT@\@tempb @set@@\MT@val}{%
- \MT@xdef@n{MT@\@tempb @setname}{\MT@val}%
- }{%
- \MT@xdef@n{MT@\@tempb @setname}%
- {\@nameuse{MT@default@\@tempb @set}}%
- \MT@warning@nl{%
- The #1 set `\MT@val' is undeclared.\MessageBreak
- Using set `\@nameuse{MT@\@tempb @setname}' instead}%
- }%
+ \MT@opt@def@set{#1}%
}%
}%
}%
@@ -8219,45 +9087,30 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}
% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@define@option{protrusion}
-\MT@define@option{expansion}
-% \end{macrocode}
% \opt{activate} is a shortcut for \opt{protrusion} and \opt{expansion}.
%\changes{v1.9e}{2006/07/18}{fix: default value for \opt{activate}: \texttt{true}}
%\todo{add \opt{spacing} to \opt{activate}, when the feature has stabilised in \pdftex?}
% \begin{macrocode}
\define@key{MT}{activate}[true]{%
- \setkeys{MT}{protrusion={#1}}%
- \setkeys{MT}{expansion={#1}}%
+ \setkeys{MT}{protrusion={#1}}%
+ \setkeys{MT}{expansion={#1}}%
}
% \end{macrocode}
-%\begin{macro}{\MT@define@option@}
% \opt{spacing}, \opt{kerning} and \opt{tracking} do not have a compatibility level.
% \begin{macrocode}
-\def\MT@define@option@#1{%
+\MT@map@clist@n{spacing,kerning,tracking}{%
\define@key{MT}{#1}[true]{%
- \csname MT@opt@#1true\endcsname
\MT@map@clist@n{##1}{%
\KV@@sp@def\MT@val{####1}%
\MT@ifempty\MT@val\relax{%
\csname MT@#1true\endcsname
- \edef\@tempb{\csname MT@rbba@#1\endcsname}%
\MT@ifstreq\MT@val{true}\relax
{%
\MT@ifstreq\MT@val{false}{%
\csname MT@#1false\endcsname
}{%
- \MT@ifdefined@n@TF{MT@\@tempb @set@@\MT@val}{%
- \MT@xdef@n{MT@\@tempb @setname}{\MT@val}%
- }{%
- \MT@xdef@n{MT@\@tempb @setname}%
- {\@nameuse{MT@default@\@tempb @set}}%
- \MT@warning@nl{%
- The #1 set `\MT@val' is undeclared.\MessageBreak
- Using set `\@nameuse{MT@\@tempb @setname}' instead}%
- }%
+ \edef\@tempb{\csname MT@rbba@#1\endcsname}%
+ \MT@opt@def@set{#1}%
}%
}%
}%
@@ -8265,17 +9118,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}
% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@define@option@{spacing}
-\MT@define@option@{kerning}
-\MT@define@option@{tracking}
-% \end{macrocode}
%\changes{v1.5}{2004/12/02}{new option: \opt{selected}, by default false
% (suggested by \contributor \thanh{} <hanthethanh\at gmx.net>)}
% ^^A private mail, 30/11/2004
-%\changes{v2.0}{2005/10/04}{new option: \opt{babel}, by default false
-% (language-dependent setup suggested by \contributor Ulrich Dirr <ud\at art-satz.de>) (beta:1)}
+%\changes{v2.0}{2005/10/04}{(beta:1) new option: \opt{babel}, by default false
+% (language-dependent setup suggested by \contributor Ulrich Dirr <ud\at art-satz.de>)}
%\begin{macro}{\MT@def@bool@opt}
% The |true|/|false| options:
% \opt{draft}, \opt{final} (may be inherited from the class options),
@@ -8283,18 +9130,15 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \opt{selected},
% \opt{babel},
% \opt{DVIoutput},
-% \opt{defersetup}.
+% \opt{defersetup},
+% \opt{copyfonts}.
% \begin{macrocode}
\def\MT@def@bool@opt#1#2{%
- \define@key{MT}{#1}[]{%
- \MT@ifempty{##1}%
- {\def\@tempa{true}}%
- {\def\@tempa{##1}}%
+ \define@key{MT}{#1}[true]{%
+ \def\@tempa{##1}%
\MT@ifstreq\@tempa{true}\relax{%
\MT@ifstreq\@tempa{false}\relax{%
- \MT@warning@nl{%
- `##1' is not an admissible value for option\MessageBreak
- `#1'. Assuming `false'}%
+ \MT@optwarn@admissible{##1}{#1}%
\def\@tempa{false}%
}%
}%
@@ -8303,14 +9147,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\MT@def@simple@bool@opt}
% Boolean options that only set the switch.
% \begin{macrocode}
-\def\MT@def@simple@bool@opt#1{\MT@def@bool@opt{#1}{\csname MT@#1\@tempa\endcsname}}
-% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-\MT@map@tlist@n{{draft}{auto}{selected}{babel}}\MT@def@simple@bool@opt
+\MT@map@clist@n{draft,selected,babel}{%
+ \MT@def@bool@opt{#1}{\csname MT@#1\@tempa\endcsname}}
+\MT@def@bool@opt{auto}{\csname MT@auto\@tempa\endcsname \MT@opt@autotrue}
% \end{macrocode}
% The \opt{DVIoutput} option will change \cmd\pdfoutput\ immediately to minimise
% the risk of confusing other packages.
@@ -8345,6 +9186,30 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
}
% \end{macrocode}
+% \opt{copyfonts} will copy all fonts before setting them up. This allows
+% expansion with different parameters.
+%\changes{v2.2}{2007/07/03}{new option: \opt{copyfonts}}
+% This options is also \emph{undocumented} in the hope that we can always find
+% out automatically whether it's required.
+% \begin{macrocode}
+\MT@requires@pdftex7{
+ \MT@def@bool@opt{copyfonts}{%
+ \csname if\@tempa\endcsname
+ \MT@glet\MT@copy@font\MT@copy@font@
+ \else
+ \MT@glet\MT@copy@font\relax
+ \fi
+ }
+}{
+ \MT@def@bool@opt{copyfonts}{%
+ \csname if\@tempa\endcsname
+ \MT@error{The pdftex version you are using is too old\MessageBreak
+ to use the `copyfonts' option}
+ {Please upgrade pdftex.}%
+ \fi
+ }
+}
+% \end{macrocode}
% \opt{final} is the opposite to \opt{draft}.
%\changes{v1.4a}{2004/11/16}{new option: \opt{final}}
% \begin{macrocode}
@@ -8358,11 +9223,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
% For \opt{verbose} output, we simply redefine \cs{MT@vinfo}.
% \begin{macrocode}
-\define@key{MT}{verbose}[]{%
+\define@key{MT}{verbose}[true]{%
\let\MT@vinfo\MT@info@nl
- \MT@ifempty{#1}%
- {\def\@tempa{true}}%
- {\def\@tempa{#1}}%
+ \def\@tempa{#1}%
\MT@ifstreq\@tempa{true}\relax{%
% \end{macrocode}
%\changes{v1.7}{2005/03/16}{new value for \opt{verbose} option: \texttt{errors}}
@@ -8373,11 +9236,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
\let\MT@warning@nl\MT@warn@err
}{%
\let\MT@vinfo\@gobble
- \MT@ifstreq\@tempa{false}\relax{%
- \MT@warning@nl{%
- `#1' is not an admissible value for option\MessageBreak
- `verbose'. Assuming `false'}%
- }%
+ \MT@ifstreq\@tempa{false}\relax
+ {\MT@optwarn@admissible{#1}{verbose}}%
}%
}%
}
@@ -8386,9 +9246,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
% (suggested by \contributor \thanh{} <hanthethanh\at gmx.net>)}
% ^^A private mail, 30/11/2004
%\changes{v1.6}{2004/12/18}{new option: \opt{factor}, by default 1000}
-%\changes{v2.0}{2005/09/21}{new option: \opt{letterspace}, by default 100 (beta:1)}
+%\changes{v2.0}{2005/09/21}{(beta:1) new option: \opt{letterspace}, by default 100}
%\changes{v2.0}{2007/01/05}{option `\texttt{letterspacing}' renamed to `\opt{letterspace}'}
-%\begin{macro}{\MT@def@num@opt}
% Options with numerical keys:
% \opt{factor},
% \opt{stretch},
@@ -8397,60 +9256,44 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \opt{letterspace}.
% \begin{macrocode}
%</package>
-\def\MT@def@num@opt#1{%
- \define@key{MT}{#1}[]{%
- \MT@ifempty{##1}%
- {\MT@let@cn\@tempa{MT@#1@default}}%
- {\def\@tempa{##1 }}%
+\MT@map@clist@n{%
+%<package> stretch,shrink,step,%
+ letterspace}{%
+ \define@key{MT}{#1}[\csname MT@#1@default\endcsname]{%
+ \def\@tempa{##1 }%
% \end{macrocode}
% No nonsense in \cs{MT@factor} et al.?
%\changes{v1.6}{2005/01/06}{test whether numeric options receive a number}
% A space terminates the number.
% \begin{macrocode}
- \MT@ifint\@tempa{%
- \MT@edef@n{MT@#1}{\@tempa}%
- }{\MT@warning@nl{%
- Value `##1' for option `#1' is not a number.\MessageBreak
- Using default value of \number\@nameuse{MT@#1@default}}%
- }%
+ \MT@ifint\@tempa
+ {\MT@edef@n{MT@#1}{\@tempa}}%
+ {\MT@optwarn@nan{##1}{#1}}%
}%
}
-% \end{macrocode}
-%\end{macro}
-% \begin{macrocode}
-%<package>\MT@map@tlist@n{{stretch}{shrink}{step}{letterspace}}\MT@def@num@opt
-%<letterspace>\MT@def@num@opt{letterspace}
%<*package>
% \end{macrocode}
% \opt{factor} will define the protrusion factor only.
% \begin{macrocode}
-\define@key{MT}{factor}[]{%
- \MT@ifempty{#1}%
- {\let\@tempa\MT@factor@default}%
- {\def\@tempa{#1 }}%
- \MT@ifint\@tempa{%
- \edef\MT@pr@factor{\@tempa}%
- }{\MT@warning@nl{%
- Value `#1' for option `factor' is not a number.\MessageBreak
- Using default value of \number\MT@factor@default}%
- }%
+\define@key{MT}{factor}[\MT@factor@default]{%
+ \def\@tempa{#1 }%
+ \MT@ifint\@tempa
+ {\edef\MT@pr@factor{\@tempa}}
+ {\MT@optwarn@nan{#1}{factor}}%
}
% \end{macrocode}
% Unit for protrusion codes.
%\changes{v1.8}{2005/04/14}{new option: \opt{unit}, by default \texttt{character}}
%\changes{v1.9}{2005/09/28}{option \opt{unit}: rename value \texttt{relative} to \texttt{character}}
% \begin{macrocode}
-\define@key{MT}{unit}[]{%
- \MT@ifempty{#1}%
- {\def\@tempa{character}}%
- {\KV@@sp@def\@tempa{#1}}%
+\define@key{MT}{unit}[character]{%
+ \def\@tempa{#1}%
\MT@ifstreq\@tempa{character}\relax{%
- \MT@ifdimen\@tempa{%
- \let\MT@pr@unit\@tempa
- }{%
- \MT@warning@nl{`\@tempa' is not a dimension. Ignoring it and\MessageBreak
- setting values relative to character widths}%
- }%
+ \MT@ifdimen\@tempa
+ {\let\MT@pr@unit\@tempa}%
+ {\MT@warning@nl{`\@tempa' is not a dimension.\MessageBreak
+ Ignoring it and setting values relative to\MessageBreak
+ character widths}}%
}%
}
% \end{macrocode}
@@ -8468,7 +9311,6 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Also, we only enable expansion by default if \pdftex\ can expand the fonts
% automatically.
%\changes{v1.6}{2004/12/23}{defaults: turn off expansion for old \pdftex\ versions}
-%\todo{should \opt{spacing} be enabled by default?}
% \begin{macrocode}
\MT@requires@pdftex4{
\MT@expansiontrue
@@ -8489,7 +9331,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\def\MT@get@config#1config=#2,#3\@nil{%
\MT@ifempty{#2}%
{\def\MT@config@file{\MT@MT.cfg}}%
- {\KV@@sp@def\MT@config@file{#2.cfg}}%
+ {\def\MT@config@file{#2.cfg}}%
}
\expandafter\expandafter\expandafter\MT@get@config
\csname opt@\@currname.\@currext\endcsname,config=,\@nil
@@ -8534,7 +9376,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
}{%
\global\MT@let@nn{MT@#1@setname}{MT@default@#1@set}%
\MT@info@nl{Using default \@nameuse{MT@abbr@#1} set `\@nameuse{MT@#1@setname}'}%
- }
+ }%
}
% \end{macrocode}
%\end{macro}
@@ -8550,9 +9392,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
%
% This hook was needed in versions prior to 1.9a to overcome the situation that
% (1)~the \microtype\ package should be loaded after all font defaults have
-% been set up (hence, using \cmd\@ifpackageloaded\ in the font package has not
-% been viable), and (2)~checking \cmd\AtBeginDocument\ could be too late,
-% since fonts might already have been loaded, and consequently set up, in the
+% been set up (hence, using \cmd\@ifpackageloaded\ in the font package was not
+% viable), and (2)~checking \cmd\AtBeginDocument\ could be too late, since
+% fonts might already have been loaded, and consequently set up, in the
% preamble. With the new deferred setup, one could live without this command,
% however, it remains here since it's simpler than testing whether the package
% was loaded both in the preamble as well as at the beginning of the document
@@ -8597,10 +9439,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@addto@setup{\def\microtypesetup{\setkeys{MTX}}}
\def\MT@define@optionX#1#2{%
\define@key{MTX}{#1}[true]{%
- \KV@@sp@def\@tempb{#1}%
+ \edef\@tempb{\csname MT@rbba@#1\endcsname}%
\MT@map@clist@n{##1}{%
\KV@@sp@def\MT@val{####1}%
- \edef\@tempb{\csname MT@rbba@\@tempb\endcsname}%
\MT@ifempty\MT@val\relax{%
\@tempcnta=\m@ne
\MT@ifstreq\MT@val{true}{%
@@ -8609,7 +9450,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% has been disabled in the package options since fonts might already have been
% loaded and hence wouldn't be set up.
% \begin{macrocode}
- \MT@checksetup\@tempb{%
+ \MT@checksetup{#1}{%
\expandafter\@tempcnta=\csname MT@\@tempb @level\endcsname
\MT@info{Enabling #1
(level \number\csname MT@\@tempb @level\endcsname)}%
@@ -8620,20 +9461,19 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@info{Disabling #1}%
}{%
\MT@ifstreq\MT@val{compatibility}{%
- \MT@checksetup\@tempb{%
+ \MT@checksetup{#1}{%
\@tempcnta=\@ne
\MT@let@nc{MT@\@tempb @level}\@ne
\MT@info{Setting #1 to level 1}%
}%
}{%
\MT@ifstreq\MT@val{nocompatibility}{%
- \MT@checksetup\@tempb{%
+ \MT@checksetup{#1}{%
\@tempcnta=\tw@
\MT@let@nc{MT@\@tempb @level}\tw@
\MT@info{Setting #1 to level 2}%
}%
- }{%
- \MT@warning{%
+ }{\MT@warning{%
Value `\MT@val' for key `#1' not recognised.\MessageBreak
Use any of `true', `false', `compatibility' or\MessageBreak
`nocompatibility'}%
@@ -8655,12 +9495,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
% Test whether the feature wasn't disabled in the package options.
% \begin{macrocode}
\def\MT@checksetup#1{%
- \expandafter\csname ifMT@\csname MT@abbr@#1\endcsname\endcsname
+ \expandafter\csname ifMT@#1\endcsname
\expandafter\@firstofone
\else
- \MT@warning{%
- You cannot enable \@nameuse{MT@abbr@#1} if it was disabled\MessageBreak
- in the package options,}%
+ \MT@warning{You cannot enable #1 if it was disabled\MessageBreak
+ in the package options,}%
\expandafter\@gobble
\fi
}
@@ -8677,14 +9516,12 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@requires@pdftex6{
\def\MT@define@optionX@#1#2{%
\define@key{MTX}{#1}[true]{%
- \KV@@sp@def\@tempb{#1}%
\MT@map@clist@n{##1}{%
\KV@@sp@def\MT@val{####1}%
- \edef\@tempb{\csname MT@rbba@\@tempb\endcsname}%
\MT@ifempty\MT@val\relax{%
\@tempcnta=\m@ne
\MT@ifstreq\MT@val{true}{%
- \MT@checksetup\@tempb{%
+ \MT@checksetup{#1}{%
\@tempcnta=\@ne
\MT@info{Enabling #1}%
}%
@@ -8692,10 +9529,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@ifstreq\MT@val{false}{%
\@tempcnta=\z@
\MT@info{Disabling #1}%
- }{%
- \MT@warning{%
- Value `\MT@val' for key `#1' not recognised.\MessageBreak
- Use either `true' or `false'}%
+ }{\MT@warning{Value `\MT@val' for key `#1' not recognised.
+ \MessageBreak Use either `true' or `false'}%
}%
}%
\ifnum\@tempcnta>\m@ne
@@ -8708,8 +9543,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
%\end{macro}
% \begin{macrocode}
- \MT@define@optionX@{tracking}{\ifnum\@tempcnta=\z@
- \MT@trackingfalse\else\MT@trackingtrue\fi}
+ \MT@define@optionX@{tracking}{\ifnum\@tempcnta=\z@ \let\MT@tracking\relax\else
+ \let\MT@tracking\MT@tracking@\fi}
\MT@define@optionX@{spacing}{\pdfadjustinterwordglue\@tempcnta}
\MT@define@optionX@{kerning}{\pdfprependkern\@tempcnta
\pdfappendkern \@tempcnta}
@@ -8726,13 +9561,17 @@ time will almost certainly lead to undesired results. Have your choice!}%
\setkeys{MTX}{expansion={#1}}%
}
% \end{macrocode}
+%\begin{macro}{\MT@saved@setupfont}
% Disable everything -- may be used as a work-around in case setting up fonts
% doesn't work in certain environments. \emph{(Undocumented.)}
% \begin{macrocode}
\let\MT@saved@setupfont\MT@setupfont
+% \end{macrocode}
+%\end{macro}
+% \begin{macrocode}
\define@key{MTX}{disable}[]{%
\MT@info{Inactivate `\MT@MT' package}%
- \let\MT@setupfont\@gobble
+ \let\MT@setupfont\relax
}
\define@key{MTX}{enable}[]{%
\MT@info{Reactivate `\MT@MT' package}%
@@ -8763,8 +9602,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
}%
}%
\MT@temp
- \AtEndOfPackage{\let\@unprocessedoptions\relax}%
- \let\CurrentOption\@empty
+ \MT@clear@options
}
% \end{macrocode}
%\end{macro}
@@ -8785,25 +9623,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@warning@nl{`draft' option active.\MessageBreak
Disabling all micro-typographic extensions.\MessageBreak
This might lead to different line and page breaks}
- \MT@protrusionfalse
- \MT@expansionfalse
- \MT@trackingfalse
- \MT@spacingfalse
- \MT@kerningfalse
- \MT@babelfalse
\let\MT@setupfont\relax
- \def\DeclareMicrotypeSet#1#{\@gobbletwo}
- \renewcommand*\UseMicrotypeSet[2][]{}
- \renewcommand*\SetProtrusion[3][]{}
- \renewcommand*\SetExpansion[3][]{}
- \renewcommand*\SetTracking[3][]{}
- \renewcommand*\SetExtraSpacing[3][]{}
- \renewcommand*\SetExtraKerning[3][]{}
- \renewcommand*\DeclareCharacterInheritance[3][]{}
- \renewcommand*\DeclareMicrotypeAlias[2]{}
\renewcommand*\LoadMicrotypeFile[1]{}
\renewcommand*\microtypesetup[1]{}
\renewcommand*\microtypecontext[1]{}
+ \renewcommand*\lsstyle{}
\else
% \end{macrocode}
% For <DVI> output, the user must have explicitly passed the \opt{expansion}
@@ -8817,7 +9641,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\fi
% \end{macrocode}
% \pdftex\ can create <DVI> output, too. However, both the <DVI> viewer and
-% dvips need to find actual fonts. Therefore, expansion will only work if the
+% |dvips| need to find actual fonts. Therefore, expansion will only work if the
% fonts for different degrees of expansion are readily available.
%
%\changes{v1.4b}{2004/11/19}{new message if \cmd\pdfoutput\ is changed}
@@ -8942,13 +9766,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@autofalse
\def\MT@auto{1000 }
}
+ \else
% \end{macrocode}
% No automatic expansion.
% \begin{macrocode}
- \else
- \ifnum\MT@pdftex@no < 4
+ \MT@requires@pdftex4\relax{
\def\MT@auto{1000 }
- \fi
+ }
\fi
% \end{macrocode}
% Choose the appropriate macro for selected expansion.
@@ -8959,7 +9783,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\let\MT@set@ex@codes\MT@set@ex@codes@n
\fi
% \end{macrocode}
-% Filter out |stretch=0,shrink=0|, since it would result in an \pdftex\ error.
+% Filter out |stretch=0,shrink=0|, since it would result in a \pdftex\ error.
%\changes{v1.9}{2005/07/08}{disable expansion if both \opt{step} and \opt{shrink} are zero}
% \begin{macrocode}
\ifnum\MT@stretch=\z@
@@ -8974,12 +9798,32 @@ time will almost certainly lead to undesired results. Have your choice!}%
\ifMT@expansion
\edef\MT@active@features{\MT@active@features,ex}%
\pdfadjustspacing\MT@ex@level
- \MT@info@nl{\ifMT@auto\else Non-\fi Automatic font expansion enabled
+ \MT@info@nl{\ifMT@auto A\else Non-a\fi utomatic font expansion enabled
(level \number\MT@ex@level),\MessageBreak
stretch: \number\MT@stretch, shrink: \number\MT@shrink,
- step: \number\MT@step, \ifMT@selected\else non-\fi selected}
+ step: \number\MT@step, \ifMT@selected\else non-\fi selected%
+ \ifx\MT@copy@font\MT@copy@font@ .\MessageBreak
+ Set up for expansion contexts (using font copies)\fi}
+% \end{macrocode}
+%\changes{v2.2}{2007/01/28}{warning if \opt{stretch} or \opt{shrink} aren't multiples of \opt{step}}
+%\begin{macro}{\MT@check@step}
+% Check whether \opt{stretch} and \opt{shrink} are multiples of \opt{step}.
+% \begin{macrocode}
+ \def\MT@check@step#1{%
+ \@tempcnta=\csname MT@#1\endcsname
+ \divide\@tempcnta \MT@step
+ \multiply\@tempcnta \MT@step
+ \ifnum\@tempcnta=\csname MT@#1\endcsname\else
+ \MT@warning@nl{The #1 amount is not a multiple of step.\MessageBreak
+ The effective maximum #1 is \the\@tempcnta\space
+ (step \number\MT@step)}
+ \fi
+ }
+ \MT@check@step{stretch}
+ \MT@check@step{shrink}
\MT@check@active@set{ex}
% \end{macrocode}
+%\end{macro}
%\changes{v1.7}{2005/03/02}{modify \cmd\showhyphens}
% Inside \cmd\showhyphens, font expansion should be disabled.
% \begin{macrocode}
@@ -9005,15 +9849,22 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
\MT@requires@pdftex6{
%</package>
-\MT@addto@setup{%
+ \MT@addto@setup{%
%<*package>
% \end{macrocode}
% Tracking, spacing and kerning.
% \begin{macrocode}
\ifMT@tracking
- \edef\MT@active@features{\MT@active@features,tr}
- \MT@info@nl{Tracking enabled}
- \MT@check@active@set{tr}
+%<*lua>
+ \MT@requires@luatex{
+ \MT@warning@nl{Tracking doesn't currently work with luatex}
+ \let\MT@tracking\relax
+ }{
+%</lua>
+ \edef\MT@active@features{\MT@active@features,tr}
+ \MT@info@nl{Tracking enabled}
+ \MT@check@active@set{tr}
+%<lua> }
\else
\let\MT@tracking\relax
\MT@info@nl{No tracking}
@@ -9038,6 +9889,27 @@ time will almost certainly lead to undesired results. Have your choice!}%
\MT@info@nl{No adjustment of character kerning}
\fi
%</package>
+% \end{macrocode}
+%\begin{macro}{\MT@warn@tracking@DVI}
+%\changes{v2.2}{2007/02/11}{warning when letterspacing in DVI mode}
+% We issue a warning, when letterspacing in <DVI> mode, since it will probably
+% not work.
+% \begin{macrocode}
+ \ifnum\pdfoutput<\@ne
+ \def\MT@warn@tracking@DVI{%
+ \MT@warning@nl{%
+ You are using tracking/letterspacing in DVI mode.\MessageBreak
+ This will probably not work, unless the post-\MessageBreak
+ processing program (dvips, dvipdfm(x), ...) is able\MessageBreak
+ to create the virtual fonts on the fly}%
+ \MT@glet\MT@warn@tracking@DVI\relax
+ }
+ \else
+ \let\MT@warn@tracking@DVI\relax
+ \fi
+% \end{macrocode}
+%\end{macro}
+% \begin{macrocode}
\ifnum\MT@letterspace=\m@ne
\let\MT@letterspace\MT@letterspace@default
\else
@@ -9056,24 +9928,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
\else
\MT@info@nl{No tracking (pdftex too old)}
\fi
- \MT@trackingfalse
- \let\MT@tracking\relax
\ifMT@spacing
\MT@warning@nl{Adjustment of interword spacing only works with\MessageBreak
pdftex version 1.40 or newer. Switching it off}%
\else
\MT@info@nl{No adjustment of interword spacing (pdftex too old)}
\fi
- \MT@spacingfalse
- \let\MT@spacing\relax
\ifMT@kerning
\MT@warning@nl{Character kerning only works with\MessageBreak
pdftex version 1.40 or newer. Switching it off}%
\else
\MT@info@nl{No adjustment of character kerning (pdftex too old)}
\fi
- \MT@kerningfalse
- \let\MT@kerning\relax
}
}
% \end{macrocode}
@@ -9081,7 +9947,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% ignored with \cmd\pdfadjustinterwordglue\,|>|\,0. Why 1500? Because some
% packages redefine \cmd\frenchspacing. See the |c.t.t| thread
% `\cmd\frenchspacing\ with <AMS> packages and babel', started by Philipp
-% Lehman on August 16, 2005: \nolinkurl{<ddtbaj$rob$1@online.de>}.
+% Lehman on 16 August 2005: \nolinkurl{<ddtbaj$rob$1@online.de>}.
% \begin{macrocode}
\MT@requires@pdftex6{
\AtBeginDocument{%
@@ -9147,8 +10013,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
\shorthandoff{#2}}
}{
\def\MT@shorthandoff#1#2{%
- \MT@error{You must load the `babel' package before microtype}
- {Otherwise, I cannot switch off the active characters
+ \MT@error{You must load the `babel' package before \MT@MT}
+ {Otherwise, `\MT@MT' cannot switch off the active characters
for #1 babel.}}
}
% \end{macrocode}
@@ -9171,25 +10037,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
}
% \end{macrocode}
% Disable French \pkg{babel}'s active characters.
-%\changes{v2.0}{2006/10/10}{option `\opt{babel}': fix: switch off French
+%\changes{v2.0}{2006/10/10}{(beta:8) option `\opt{babel}': fix: switch off French
% \pkg{babel}'s active characters with \cmd\shorthandoff\
% instead of \cmd\NoAutoSpaceBeforeFDP\
-% (reported by \contributor Daniel Flipo <daniel.flipo\at univ-lille1.fr>) (beta:8)}
-% ^^A private mail, 2006/10/09
+% (reported by \contributor Daniel Flipo <daniel.flipo\at univ-lille1.fr>)}
+% ^^A private mail, 09/10/2006
% \begin{macrocode}
\ifMT@kerning
\MT@if@false
- \MT@with@babel@and{french} \MT@if@true
- \MT@with@babel@and{frenchb} \MT@if@true
- \MT@with@babel@and{francais}\MT@if@true
- \MT@with@babel@and{acadian} \MT@if@true
- \MT@with@babel@and{canadien}\MT@if@true
+ \MT@with@babel@and@T{french} \MT@if@true
+ \MT@with@babel@and@T{frenchb} \MT@if@true
+ \MT@with@babel@and@T{francais}\MT@if@true
+ \MT@with@babel@and@T{acadian} \MT@if@true
+ \MT@with@babel@and@T{canadien}\MT@if@true
\ifMT@if@\MT@shorthandoff{French}{;:!?}\fi
% \end{macrocode}
% Disable Turkish \pkg{babel}'s active characters.
-%\changes{v2.0}{2006/10/10}{option `\opt{babel}': disable Turkish \pkg{babel}'s active characters (beta:8)}
+%\changes{v2.0}{2006/10/10}{(beta:8) option `\opt{babel}': disable Turkish \pkg{babel}'s active characters}
% \begin{macrocode}
- \MT@with@babel@and{turkish}{\MT@shorthandoff{Turkish}{:!=}}
+ \MT@with@babel@and@T{turkish}{\MT@shorthandoff{Turkish}{:!=}}
\fi
% \end{macrocode}
% In case \pkg{babel} was loaded before \microtype:
@@ -9295,6 +10161,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \end{macrocode}
% The default sets.
+%\changes{v2.2}{2007/04/15}{default set for tracking: \texttt{smallcaps}}
% \begin{macrocode}
%%% -----------------------------------------------------------------------
%%% DEFAULT SETS
@@ -9303,22 +10170,34 @@ time will almost certainly lead to undesired results. Have your choice!}%
\DeclareMicrotypeSetDefault[expansion] {basictext}
\DeclareMicrotypeSetDefault[spacing] {basictext}
\DeclareMicrotypeSetDefault[kerning] {alltext}
-\DeclareMicrotypeSetDefault[tracking] {normalfont}
+\DeclareMicrotypeSetDefault[tracking] {smallcaps}
% \end{macrocode}
%
-%\subsection{Font Aliases}
+%\subsection{Font Variants and Aliases}
%
-% Fonts that are `the same'.
% \begin{macrocode}
%%% -----------------------------------------------------------------------
-%%% FONT ALIASES
+%%% FONT VARIANTS AND ALIASES
% \end{macrocode}
-% The Latin Modern fonts, the virtual fonts from the \pkg{ae} and \pkg{zefonts},
-% and the \pkg{eco} and \pkg{hfoldsty} packages (oldstyle numerals) all inherit
-% the (basic) settings from Computer Modern Roman. Some of them are in part
-% overwritten later.
+% These are the variants I happen to be using (expert encoding, oldstyle
+% numerals, swashes, alternative, display, inferior and superior numerals):
+% \begin{macrocode}
+\DeclareMicrotypeVariants{x,j,w,a,d,0,1}
+
+% \end{macrocode}
+% Other candidates: |2|~(proportional digits), |e|~(engraved), |f|~(Fraktur),
+% |g|~(small text), |h|~(shadow), |l|~(outline), |n|~(informal),
+% |p|~(ornaments), |r|~(roman), |s|~(sans serif), |t|~(typewriter).
+% I've omitted them since they seem hardly be used and/or they are actually
+% more than a variant, \ie, they shouldn't share a file.
+%
+%\bigskip\noindent
+% Fonts that are `the same': The Latin Modern fonts, the virtual fonts from the
+% \pkg{ae} and \pkg{zefonts}, and the \pkg{eco} and \pkg{hfoldsty} packages
+% (oldstyle numerals) all inherit the (basic) settings from Computer Modern
+% Roman. Some of them are in part overwritten later.
%\changes{v1.2}{2004/10/03}{declare \texttt{cmor} as an alias of \texttt{cmr}}
%\changes{v1.3}{2004/10/22}{declare \texttt{aer}, \texttt{zer} and \texttt{hfor}
% as an alias of \texttt{cmr}}
@@ -9333,14 +10212,20 @@ time will almost certainly lead to undesired results. Have your choice!}%
% settings respectively,
%\changes{v1.8}{2005/04/19}{declare \texttt{pxr} and \texttt{txr}
% as aliases of \texttt{ppl} resp. \texttt{ptm}}
-% also the \pkg{qfonts} package, which provides both font families.
-%\changes{v1.9}{2005/08/16}{declare \texttt{qpl} and \texttt{qtm} (\pkg{qfonts})
+% also the \TeX\ Gyre fonts Pagella and Termes (formerly: \pkg{qfonts}).
+%\changes{v1.9}{2005/08/16}{declare \texttt{qpl} and \texttt{qtm} (\pkg{qfonts}, \TeX\ Gyre)
% as aliases of \texttt{ppl} resp. \texttt{ptm}}
% \begin{macrocode}
\DeclareMicrotypeAlias{pxr} {ppl} % pxfonts
-\DeclareMicrotypeAlias{qpl} {ppl} % qfonts/QuasiPalatino
+\DeclareMicrotypeAlias{qpl} {ppl} % TeX Gyre Pagella (formerly: qfonts/QuasiPalatino)
+% \end{macrocode}
+% The `<FPL> Neu' fonts, a `re-implementation' of Palatino.
+%\changes{v2.2}{2007/05/27}{declare <FPL> Neu as an alias of Palatino}
+% \begin{macrocode}
+\DeclareMicrotypeAlias{fp9x}{pplx} % FPL Neu
+\DeclareMicrotypeAlias{fp9j}{pplj} % "
\DeclareMicrotypeAlias{txr} {ptm} % txfonts
-\DeclareMicrotypeAlias{qtm} {ptm} % qfonts/QuasiTimes
+\DeclareMicrotypeAlias{qtm} {ptm} % TeX Gyre Termes (formerly: qfonts/QuasiTimes)
% \end{macrocode}
%\todo{check Times variants}
% More Times variants, to be checked: |pns|, |mns| (TimesNewRomanPS); |mnt|
@@ -9352,7 +10237,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
% as aliases of \texttt{eur} resp. \texttt{eus} (\pkg{euler})}
% \begin{macrocode}
\DeclareMicrotypeAlias{zeur}{eur} % Euler VM
-\DeclareMicrotypeAlias{zeus}{eus}
+\DeclareMicrotypeAlias{zeus}{eus} % "
+% \end{macrocode}
+% MicroPress's Charter version (\pkg{chmath}).
+%\changes{v2.2}{2007/06/08}{declare \texttt{chr} (\pkg{chmath}) as an alias of Charter
+% (reported by \contributor Geoff Vallis <gkv\at Princeton.EDU>)}
+% ^^A private mail, 07/06/2007
+% \begin{macrocode}
+\DeclareMicrotypeAlias{chr} {bch} % CH Math
% \end{macrocode}
% The \pkg{mathdesign} package provides math fonts matching Bitstream Charter
%\changes{v1.9a}{2005/10/31}{declare \texttt{mdbch} (\pkg{mathdesign})
@@ -9362,6 +10254,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
\DeclareMicrotypeAlias{mdbch}{bch} % mathdesign/Charter
\DeclareMicrotypeAlias{mdugm}{ugm} % mathdesign/URW Garamond
% \end{macrocode}
+% <URW> Letter Gothic is similar enough to Bitstream Letter Gothic to share the
+% configuration.
+% \begin{macrocode}
+\DeclareMicrotypeAlias{ulg} {blg} % URW LetterGothic -> Bitstream LetterGothic12Pitch
+% \end{macrocode}
% Euro symbol fonts, to save some files.
% \begin{macrocode}
\DeclareMicrotypeAlias{zpeus} {zpeu} % Adobe Euro sans -> serif
@@ -9382,7 +10279,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{kerning=french, spacing=}
\DeclareMicrotypeBabelHook
- {english,UKenglish,british,american,USenglish}
+ {english,UKenglish,british,USenglish,american}
{kerning=, spacing=nonfrench}
\DeclareMicrotypeBabelHook
@@ -9397,14 +10294,16 @@ time will almost certainly lead to undesired results. Have your choice!}%
% All printable <ASCII> characters are allowed in the settings, with the
% following exceptions (on the left hand side, the replacements on the right):
%
-%\begin{tabular}{l@{\quad:\quad}l}
-% |\| & \cmd\textbackslash\\
-% |{| & \cmd\textbraceleft\\
-% |}| & \cmd\textbraceright\\
-% |^| & \cmd\textasciicircum\\
-% |%| & \cmd\%\\
+%\begin{flushleft}
+%\begin{tabular}{@{}l@{\quad:\quad}l}
+% |\| & \cmd\textbackslash \\
+% |{| & \cmd\textbraceleft \\
+% |}| & \cmd\textbraceright \\
+% |^| & \cmd\textasciicircum \\
+% |%| & \cmd\% \\
% |#| & \cmd\#
%\end{tabular}
+%\end{flushleft}
%
%\noindent
% Comma and equal sign must be guarded with braces (`|{,}|', `|{=}|') to keep
@@ -9420,6 +10319,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%
%\changes{v1.1}{2004/09/14}{remove 8-bit characters from the configuration files
% (suggested by \contributor Harald Harders <h.harders\at tu-bs.de>)}
+% ^^A private mail, 13/09/2004
% 8-bit characters are also admissible, provided they have been declared in the
% input encoding file. They should, however, only be used in private
% configuration files, where the proper input encoding is guaranteed, or else in
@@ -9451,7 +10351,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
i = {\i},
j = {\j},
O = {\O},
- o = {\o},
+ o = {\o}
}
% \end{macrocode}
@@ -9496,8 +10396,13 @@ time will almost certainly lead to undesired results. Have your choice!}%
Y = {\'Y,\"Y},
y = {\'y,\"y},
Z = {\'Z,\.Z,\v Z},
- z = {\'z,\.z,\v z},
- - = {127},
+ z = {\'z,\.z,\v z}
+% \end{macrocode}
+%\changes{v2.2}{2007/02/04}{remove `\texttt{-}' $\rightarrow$ `\texttt{127}'}
+% The `soft hyphen' often has reduced right side bearing so that it may already
+% be protruded, hence no inheritance.
+% \begin{macrocode}
+% - = {127},
}
% \end{macrocode}
@@ -9531,7 +10436,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
Y = {\'Y,\"Y},
y = {\'y,\"y},
Z = {\v Z},
- z = {\v z},
+ z = {\v z}
}
% \end{macrocode}
@@ -9562,7 +10467,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
S = {\'S},
s = {\'s},
Z = {\'Z,\.Z},
- z = {\'z,\.z},
+ z = {\'z,\.z}
}
% \end{macrocode}
@@ -9571,8 +10476,10 @@ time will almost certainly lead to undesired results. Have your choice!}%
%\changes{v1.9d}{2006/04/20}{add list for <QX> encoding (contributed by
% \contributor Maciej Eder <maciej_eder\at poczta.onet.pl>)}
% ^^A private mail, 19/04/2006
-% The Central European <QX> encoding. Ligatures: |009|~(`fk'), |012|~(`fi'), |013|~(`fl'),
-% |014|~(`ffi'), |015|~(`ffl'), \AE, \ae, \OE, \oe.
+% The Central European <QX> encoding.\footnote{
+% Thanks to \contributor Maciej Eder <maciej_eder\at poczta.onet.pl>.}
+% Ligatures: |009|~(`fk'), |012|~(`fi'), |013|~(`fl'), |014|~(`ffi'),
+% |015|~(`ffl'), \AE, \ae, \OE, \oe.
% \begin{macrocode}
\DeclareCharacterInheritance
{ encoding = QX }
@@ -9642,7 +10549,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
u = {\`u,\'u,\~u,\h u,\d u,\horn u,
\`\uhorn,\'\uhorn,\~\uhorn,\h\uhorn,\d\uhorn},
Y = {\`Y,\'Y,\~Y,\h Y,\d Y},
- y = {\`y,\'y,\~y,\h y,\d y},
+ y = {\`y,\'y,\~y,\h y,\d y}
}
%</m-t>
@@ -9678,15 +10585,33 @@ time will almost certainly lead to undesired results. Have your choice!}%
%</mvs>
% \end{macrocode}
%
+%\subsection{Tracking}
+%\GeneralChanges{Tracking}
+%
+%\changes{v2.2}{2007/02/23}{add ligatures that are to be disabled}
+% By default, we only disable the `f*' ligatures, for those fonts that have
+% any. Thus, ligatures and especially kerning for all other characters will be
+% retained.
+% \begin{macrocode}
+%<*m-t>
+%%% -----------------------------------------------------------------------
+%%% TRACKING/LETTERSPACING
+
+\SetTracking
+ [ no ligatures = {f} ]
+ { encoding = {OT1,T1,LY1,OT4,QX} }
+ {}
+
+% \end{macrocode}
+%
%\subsection{Font Expansion}
%\GeneralChanges{Expansion}
%
% These are \thanh's original expansion settings. They are used for all fonts
% (until somebody shows mercy and creates font-specific settings).
% \begin{macrocode}
-%<*m-t>
%%% -----------------------------------------------------------------------
-%%% EXPANSION SETTINGS
+%%% EXPANSION
\SetExpansion
[ name = default ]
@@ -9717,7 +10642,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
3 = 700,
6 = 700,
8 = 700,
- 9 = 700,
+ 9 = 700
}
% \end{macrocode}
@@ -9750,7 +10675,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
3 = 700,
6 = 700,
8 = 700,
- 9 = 700,
+ 9 = 700
}
%</m-t>
@@ -9769,7 +10694,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%
% \begin{macrocode}
%%% -----------------------------------------------------------------------
-%%% PROTRUSION SETTINGS
+%%% PROTRUSION
% \end{macrocode}
% For future historians, \thanh's original settings (from \file{protcode.tex},
@@ -9803,7 +10728,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% - = { ,700},
% \textendash = { ,300}, \textemdash = { ,200},
% \textquoteleft = {700, }, \textquoteright = { ,700},
-% \textquotedblleft = {500, }, \textquotedblright = { ,500},
+% \textquotedblleft = {500, }, \textquotedblright = { ,500}
% }
%\end{verbatim}
%
@@ -9834,6 +10759,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% (|pmnx|, |pmnj|),
%\changes{v1.1}{2004/09/14}{settings for Adobe Minion (contributed by
% \contributor Harald Harders <h.harders\at tu-bs.de>)}
+% ^^A private mail, 14/09/2004
% \begin{macrocode}
%<pmn> [ name = pmnj-default ]
% \end{macrocode}
@@ -9845,22 +10771,28 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
%<ptm> [ name = ptm-default ]
% \end{macrocode}
-% and <URW> Garamond (|ugm|).
+% <URW> Garamond (|ugm|)
%\changes{v1.9c}{2006/01/26}{settings for <URW> Garamond}
% \begin{macrocode}
%<ugm> [ name = ugm-default ]
+% \end{macrocode}
+% and Bitstream Letter Gothic (|blg|).
+%\changes{v2.2}{2007/03/03}{settings for Bitstream Letter Gothic}
+% \begin{macrocode}
+%<blg> [ name = blg-default ]
%<m-t> { encoding = OT1 }
%<cmr> { }
-%<bch|pad|pmn|ugm> { encoding = OT1,
+%<bch|blg|pad|pmn|ugm> { encoding = OT1,
%<ppl|ptm> { encoding = {OT1,OT4},
%<bch> family = bch }
+%<blg> family = blg }
%<pad> family = {pad,padx,padj} }
%<pmn> family = pmnj }
%<ppl> family = {ppl,pplx,pplj} }
%<ptm> family = {ptm,ptmx,ptmj} }
%<ugm> family = ugm }
{
-%<m-t|bch|cmr|pad|pmn|ppl|ptm> A = {50,50},
+%<m-t|bch|blg|cmr|pad|pmn|ppl|ptm> A = {50,50},
%<ugm> A = {50,100},
%<m-t|pad|ptm> \AE = {50, },
%<ugm> \AE = {150,50},
@@ -9873,47 +10805,61 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ugm> F = { ,70},
%<bch|pad|pmn> G = {50, },
%<ugm> G = {50,50},
+%<blg> I = {150,150},
%<m-t|cmr|pad|pmn|ppl|ptm|ugm> J = {50, },
-%<bch> J = {100, },
- K = { ,50},
+%<bch|blg> J = {100, },
+%<!blg> K = { ,50},
+%<blg> K = {50, },
%<m-t|bch|cmr|pad|pmn|ppl> L = { ,50},
+%<blg> L = { ,150},
%<ptm> L = { ,80},
%<ugm> L = { ,120},
%<bch|pad|pmn|ugm> O = {50,50},
%<pad|pmn> \OE = {50, },
%<ugm> \OE = {50,50},
+%<blg> P = { ,100},
%<ugm> P = { ,50},
%<bch|pad|pmn> Q = {50,70},
%<ugm> Q = {50,50},
%<bch> R = { ,50},
%<ugm> R = { ,70},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> T = {50,50},
+%<blg> T = {100,100},
%<ugm> T = {70,70},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> V = {50,50},
-%<ugm> V = {70,70},
+%<blg|ugm> V = {70,70},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> W = {50,50},
%<ugm> W = {70,70},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> X = {50,50},
%<ugm> X = {50,70},
%<m-t|bch|cmr|pad|pmn|ppl> Y = {50,50},
-%<ptm|ugm> Y = {80,80},
+%<blg|ptm|ugm> Y = {80,80},
%<ugm> Z = {50,50},
+%<blg> f = {150,100},
+%<blg> i = {150,150},
+%<blg> j = {100,100},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> k = { ,50},
%<ugm> k = { ,70},
+%<blg> l = {150,150},
%<pmn> l = { ,-50},
%<pad|ppl> p = {50,50},
%<ugm> p = { ,50},
%<pad|ppl> q = {50, },
- r = { ,50},
+%<!blg> r = { ,50},
+%<blg> r = {100, 80},
%<cmr|pad|pmn> t = { ,70},
%<bch> t = { ,50},
+%<blg> t = {150, 80},
%<ugm> t = { ,100},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> v = {50,50},
+%<blg> v = {100,100},
%<ugm> v = {50,70},
%<m-t|bch|cmr|pad|pmn|ppl|ptm> w = {50,50},
%<ugm> w = {50,70},
- x = {50,50},
+%<!blg> x = {50,50},
+%<blg> x = {100,100},
%<m-t|bch|pad|pmn> y = { ,50},
+%<blg> y = { 50,100},
%<cmr|ppl|ptm> y = {50,70},
%<ugm> y = { ,70},
% \end{macrocode}
@@ -9923,15 +10869,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
%<cmr> 0 = { ,50},
%<m-t> 1 = {50,50},
-%<bch|pad|ptm|ugm> 1 = {150,150},
+%<bch|blg|pad|ptm|ugm> 1 = {150,150},
%<cmr> 1 = {100,200},
%<pmn> 1 = { ,50},
%<ppl> 1 = {100,100},
%<bch|cmr|pad|ugm> 2 = {50,50},
-%<cmr|pad|ugm> 3 = {50,50},
+%<blg> 2 = { ,100},
%<bch|pmn> 3 = {50, },
+%<cmr|pad|ugm> 3 = {50,50},
+%<blg> 3 = {100, },
%<m-t|pad> 4 = {50,50},
%<bch> 4 = {100,50},
+%<blg> 4 = {100, },
%<cmr|ugm> 4 = {70,70},
%<pmn> 4 = {50, },
%<ptm> 4 = {70, },
@@ -9942,6 +10891,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<pad> 6 = {50,50},
%<m-t> 7 = {50,50},
%<bch|pad|pmn|ugm> 7 = {50,80},
+%<blg> 7 = {100,100},
%<cmr|ptm> 7 = {50,100},
%<ppl> 7 = { ,50},
%<cmr> 8 = { ,50},
@@ -9949,19 +10899,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> 9 = { ,50},
%<m-t|cmr|pad|pmn|ppl|ptm|ugm> . = { ,700},
%<bch> . = { ,600},
- {,}= { ,500},
+%<blg> . = {400,500},
+%<!blg> {,}= { ,500},
+%<blg> {,}= {300,400},
%<m-t|cmr|pad|pmn|ppl|ptm|ugm> : = { ,500},
%<bch> : = { ,400},
+%<blg> : = {300,400},
%<m-t|bch|pad|pmn|ptm> ; = { ,300},
+%<blg> ; = {200,300},
%<cmr|ppl> ; = { ,500},
%<ugm> ; = { ,400},
- ! = { ,100},
+%<!blg> ! = { ,100},
+%<blg> ! = {200,200},
%<m-t|pad|pmn|ptm> ? = { ,100},
%<bch|cmr|ppl|ugm> ? = { ,200},
+%<blg> ? = {150,150},
%<pmn> " = {300,300},
%<m-t|bch|cmr|pad|pmn|ppl> @ = {50,50},
%<ptm> @ = {100,100},
-%<m-t|bch|cmr|pad|pmn|ppl|ptm> ~ = {200,250},
+%<m-t|bch|blg|cmr|pad|pmn|ppl|ptm> ~ = {200,250},
%<ugm> ~ = {300,350},
%<pad|ppl|ptm> & = {50,100},
%<ugm> & = { ,100},
@@ -9969,32 +10925,41 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch> \% = { ,50},
%<ppl|ptm> \% = {100,100},
%<ugm> \% = {50,100},
+%<blg> \# = {100,100},
%<m-t|ppl|ptm|ugm> * = {200,200},
%<bch|pmn> * = {200,300},
+%<blg> * = {150,200},
%<cmr|pad> * = {300,300},
%<m-t|cmr|ppl|ptm> + = {250,250},
%<bch> + = {150,250},
%<pad> + = {300,300},
-%<pmn> + = {150,200},
+%<blg|pmn> + = {150,200},
%<ugm> + = {250,300},
-%<ugm> {=}= {200,200},
+%<blg|ugm> {=}= {200,200},
%<m-t|pad|pmn|ptm> ( = {100, }, ) = { ,200},
%<bch|ugm> ( = {200, }, ) = { ,200},
+%<blg> ( = {300, }, ) = { ,300},
%<cmr|ppl> ( = {100, }, ) = { ,300},
%<bch|pmn> [ = {100, }, ] = { ,100},
+%<blg> [ = {300,100}, ] = { ,300},
% \end{macrocode}
%\changes{v1.7}{2005/03/15}{fix: remove \textbackslash\ from <OT1>,
% add \cmd\textbackslash\ to <T1> encoding}
% \begin{macrocode}
%<m-t|pad|pmn|ptm> / = {100,200},
%<bch> / = { ,200},
+%<blg> / = {300,300},
%<cmr|ppl> / = {200,300},
%<ugm> / = {100,300},
%<m-t|ptm> - = {500,500},
%<bch|cmr|ppl> - = {400,500},
+%<blg> - = {300,400},
%<pad> - = {300,500},
%<pmn> - = {200,400},
%<ugm> - = {500,600},
+%<blg> < = {200,100}, > = {100,200},
+%<blg> _ = {150,250},
+%<blg> | = {250,250},
%<m-t|pmn> \textendash = {200,200}, \textemdash = {150,150},
%<bch> \textendash = {200,300}, \textemdash = {150,250},
%<cmr> \textendash = {400,300}, \textemdash = {300,200},
@@ -10005,14 +10970,16 @@ time will almost certainly lead to undesired results. Have your choice!}%
% might be used like that (see the \pkg{csquotes} package for examples).
% \begin{macrocode}
%<m-t|bch|pmn> \textquoteleft = {300,400}, \textquoteright = {300,400},
+%<blg> \textquoteleft = {400,600}, \textquoteright = {400,600},
%<cmr> \textquoteleft = {500,700}, \textquoteright = {500,600},
%<pad|ppl> \textquoteleft = {500,700}, \textquoteright = {500,700},
%<ptm> \textquoteleft = {500,500}, \textquoteright = {300,500},
%<ugm> \textquoteleft = {300,600}, \textquoteright = {300,600},
-%<m-t|bch|pmn> \textquotedblleft = {300,300}, \textquotedblright = {300,300},
-%<cmr> \textquotedblleft = {500,300}, \textquotedblright = {200,600},
-%<pad|ppl|ptm> \textquotedblleft = {300,400}, \textquotedblright = {300,400},
-%<ugm> \textquotedblleft = {400,400}, \textquotedblright = {400,400},
+%<m-t|bch|pmn> \textquotedblleft = {300,300}, \textquotedblright = {300,300}
+%<blg> \textquotedblright = {300,400}
+%<cmr> \textquotedblleft = {500,300}, \textquotedblright = {200,600}
+%<pad|ppl|ptm> \textquotedblleft = {300,400}, \textquotedblright = {300,400}
+%<ugm> \textquotedblleft = {400,400}, \textquotedblright = {400,400}
}
% \end{macrocode}
@@ -10034,7 +11001,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"06 = { 50, 50}, % \Sigma
"07 = {100,100}, % \Upsilon
"08 = { 50, 50}, % \Phi
- "09 = { 50, 50}, % \Psi
+ "09 = { 50, 50} % \Psi
% \end{macrocode}
% Remaining slots can be found in the source file.
%\iffalse ^^A ... namely, here:
@@ -10054,6 +11021,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\SetProtrusion
%<m-t> [ name = T1-default,
%<bch> [ name = bch-T1,
+%<blg> [ name = blg-T1,
%<cmr> [ name = cmr-T1,
%<pad> [ name = pad-T1,
%<pmn> [ name = pmnj-T1,
@@ -10062,6 +11030,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ugm> [ name = ugm-T1,
%<m-t> load = default ]
%<bch> load = bch-default ]
+%<blg> load = blg-default ]
%<cmr> load = cmr-default ]
%<pad> load = pad-default ]
%<pmn> load = pmnj-default ]
@@ -10070,8 +11039,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ugm> load = ugm-default ]
%<m-t> { encoding = {T1,LY1} }
%<bch|cmr|pad|pmn|ppl> { encoding = {T1,LY1},
-%<ptm|ugm> { encoding = {T1},
+%<blg|ptm|ugm> { encoding = {T1},
%<bch> family = bch }
+%<blg> family = blg }
%<cmr> family = cmr }
%<pad> family = {pad,padx,padj} }
%<pmn> family = pmnj }
@@ -10082,16 +11052,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> \AE = {50, },
%<bch> \OE = {50, },
%<pmn> \TH = { ,50},
+%<blg> \v L = { ,250},
+%<blg> \v d = { ,250},
+%<blg> \v l = { ,250},
+%<blg> \v t = { ,250},
+%<blg> 127 = {300,400},
+%<blg> 156 = {100, }, % IJ
+%<blg> 188 = { 80, 80}, % ij
%<m-t|bch|pad|pmn|ppl|ptm> _ = {100,100},
%<cmr> _ = {200,200},
%<ugm> _ = {100,200},
%<m-t|pad|pmn|ptm> \textbackslash = {100,200},
%<bch> \textbackslash = {150,200},
+%<blg> \textbackslash = {250,300},
%<cmr|ppl> \textbackslash = {200,300},
%<ugm> \textbackslash = {100,300},
%<ugm> \textbar = {200,200},
-%<cmr> \textquotedblleft = {200,600},
-%<cmr> \textquotedbl = {300,300},
+%<blg> \textendash = {300,300}, \textemdash = {150,150},
+%<blg> \textquotedbl = {300,400}, \textquotedblleft = {300,400},
+%<cmr> \textquotedbl = {300,300}, \textquotedblleft = {200,600},
% \end{macrocode}
%\changes{v1.4}{2004/10/30}{tweak quote characters for \texttt{cmr}
% variants (<OT1>, <T1>, \texttt{lmr})}
@@ -10099,22 +11078,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
% and boundary character. Therefore, we must override the settings from <OT1>.
% \begin{macrocode}
%<m-t|cmr|pad|ppl|ptm|ugm> \quotesinglbase = {400,400}, \quotedblbase = {400,400},
+%<blg> \quotesinglbase = {400,400}, \quotedblbase = {300,400},
%<bch|pmn> \quotesinglbase = {400,400}, \quotedblbase = {300,300},
%<m-t|bch|pmn> \guilsinglleft = {400,300}, \guilsinglright = {300,400},
+%<blg> \guilsinglleft = {300,500}, \guilsinglright = {300,500},
%<cmr|pad|ppl|ptm> \guilsinglleft = {400,400}, \guilsinglright = {300,500},
%<ugm> \guilsinglleft = {400,400}, \guilsinglright = {300,600},
%<m-t> \guillemotleft = {200,200}, \guillemotright = {200,200},
%<cmr> \guillemotleft = {300,200}, \guillemotright = {100,400},
%<bch|pmn> \guillemotleft = {200,200}, \guillemotright = {150,300},
-%<pad|ppl|ptm> \guillemotleft = {300,300}, \guillemotright = {200,400},
+%<blg|pad|ppl|ptm> \guillemotleft = {300,300}, \guillemotright = {200,400},
%<ugm> \guillemotleft = {300,400}, \guillemotright = {300,400},
%<m-t|bch|cmr|pad|pmn|ppl|ugm> \textexclamdown = {100, }, \textquestiondown = {100, },
+%<blg> \textexclamdown = {200, }, \textquestiondown = {100, },
%<ptm> \textexclamdown = {200, }, \textquestiondown = {200, },
%<m-t|cmr|pad|ppl|ptm|ugm> \textbraceleft = {400,200}, \textbraceright = {200,400},
-%<bch|pmn> \textbraceleft = {200, }, \textbraceright = { ,300},
-%<m-t|bch|cmr|pad|ppl|ptm|ugm> \textless = {200,100}, \textgreater = {100,200},
+%<bch|blg|pmn> \textbraceleft = {200, }, \textbraceright = { ,300},
+%<m-t|bch|cmr|pad|ppl|ptm|ugm> \textless = {200,100}, \textgreater = {100,200}
%<pmn> \textless = {100, }, \textgreater = { ,100},
-%<pmn> \textvisiblespace = {100,100}, % not in LY1
+%<pmn> \textvisiblespace = {100,100} % not in LY1
% \end{macrocode}
%\iffalse
% \dh = { , },
@@ -10140,7 +11122,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = lmr }
{
\textquotedblleft = {500,300},
- \quotedblbase = {500,300},
+ \quotedblbase = {500,300}
}
%</cmr>
@@ -10173,7 +11155,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ptm> \textbraceleft = {200,200}, \textbraceright = {200,300},
\textless = {200,100}, \textgreater = {100,200},
\textminus = {200,200}, \textdegree = {300,300},
-%<m-t> \copyright = {100,100}, \textregistered = {100,100},
+%<m-t> \copyright = {100,100}, \textregistered = {100,100}
%<ptm> \copyright = {100,150}, \textregistered = {100,150},
%<ptm> \textxgeq = { ,100}, \textxleq = {100, },
%<ptm> \textalpha = { , 50}, \textDelta = { 70, 70},
@@ -10186,7 +11168,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ptm> \texttimes = {100,150}, \textpm = { 50, 80},
%<ptm> \textbullet = {150,150}, \textperiodcentered = {300,300},
%<ptm> \textquotesingle = {500,500}, \textquotedbl = {300,300},
-%<ptm> \textperthousand = { ,50},
+%<ptm> \textperthousand = { ,50}
}
%</m-t|ptm>
@@ -10217,7 +11199,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> \guillemotleft = {300,200}, \guillemotright = {100,400},
%<bch> \textbraceleft = {200, }, \textbraceright = { ,300},
%<cmr> \textbraceleft = {400,200}, \textbraceright = {200,400},
- \textless = {200,100}, \textgreater = {100,200},
+ \textless = {200,100}, \textgreater = {100,200}
}
%</cmr|bch>
@@ -10228,7 +11210,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{ encoding = OT1,
family = pmnx }
{
- 1 = {230,180},
+ 1 = {230,180}
}
\SetProtrusion
@@ -10237,7 +11219,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{ encoding = {T1,LY1},
family = pmnx }
{
- 1 = {230,180},
+ 1 = {230,180}
}
%</pmn>
@@ -10274,7 +11256,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\textperiodcentered = {300,300},
\textplusminus = { 50, 80},
\textmultiply = {100,100},
- \textdivide = { 50,150},
+ \textdivide = { 50,150}
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -10307,22 +11289,25 @@ time will almost certainly lead to undesired results. Have your choice!}%
\SetProtrusion
%<m-t> [ name = OT1-it ]
%<bch> [ name = bch-it ]
+%<blg> [ name = blg-it,
+%<blg> load = blg-default ]
%<cmr> [ name = cmr-it ]
%<pad> [ name = pad-it ]
%<pmn> [ name = pmnj-it ]
%<ppl> [ name = ppl-it ]
%<ptm> [ name = ptm-it ]
%<ugm> [ name = ugm-it ]
-%<m-t|bch|pad|pmn|ugm> { encoding = OT1,
+%<m-t|bch|blg|pad|pmn|ugm> { encoding = OT1,
%<ppl|ptm> { encoding = {OT1,OT4},
%<bch> family = bch,
+%<blg> family = blg,
%<pad> family = {pad,padx,padj},
%<pmn> family = pmnj,
%<ppl> family = {ppl,pplx,pplj},
%<ptm> family = {ptm,ptmx,ptmj},
%<ugm> family = ugm,
-%<!(cmr|ugm)> shape = {it,sl} }
-%<ugm> shape = it }
+%<m-t|bch|pad|pmn|ppl|ptm> shape = {it,sl} }
+%<blg|ugm> shape = it }
%<cmr> { }
{
%<cmr|ptm> A = {100,50},
@@ -10435,7 +11420,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> 8 = {50,-50},
%<cmr> 9 = {100,-100},
%<m-t|cmr|pad|pmn|ppl> . = { ,500},
+%<blg> . = {400,600},
%<bch|ptm|ugm> . = { ,700},
+%<blg> {,}= {300,500},
%<m-t|cmr|pad|pmn|ppl> {,}= { ,500},
%<bch|ugm> {,}= { ,600},
%<ptm> {,}= { ,700},
@@ -10475,7 +11462,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<m-t|bch|ugm> ~ = {150,150},
%<cmr|pad|pmn|ppl|ptm> ~ = {200,150},
%<ugm> {=}= {200,200},
- ( = {200, }, ) = { ,200},
+%<!blg> ( = {200, }, ) = { ,200},
%<m-t|cmr|pad|ppl|ptm|ugm> / = {100,200},
%<bch> / = { ,150},
%<pmn> / = {100,150},
@@ -10486,20 +11473,23 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ppl> - = {300,500},
%<ptm> - = {500,500},
%<ugm> - = {400,700},
+%<blg> _ = {0,300},
%<m-t|pmn> \textendash = {200,200}, \textemdash = {150,150},
%<bch> \textendash = {200,300}, \textemdash = {150,200},
%<cmr> \textendash = {500,300}, \textemdash = {400,200},
%<pad|ppl|ptm|ugm> \textendash = {300,300}, \textemdash = {200,200},
%<m-t|bch|pmn|ugm> \textquoteleft = {400,200}, \textquoteright = {400,200},
+%<blg> \textquoteleft = {400,400}, \textquoteright = {400,400},
%<cmr|pad> \textquoteleft = {800,200}, \textquoteright = {800,200},
%<ppl> \textquoteleft = {700,400}, \textquoteright = {700,400},
%<ptm> \textquoteleft = {800,500}, \textquoteright = {800,500},
-%<m-t|bch|pmn> \textquotedblleft = {400,200}, \textquotedblright = {400,200},
-%<cmr> \textquotedblleft = {700,100}, \textquotedblright = {500,300},
-%<pad> \textquotedblleft = {700,200}, \textquotedblright = {700,200},
-%<ppl> \textquotedblleft = {500,300}, \textquotedblright = {500,300},
-%<ptm> \textquotedblleft = {700,400}, \textquotedblright = {700,400},
-%<ugm> \textquotedblleft = {600,200}, \textquotedblright = {600,200},
+%<m-t|bch|pmn> \textquotedblleft = {400,200}, \textquotedblright = {400,200}
+%<blg> \textquotedblright = {300,300}
+%<cmr> \textquotedblleft = {700,100}, \textquotedblright = {500,300}
+%<pad> \textquotedblleft = {700,200}, \textquotedblright = {700,200}
+%<ppl> \textquotedblleft = {500,300}, \textquotedblright = {500,300}
+%<ptm> \textquotedblleft = {700,400}, \textquotedblright = {700,400}
+%<ugm> \textquotedblleft = {600,200}, \textquotedblright = {600,200}
}
%<*cmr>
@@ -10522,13 +11512,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
"07 = {200,150}, % \Upsilon
"08 = {150, 50}, % \Phi
"09 = {150,100}, % \Psi
- "0A = { 50, 50}, % \Omega
+ "0A = { 50, 50} % \Omega
}
%</cmr>
\SetProtrusion
%<m-t> [ name = T1-it-default,
%<bch> [ name = bch-it-T1,
+%<blg> [ name = blg-it-T1,
%<cmr> [ name = cmr-it-T1,
%<pad> [ name = pad-it-T1,
%<pmn> [ name = pmnj-it-T1,
@@ -10537,6 +11528,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ugm> [ name = ugm-it-T1,
%<m-t> load = OT1-it ]
%<bch> load = bch-it ]
+%<blg> load = blg-T1 ]
%<cmr> load = cmr-it ]
%<pmn> load = pmnj-it ]
%<pad> load = pad-it ]
@@ -10544,20 +11536,24 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ptm> load = ptm-it ]
%<ugm> load = ugm-it ]
%<m-t|bch|cmr|pad|pmn|ppl> { encoding = {T1,LY1},
-%<ptm|ugm> { encoding = {T1},
+%<blg|ptm|ugm> { encoding = {T1},
%<bch> family = bch,
+%<blg> family = blg,
%<cmr> family = cmr,
%<pmn> family = pmnj,
%<pad> family = {pad,padx,padj},
%<ppl> family = {ppl,pplx,pplj},
%<ptm> family = {ptm,ptmx,ptmj},
%<ugm> family = ugm,
-%<!(cmr|ugm)> shape = {it,sl} }
-%<cmr|ugm> shape = it }
+%<m-t|bch|pad|pmn|ppl|ptm> shape = {it,sl} }
+%<blg|cmr|ugm> shape = it }
{
%<m-t|bch|pmn> _ = { ,100},
+%<blg> _ = {0,300},
%<cmr|ugm> _ = {100,200},
%<pad|ppl|ptm> _ = {100,100},
+%<blg> . = {400,600},
+%<blg> {,}= {300,500},
%<cmr> \AE = {100, },
%<bch> \OE = { 50, },
%<cmr> \OE = {100, },
@@ -10573,6 +11569,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<pmn> \textbackslash = {100,150},
%<ugm> \textbar = {200,200},
%<cmr> \textquotedblleft = {500,300},
+%<blg> \textquoteleft = {400,400}, \textquoteright = {400,400},
+%<blg> \textquotedbl = {300,300}, \textquotedblleft = {300,300},
+%<blg> \textquotedblright = {300,300}, \quotedblbase = {200,600},
%<m-t|ptm> \quotesinglbase = {300,700}, \quotedblbase = {400,500},
%<cmr> \quotesinglbase = {300,700}, \quotedblbase = {200,600},
%<bch|pmn> \quotesinglbase = {200,500}, \quotedblbase = {150,500},
@@ -10596,8 +11595,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch|pmn> \textbraceleft = {200, }, \textbraceright = { ,200},
%<cmr|pad|ptm> \textbraceleft = {400,100}, \textbraceright = {200,200},
%<bch|pmn> \textless = {100, }, \textgreater = { ,100},
-%<cmr|pad|ppl|ptm> \textless = {300,100}, \textgreater = {200,100},
-%<pmn> \textvisiblespace = {100,100},
+%<cmr|pad|ppl|ptm> \textless = {300,100}, \textgreater = {200,100}
+%<pmn> \textvisiblespace = {100,100}
}
%<*m-t|ptm>
@@ -10622,7 +11621,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\textbraceleft = {200,100}, \textbraceright = {200,200},
\textless = {100,100}, \textgreater = {100,100},
\textminus = {200,200}, \textdegree = {300,150},
-%<m-t> \copyright = {100,100}, \textregistered = {100,100},
+%<m-t> \copyright = {100,100}, \textregistered = {100,100}
%<ptm> \textregistered = {100,150}, \copyright = {100,150},
%<ptm> \textDelta = { 70, }, \textdelta = { , 50},
%<ptm> \textpi = { 50, 80}, \textmu = { , 80},
@@ -10635,7 +11634,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ptm> \texttimes = {100,150}, \textpm = { 50, 80},
%<ptm> \textbullet = {300,100}, \textperiodcentered = {300,300},
%<ptm> \textquotesingle = {500,500}, \textquotedbl = {300,300},
-%<ptm> \textperthousand = { ,50},
+%<ptm> \textperthousand = { ,50}
}
%</m-t|ptm>
@@ -10662,8 +11661,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> \guillemotleft = {400,100}, \guillemotright = {200,300},
%<bch> \textbraceleft = {200, }, \textbraceright = { ,200},
%<cmr> \textbraceleft = {400,100}, \textbraceright = {200,200},
-%<bch> \textless = {100, }, \textgreater = { ,100},
-%<cmr> \textless = {300,100}, \textgreater = {200,100},
+%<bch> \textless = {100, }, \textgreater = { ,100}
+%<cmr> \textless = {300,100}, \textgreater = {200,100}
}
%</cmr|bch>
@@ -10682,7 +11681,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
L = { ,50},
f = { ,-50},
- = {300, },
- \textendash = {400, }, \textemdash = {300, },
+ \textendash = {400, }, \textemdash = {300, }
}
\SetProtrusion
@@ -10695,7 +11694,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
L = { ,50},
f = { ,-50},
- = {300, },
- \textendash = {400, }, \textemdash = {300, },
+ \textendash = {400, }, \textemdash = {300, }
}
\SetProtrusion
@@ -10708,7 +11707,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
L = { ,50},
f = { ,-50},
- = {300, },
- \textendash = {400, }, \textemdash = {300, },
+ \textendash = {400, }, \textemdash = {300, }
}
\SetProtrusion
@@ -10719,7 +11718,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
shape = {it,sl} }
{
\textquotedblleft = {700,100},
- \quotedblbase = {600,300},
+ \quotedblbase = {600,300}
}
% \end{macrocode}
@@ -10739,7 +11738,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
6 = {200, },
7 = {200, 50},
8 = {150,-50},
- 9 = {100, 50},
+ 9 = {100, 50}
}
%</cmr>
@@ -10751,7 +11750,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = {it,sl} }
{
- 1 = {100,150},
+ 1 = {100,150}
}
\SetProtrusion
@@ -10761,7 +11760,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = {it,sl} }
{
- 1 = {100,150},
+ 1 = {100,150}
}
%</pmn>
@@ -10796,7 +11795,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\textonehalf = { 50, },
\textplusminus = {100,100},
\textmultiply = {150,150},
- \textdivide = {150,150},
+ \textdivide = {150,150}
}
%</ptm>
@@ -10808,7 +11807,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% relative to character width, we don't need to adjust them any further (but
% we have to reset some characters).
% \begin{macrocode}
-%<*!ugm>
+%<*!(blg|ugm)>
\SetProtrusion
%<m-t> [ name = OT1-sc,
%<bch> [ name = bch-sc,
@@ -10853,8 +11852,8 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ppl> q = { 0, },
%<m-t|cmr|pad|pmn|ppl|ptm> r = { , 0},
t = {50,50},
-%<m-t|bch|cmr|pad|pmn|ppl> y = {50,50},
-%<ptm> y = {80,80},
+%<m-t|bch|cmr|pad|pmn|ppl> y = {50,50}
+%<ptm> y = {80,80}
}
\SetProtrusion
@@ -10900,11 +11899,11 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ppl> q = { 0, },
%<m-t|cmr|pad|pmn|ppl|ptm> r = { , 0},
t = {50,50},
-%<m-t|bch|cmr|pad|pmn|ppl> y = {50,50},
-%<ptm> y = {80,80},
+%<m-t|bch|cmr|pad|pmn|ppl> y = {50,50}
+%<ptm> y = {80,80}
}
-%</!ugm>
+%</!(blg|ugm)>
%<*m-t>
\SetProtrusion
[ name = QX-sc,
@@ -10919,7 +11918,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
013 = { ,50}, % fl
r = { , 0},
t = {50,50},
- y = {50,50},
+ y = {50,50}
}
%</m-t>
@@ -10946,7 +11945,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch> q = { 0, },
%<cmr> r = { , 0},
t = {50,50},
- y = {50,50},
+ y = {50,50}
}
%</cmr|bch>
@@ -10958,7 +11957,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = sc }
{
- 1 = {230,180},
+ 1 = {230,180}
}
\SetProtrusion
@@ -10968,7 +11967,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = sc }
{
- 1 = {230,180},
+ 1 = {230,180}
}
% \end{macrocode}
@@ -11014,7 +12013,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
v = {100, },
w = {100, },
y = {50, },
- z = { ,-50},
+ z = { ,-50}
}
\SetProtrusion
@@ -11054,7 +12053,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
v = {100, },
w = {100, },
y = {50, },
- z = { ,-50},
+ z = { ,-50}
}
\SetProtrusion
@@ -11064,7 +12063,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = {scit,si} }
{
- 1 = {100,150},
+ 1 = {100,150}
}
\SetProtrusion
@@ -11074,7 +12073,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
family = pmnx,
shape = {scit,si} }
{
- 1 = {100,150},
+ 1 = {100,150}
}
%</pmn>
@@ -11090,6 +12089,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
\SetProtrusion
%<m-t> [ name = textcomp ]
%<bch> [ name = bch-textcomp ]
+%<blg> [ name = blg-textcomp ]
%<cmr> [ name = cmr-textcomp ]
%<pad> [ name = pad-textcomp ]
%<pmn> [ name = pmn-textcomp ]
@@ -11099,6 +12099,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<m-t> { encoding = TS1 }
%<!m-t> { encoding = TS1,
%<bch> family = bch }
+%<blg> family = blg }
%<cmr> family = cmr }
%<pad> family = {pad,padx,padj} }
%<pmn> family = {pmnx,pmnj} }
@@ -11106,18 +12107,22 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<ptm> family = {ptm,ptmx,ptmj} }
%<ugm> family = ugm }
{
+%<blg> \textquotestraightbase = {400,500},
%<cmr> \textquotestraightbase = {300,300},
%<pad|pmn> \textquotestraightbase = {400,400},
+%<blg> \textquotestraightdblbase = {300,400},
%<cmr|pmn> \textquotestraightdblbase = {300,300},
%<pad> \textquotestraightdblbase = {400,400},
%<bch|cmr|pad|pmn|ugm> \texttwelveudash = {200,200},
%<bch|cmr|pad|pmn> \textthreequartersemdash = {150,150},
%<ugm> \textthreequartersemdash = {200,200},
+%<blg> \textquotesingle = {500,600},
%<cmr|pmn> \textquotesingle = {300,400},
%<pad> \textquotesingle = {400,500},
%<ptm> \textquotesingle = {500,500},
%<ugm> \textquotesingle = {300,500},
%<bch|cmr|pmn> \textasteriskcentered = {200,300},
+%<blg> \textasteriskcentered = {150,200},
%<pad> \textasteriskcentered = {300,300},
%<ugm> \textasteriskcentered = {100,200},
%<pmn> \textfractionsolidus = {-200,-200},
@@ -11132,29 +12137,35 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<cmr> \textrangle = { ,400},
%<m-t|bch|pmn|ptm> \textminus = {200,200},
%<cmr|pad|ppl> \textminus = {300,300},
-%<ugm> \textminus = {250,300},
+%<blg|ugm> \textminus = {250,300},
%<bch|pad|pmn> \textlbrackdbl = {100, },
+%<blg> \textlbrackdbl = {200, },
%<bch|pad|pmn> \textrbrackdbl = { ,100},
+%<blg> \textrbrackdbl = { ,200},
%<pmn> \textasciigrave = {200,500},
-%<bch|cmr|pad|pmn> \texttildelow = {200,250},
+%<bch|blg|cmr|pad|pmn> \texttildelow = {200,250},
%<pmn> \textasciibreve = {300,400},
%<pmn> \textasciicaron = {300,400},
%<pmn> \textacutedbl = {200,300},
%<pmn> \textgravedbl = {150,300},
%<bch|pmn|ugm> \textdagger = { 80, 80},
+%<blg> \textdagger = {200,200},
%<cmr|pad> \textdagger = {100,100},
%<ptm> \textdagger = {150,150},
+%<blg> \textdaggerdbl = {150,150},
%<cmr|pad|pmn> \textdaggerdbl = { 80, 80},
%<ptm> \textdaggerdbl = {100,100},
%<bch> \textbardbl = {100,100},
-%<ugm> \textbardbl = {150,150},
+%<blg|ugm> \textbardbl = {150,150},
%<bch> \textbullet = {200,200},
+%<blg> \textbullet = {400,500},
%<cmr|pad|pmn> \textbullet = { ,100},
%<ptm> \textbullet = {150,150},
%<ugm> \textbullet = { 50,100},
%<bch|cmr|pmn> \textcelsius = { 50, },
%<pad> \textcelsius = { 80, },
%<bch> \textflorin = { 50, 50},
+%<blg> \textflorin = {100,100},
%<pad|ugm> \textflorin = { ,100},
%<pmn> \textflorin = { 50,100},
%<ptm> \textflorin = { 50, 70},
@@ -11164,7 +12175,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<pmn> \textinterrobangdown = {100, },
%<m-t|pad|ptm> \texttrademark = {100,100},
%<bch> \texttrademark = {150,150},
-%<cmr|ppl> \texttrademark = {200,200},
+%<blg|cmr|ppl> \texttrademark = {200,200},
%<pmn> \texttrademark = { 50, 50},
%<ugm> \texttrademark = {100,150},
%<bch|ugm> \textcent = { 50, },
@@ -11172,6 +12183,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch> \textsterling = { 50, },
%<ugm> \textsterling = { , 50},
%<bch> \textbrokenbar = {200,200},
+%<blg> \textbrokenbar = {250,250},
%<ugm> \textbrokenbar = {200,300},
%<pmn> \textasciidieresis = {300,400},
%<m-t|bch|cmr|pad|ptm|ugm> \textcopyright = {100,100},
@@ -11180,22 +12192,24 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch|cmr|ugm> \textordfeminine = {100,200},
%<pad|pmn> \textordfeminine = {200,200},
%<bch|cmr|pad|pmn|ugm> \textlnot = {200, },
+%<blg> \textlnot = {200,100},
%<m-t|bch|cmr|pad|ptm|ugm> \textregistered = {100,100},
%<pmn> \textregistered = { 50,150},
%<ppl> \textregistered = {200,200},
%<pmn> \textasciimacron = {150,200},
%<m-t|ppl|ptm> \textdegree = {300,300},
%<bch> \textdegree = {150,200},
+%<blg|ugm> \textdegree = {200,200},
%<cmr|pad> \textdegree = {400,400},
%<pmn> \textdegree = {150,400},
-%<ugm> \textdegree = {200,200},
%<bch|cmr|pad|pmn|ugm> \textpm = {150,200},
+%<blg> \textpm = {100,100},
%<ptm> \textpm = { 50, 80},
-%<bch|ugm> \texttwosuperior = {100,200},
+%<bch|blg|ugm> \texttwosuperior = {100,200},
%<cmr> \texttwosuperior = { 50,100},
%<pad|pmn> \texttwosuperior = {200,200},
%<ptm> \texttwosuperior = { 50, 50},
-%<bch|ugm> \textthreesuperior = {100,200},
+%<bch|blg|ugm> \textthreesuperior = {100,200},
%<cmr> \textthreesuperior = { 50,100},
%<pad|pmn> \textthreesuperior = {200,200},
%<ptm> \textthreesuperior = { 50, 50},
@@ -11203,30 +12217,33 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<bch|ugm> \textmu = { ,100},
%<bch|pad|pmn> \textparagraph = { ,100},
%<bch|cmr|pad|pmn> \textperiodcentered = {300,400},
+%<blg> \textperiodcentered = {400,500},
%<ptm> \textperiodcentered = {300,300},
%<ugm> \textperiodcentered = {200,500},
-%<bch|ugm> \textonesuperior = {200,300},
+%<bch|blg|ugm> \textonesuperior = {200,300},
%<cmr|pad|pmn> \textonesuperior = {200,200},
%<ptm> \textonesuperior = {100,100},
%<bch|pad|pmn|ugm> \textordmasculine = {200,200},
-%<cmr> \textordmasculine = {100,200},
+%<blg|cmr> \textordmasculine = {100,200},
%<bch|cmr|pmn> \texteuro = {100, },
%<pad> \texteuro = { 50,100},
-%<bch|ptm> \texttimes = {100,100},
+%<bch> \texttimes = {200,200},
+%<blg|ptm> \texttimes = {100,100},
%<cmr> \texttimes = {150,250},
%<pad> \texttimes = {100,150},
%<pmn> \texttimes = { 70,100},
%<ugm> \texttimes = {200,300},
-%<bch|pad|pmn> \textdiv = {150,200},
-%<cmr> \textdiv = {150,250},
+%<bch|pad|pmn> \textdiv = {150,200}
+%<blg> \textdiv = {100,100}
+%<cmr> \textdiv = {150,250}
%<ptm> \textdiv = { 50,100},
%<ugm> \textdiv = {200,300},
-%<ptm> \textperthousand = { ,50},
+%<ptm> \textperthousand = { ,50}
%<ugm> \textsection = { ,100},
%<ugm> \textonehalf = { 50,100},
%<ugm> \textonequarter = { 50,100},
%<ugm> \textthreequarters = { 50,100},
-%<ugm> \textsurd = { ,100},
+%<ugm> \textsurd = { ,100}
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -11410,14 +12427,14 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<pad> \texttimes = {200,100},
%<pmn> \texttimes = { 70,100},
%<ugm> \texttimes = {200,300},
-%<cmr|pad> \textdiv = {200,200},
-%<pmn> \textdiv = {150,200},
+%<cmr|pad> \textdiv = {200,200}
+%<pmn> \textdiv = {150,200}
%<ugm> \textdiv = {200,300},
%<ugm> \textsection = { ,200},
%<ugm> \textonehalf = { 50,100},
%<ugm> \textonequarter = { 50,100},
%<ugm> \textthreequarters = { 50,100},
-%<ugm> \textsurd = { ,100},
+%<ugm> \textsurd = { ,100}
}
%</cmr|pad|pmn|ugm>
@@ -11537,7 +12554,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"5E = {200,200}, % \smile
"5F = {200,200}, % \frown
"7C = {100, }, % \jmath
- "7D = { ,100}, % \wp
+ "7D = { ,100} % \wp
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -11667,7 +12684,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"7C = {100,100}, % \clubsuit
"7D = {100,100}, % \diamondsuit
"7E = {100,100}, % \heartsuit
- "7F = {100,100}, % \spadesuit
+ "7F = {100,100} % \spadesuit
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -11872,7 +12889,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"7C = {100,100}, % \intercal
"7D = { 50, 50}, % \circledcirc
"7E = { 50, 50}, % \circledast
- "7F = { 50, 50}, % \circleddash
+ "7F = { 50, 50} % \circleddash
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -12019,7 +13036,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"79 = { 50,150}, % \curvearrowright
"7A = { 50,200}, % \digamma
"7B = {100, 50}, % \varkappa
- "7F = {200, }, % \backepsilon
+ "7F = {200, } % \backepsilon
% \end{macrocode}
% Remaining slots in the source file.
%\iffalse
@@ -12092,7 +13109,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
X = { 50, 50},
Y = { 50, },
h = { , 50},
- k = { , 50},
+ k = { , 50}
}
% \end{macrocode}
@@ -12119,7 +13136,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"5F = {100,100},
"80 = { , 50},
"81 = {200,250},
- "82 = {100,200},
+ "82 = {100,200}
}
%</eur>
@@ -12161,7 +13178,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"5F = {100,100},
"66 = { 50, },
"67 = { , 50},
- "6E = {200,200},
+ "6E = {200,200}
}
\SetProtrusion
@@ -12250,7 +13267,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
"BA = { ,200},
"BB = { ,200},
"BD = {200,200},
- "DE = {200,200},
+ "DE = {200,200}
}
%</eus>
@@ -12302,7 +13319,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{=} = {200,200},
: = { ,200},
; = { ,200},
- ] = { ,200},
+ ] = { ,200}
}
%</euf>
@@ -12328,7 +13345,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
%<zpeu> E = {50, }
%<euroitc> E = {100,50}
%<mvs> 164 = {50,50}, % \EUR
-%<mvs> 068 = {50,-100}, % \EURdig
+%<mvs> 068 = {50,-100} % \EURdig
}
%<*zpeu|euroitc>
@@ -12371,7 +13388,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
%<*m-t>
%%% -----------------------------------------------------------------------
-%%% INTERWORD SPACING SETTINGS
+%%% INTERWORD SPACING
\SetExtraSpacing
[ name = default ]
@@ -12379,10 +13396,23 @@ time will almost certainly lead to undesired results. Have your choice!}%
{
% \end{macrocode}
% These settings are only a first approximation. The following reasoning is from
-% a mail from \contributor Ulrich Dirr <ud\at art-satz.de>. ^^A private mail, 14/06/2005
+% a mail from \contributor Ulrich Dirr <ud\at art-satz.de>^^A private mail, 14/06/2005
+%\ifpdf\IfFileExists{justification.jpg}{^^A
+% , who also provided the sample in figure~\ref{fig:example-spacing}^^A
+%\changes{v2.2}{2007/04/05}{add sample}^^A
+% \begin{figure}
+% \caption{^^A
+% Example for interword spacing (from Siemoneit 1989).
+% ^^A Manfred Siemoneit, Typographisches Gestalten.
+% ^^A Regeln und Tips f\"ur die richtige Gestaltung von Drucksachen,
+% ^^A Bielefeld 1989
+% The numbers indicate the preference/order when the interword space
+% needs to be shrunk.}
+% \label{fig:example-spacing}
+% \includegraphics[width=.6\textwidth]{justification.jpg}
+% \end{figure}^^A
+%}\relax\fi.
% I do not claim to have coped with the task.
-% (\dots\ In fact, I~think these settings are wrong. They lead to more overfull
-% boxes than without spacing adjustment. Needs to be fixed.)
%\todo{fix spacing settings}
%
%\begin{quote}
@@ -12407,7 +13437,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
r = { ,-300,300},
% \end{macrocode}
-% \item before or after lowercase characters with ascenders
+% \item\relax [before or] after lowercase characters with ascenders
% \begin{macrocode}
b = { ,-200,200},
d = { ,-200,200},
@@ -12417,7 +13447,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
l = { ,-200,200},
t = { ,-200,200},
% \end{macrocode}
-% \item before of after lowercase characters with x-height plus descender
+% \item\relax [before or] after lowercase characters with x-height plus descender
% with additional optical space, \eg, `v', or `w'
% \begin{macrocode}
c = { ,-100,100},
@@ -12426,9 +13456,9 @@ time will almost certainly lead to undesired results. Have your choice!}%
w = { ,-100,100},
z = { ,-100,100},
x = { ,-100,100},
- y = { ,-100,100}, % ?
+ y = { ,-100,100},
% \end{macrocode}
-% \item before of after lowercase characters with x-height plus descender
+% \item\relax [before or] after lowercase characters with x-height plus descender
% without additional optical space
% \begin{macrocode}
i = { , 50, -50},
@@ -12446,7 +13476,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \begin{macrocode}
. = { ,250,-250},
! = { ,250,-250},
- ? = { ,250,-250},
+ ? = { ,250,-250}
% \end{macrocode}
%\end{itemize}
% The order has to be reversed when enlarging is needed.'
@@ -12460,6 +13490,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \item Is the result really better?
% \item Is it overdone? (Try with a |factor| \textless\ 1000.)
% \item Should the first parameter also be used? (Probably.)
+% \item What about quotation marks, parentheses etc.?
%\end{itemize}
%
% \subsubsection{Nonfrenchspacing}
@@ -12523,7 +13554,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
% \sfcode`\, 1250
%\end{verbatim}
% \begin{macrocode}
- {,}= { , 250,-200},
+ {,}= { , 250,-200}
% \end{macrocode}
%\begin{verbatim}
%}
@@ -12547,7 +13578,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
! = {240,2000,-667},
: = {240,1000,-500},
; = { , 500,-333},
- {,}= { , 250,-200},
+ {,}= { , 250,-200}
}
% \end{macrocode}
@@ -12570,8 +13601,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
{ }
% \end{macrocode}
+%
%\subsubsection{French}
-% For the French context.
+%
+% The ratio of \fontdim2 to \fontdim6 varies for different fonts, so that
+% either the kerning of the colon (which should be a space, \ie, \fontdim2) or
+% that of the other punctuation characters (\TeX's \cmd\thinspace, \ie, one
+% sixth of \fontdim6) may be inaccurate. For Times, for example, a thin space
+% would be 665. I don't know whether French typography really wants a thin
+% space, or rather (as it happens to turn out with <CMR>) half a space.
+% (Wikipedia\footnote{\url{http://fr.wikipedia.org/wiki/Espace_typographique}.}
+% claims it should be a quarter of an em, which seems too much to me; then
+% again, it also says that this \emph{was} a thin space in French typography.)
% \begin{macrocode}
\SetExtraKerning
[ name = french-default,
@@ -12582,7 +13623,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
: = {1000,}, % = \fontdimen2
; = {500, }, % ~ \thinspace
! = {500, },
- ? = {500, },
+ ? = {500, }
}
% \end{macrocode}
@@ -12597,7 +13638,7 @@ time will almost certainly lead to undesired results. Have your choice!}%
{ encoding = {T1,LY1} }
{
\guillemotleft = { ,800}, % = 0.8\fontdimen2
- \guillemotright = {800, },
+ \guillemotright = {800, }
}
\SetExtraKerning
@@ -12609,18 +13650,18 @@ time will almost certainly lead to undesired results. Have your choice!}%
{ }
% \end{macrocode}
+%
%\subsubsection{Turkish}
-% And for Turkish.
+%
% \begin{macrocode}
\SetExtraKerning
[ name = turkish,
- context = turkish,
- unit = space ]
+ context = turkish ]
{ encoding = {OT1,T1,LY1} }
{
- : = {500, }, % ~ \thinspace
- ! = {500, },
- {=} = {500, },
+ : = {167, }, % = \thinspace
+ ! = {167, },
+ {=} = {167, }
}
%</m-t>
@@ -12763,7 +13804,7 @@ normal, and shrunk by 5\%:
% Grave accent \` Left brace \{ Vertical bar \|
% Right brace \} Tilde \~}
%
-% \CheckSum{8250}
+% \CheckSum{8918}
%
% \Finale
%
diff --git a/Master/texmf-dist/source/latex/microtype/microtype.ins b/Master/texmf-dist/source/latex/microtype/microtype.ins
index e05c1487d9e..2e6b7971760 100644
--- a/Master/texmf-dist/source/latex/microtype/microtype.ins
+++ b/Master/texmf-dist/source/latex/microtype/microtype.ins
@@ -1,5 +1,5 @@
-% -*- TeX:STY:UK -*-
-% $Id: microtype.ins,v 1.13 2007-01-14 18:07:31+01 schlicht Exp schlicht $
+% !Mode:: "TeX:STY:UK"
+% $Id: microtype.ins,v 1.14 2007-07-14 16:10:02+02 schlicht Exp schlicht $
% ------------------------------------------------------------------------
\input docstrip
\keepsilent
@@ -7,6 +7,7 @@
\preamble
------------------------------------------------------------------------
+
The `microtype' package
An interface to the micro-typographic extensions of pdfTeX
Copyright (c) 2004--2007 R Schlicht <w.m.l@gmx.net>
@@ -19,7 +20,7 @@ of all distributions of LaTeX version 2005/12/01 or later.
This work has the LPPL maintenance status `author-maintained'.
-This work consists of the files microtype.dtx and microtype.ins and the
+This work consists of the files microtype.dtx and microtype.ins and the
derived files microtype.sty and letterspace.sty.
% Modified versions of the configuration files (*.cfg) may be distributed
@@ -46,18 +47,18 @@ derived files microtype.sty and letterspace.sty.
\declarepreamble\cfgpreamble
This is the main configuration file for the `microtype' package.
It contains settings for font expansion and character protrusion,
- interword spacing and additional kerning, as well as character
- inheritance and font set declarations.
+ tracking, interword spacing and additional kerning, as well as
+ character inheritance and font set declarations.
+ You may customise these settings here, or in a different file.
Please consult the documentation for details.^^M
- You may customize these settings here, or in a different file. If
- you think you have found improvements to the settings, please let
- me know.^^M
+ If you think you have found improvements to these settings, please
+ let me know.^^M
When modifying this file, also change the identification line below.
\endpreamble
\declarepreamble\fontpreamble
- This is a font-specific configuration file for the `microtype'
- package. It may contain settings for font expansion and character
- protrusion, interword spacing and additional kerning, as well as
+ This is a font-specific configuration file for the `microtype' package.
+ It may contain settings for font expansion and character protrusion,
+ tracking, interword spacing and additional kerning, as well as
character inheritance declarations.
Please consult the documentation for details.^^M
If you think you have found improvements to these settings, please
@@ -84,13 +85,14 @@ derived files microtype.sty and letterspace.sty.
\def\makecfg#1#2{\makefile{mt-#2.cfg}{config,cfg-#1,#2}}
\generate{
- \makefile{microtype.sty}{package}
+ \makefile{microtype.sty}{package} % add `lua' for luatex support
\usepreamble\lsppreamble
\makefile{letterspace.sty}{letterspace}
\usepreamble\cfgpreamble
\makefile{microtype.cfg}{config,cfg-t,m-t}
\usepreamble\fontpreamble
\makecfg{t}{bch}
+ \makecfg{t}{blg}
\makecfg{t}{cmr}
\makecfg{t}{pad}
\makecfg{t}{ppl}