10.07.2015 Views

The microtype package

The microtype package

The microtype package

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

THE TITLE LOGO 212\tempdim\fboxrulei\fboxruleii\kernboxheight\scaletoem\showlogoA <strong>The</strong> title logo8736 Here’s how the logo on the title page was created. 30 It has nothing to do with <strong>microtype</strong>, actually, but uses fontinst.It is based on an experiment I posted to the de.comp.text.tex newsgroup. 31 It will show:• the character• the TEX box• the bounding box• kernsA.1 MacrosTo run this file, TEX needs to find the afm file (either in the TEXINPUTS path, or in the current working directory).First input fontinst.8737 \input fontinst.stybbox.sty is an addition to fontinst, which makes dimensions of the bounding boxes available (and was writtenby Hàn Thê´ Thành, by the way). <strong>The</strong>se dimensions are specified in the afm file, but not used by TEX, which is whyfontinst will discard them otherwise.8738 \input bbox.styAllocate some dimen registers.8739 \newdimen\tempdimFrame width of the box as TEX sees it.8740 \newdimen\fboxrulei8741 \fboxrulei=0.1ptFrame width of the bounding box.8742 \newdimen\fboxruleii8743 \fboxruleii=0.1ptHeight of the box indicating the kern.8744 \newdimen\kernboxheight8745 \kernboxheight=5ptAn auxiliary macro. Return a dimension relative to the em-width of the font. Requires e-TEX.8746 \setcommand\scaletoem#1{\dimexpr #1 sp*\fontdimen6\font/1000\relax}A fontinst incantation whose sole purpose is to produce the logo. Its argument is a string (letters only).8747 \fontinstcc8748 \def\showlogo#1{%Some fonts do not specify the \fontdimen 6 (width of an em) in the afm file. In this case, use the font size, which iscorrect in most cases.8749 \ifdim\fontdimen6\font = 0pt8750 \typeout{***~Warning:~no~fontdimen~6~specified~***^^J%8751 ***~setting~it~to~\pdffontsize\font \ifnum\pdftexversion < 130 pt\fi~***}8752 \fontdimen6\font=\pdffontsize\font \ifnum\pdftexversion < 130 pt\fi\relax8753 \fi8754 \installfonts8755 \input _ metrics{}{\logofont,\metrics\printbbs{#1}\relax}8756 \endinstallfonts8757 }8758 \normalccLayers.8759 \makeatletter8760 \def\mtl@layer#1#2{\pdfliteral{/OC/#1 BDC}#2\pdfliteral{EMC}}8761 \ifx\mt@objects\@undefined\let\mt@objects\@empty\fi8762 \ifx\mt@order \@undefined\let\mt@order \@empty\fi30 Note that the logo module will not be created when installing <strong>microtype</strong>. Instead, I’ve included the source in the PDFfile as an attachment. If your PDF reader supports this, you can to extract it; alternatively, you may us thepdftk tool.31 Message ID: 42aa3687$0$24366$9b4e6d93@newsread2.arcor-online.net

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!