Debian Codegraph @

texmf-dist/source/fonts/libris/librisadf.dtx

raw
1 % \iffalse meta-comment
2 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3 % librisadf.dtx
4 % Additions and changes Copyright (C) YYYY-2024 Clea F. Rees.
5 % Code from skeleton.dtx Copyright (C) 2015-2024 Scott Pakin (see below).
6 %
7 % This work may be distributed and/or modified under the
8 % conditions of the LaTeX Project Public License, either version 1.3c
9 % of this license or (at your option) any later version.
10 % The latest version of this license is in
11 % https://www.latex-project.org/lppl.txt
12 % and version 1.3c or later is part of all distributions of LaTeX
13 % version 2008-05-04 or later.
14 %
15 % This work has the LPPL maintenance status `maintained'.
16 %
17 % The Current Maintainer of this work is Clea F. Rees.
18 %
19 % This work consists of all files listed in manifest.txt.
20 %
21 % The file librisadf.dtx is a derived work under the terms of the
22 % LPPL. It is based on version 2.4 of skeleton.dtx which is part of
23 % dtxtut by Scott Pakin. A copy of dtxtut, including the
24 % unmodified version of skeleton.dtx is available from
25 % https://www.ctan.org/pkg/dtxtut and released under the LPPL.
26 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
27 % \fi
28 %
29 % \iffalse
30 %<*driver>
31 \RequirePackage{svn-prov}
32 % ref. ateb Max Chernoff: https://tex.stackexchange.com/a/723294/
33 \def\MakePrivateLetters{\makeatletter\ExplSyntaxOn\endlinechar13}
34 \ProvidesFileSVN{$Id: librisadf.dtx 10402 2024-09-27 02:35:48Z cfrees $}[v1.1 \revinfo][\filebase DTX: LibrisADF for 8-bit engines]
35 \DefineFileInfoSVN[librisadf]
36 \documentclass[11pt,british]{ltxdoc}
37 % l3doc loads fancyvrb
38 % fancyvrb overwrites svn-prov's macros without warning
39 % restore \fileversion \filerev in case we're using l3doc
40 \GetFileInfoSVN{librisadf}
41 \EnableCrossrefs
42 \CodelineIndex
43 \RecordChanges
44 %^^A \OnlyDescription
45 \DoNotIndex{\verb,\ProvidesPackageSVN,\NeedsTeXFormat,\ProcessKeyOptions,\revinfo,\DefineFileInfoSVN,\GetFileInfoSVN,\filebase,\filename}
46 \usepackage{babel}
47 \usepackage{lmodern}
48 \renewcommand{\ttdefault}{lmvtt}
49 \let\origsfdefault\sfdefault
50 \DeclareRobustCommand{\origsffamily}{%
51 \fontencoding{T1}%
52 \fontfamily{\origsfdefault}%
53 \selectfont}
54 \DeclareTextFontCommand{\textorigsf}{\origsffamily}
55 \usepackage{libris}
56 \pdfmapfile{yly.map} % not necessary for installed package
57 \pdfmapfile{+pdftex.map} % not necessary for installed package
58 \usepackage{fancyref}
59 \usepackage{array}
60 \usepackage{fancyhdr}
61 \usepackage{fixfoot}
62 \usepackage{enumitem}
63 \usepackage{booktabs}
64 \usepackage{xcolor}
65 \usepackage{xurl}
66 \urlstyle{tt}
67 \usepackage{microtype}
68 \usepackage[a4paper,headheight=14pt]{geometry} % use 14pt for 11pt text, 15pt for 12pt text
69 \usepackage{csquotes}
70 \MakeAutoQuote{‘}{’}
71 \MakeAutoQuote*{“}{”}
72 \usepackage{caption}
73 \DeclareCaptionFont{lf}{\lstyle}
74 \captionsetup[table]{labelfont=lf}
75 % sicrhau hyperindex=false: llwytho CYN bookmark
76 \usepackage{hypdoc}% ateb Ulrike Fischer: https://tex.stackexchange.com/a/695555/
77 \usepackage{bookmark}
78 \hypersetup{%
79 colorlinks=true,
80 citecolor={moss},
81 extension=pdf,
82 linkcolor={strawberry},
83 linktocpage=true,
84 pdfcreator={TeX},
85 pdfproducer={pdfeTeX},
86 urlcolor={blueberry}%
87 }
88 \title{\filebase}
89 \author{Clea F. Rees\thanks{%
90 Bug tracker:
91 \href{https://codeberg.org/cfr/nfssext/issues}{\url{codeberg.org/cfr/nfssext/issues}}
92 \textbar{} Code:
93 \href{https://codeberg.org/cfr/nfssext}{\url{codeberg.org/cfr/nfssext}}
94 \textbar{} Mirror:
95 \href{https://github.com/cfr42/nfssext}{\url{github.com/cfr42/nfssext}}%
96 }}
97 % \date{\fileversion~\filetoday}
98 \date{\fileversion~\filedate}
99 \pagestyle{fancy}
100 \fancyhf[lh]{\itshape\filebase~\fileversion}
101 % \fancyhf[rh]{\itshape\filetoday}
102 \fancyhf[rh]{\itshape\filedate}
103 \fancyhf[ch]{}
104 \fancyhf[lf]{}
105 \fancyhf[rf]{}
106 \fancyhf[cf]{--- \thepage~/~\lastpage{} ---}
107 \ExplSyntaxOn
108 \hook_gput_code:nnn {shipout/lastpage} {.}
109 {
110 \property_record:nn {t:lastpage}{abspage,page,pagenum}
111 }
112 \cs_new_protected_nopar:Npn \lastpage
113 {
114 \property_ref:nn {t:lastpage}{page}
115 }
116 \ExplSyntaxOff
117 \definecolor{strawberry}{rgb}{1.000,0.000,0.502}
118 \definecolor{blueberry}{rgb}{0.000,0.000,1.000}
119 \definecolor{moss}{rgb}{0.000,0.502,0.251}
120 \begin{document}
121 \DocInput{\filename}
122 \end{document}
123 %</driver>
124 % \fi
125 %
126 % \newcommand*{\adf}{ADF}
127 % \newcommand*{\lpack}[1]{\textsf{#1}}
128 % \newcommand*{\fgroup}[1]{\textsf{#1}}
129 % \newcommand*{\fname}[1]{\textsf{#1}}
130 %
131 % \changes{v1.0}{2008}{First public release.}
132 % \changes{v1.1}{2024-09-17}{%
133 % Belated update for (New) NFSS and revised nfssext-cfr.
134 % Add scale option to package.
135 % Try switching to DTX/INS.%
136 % }
137 %
138 % \maketitle\thispagestyle{empty}
139 % \pdfinfo{%
140 % /Creator (TeX)
141 % /Producer (pdfTeX)
142 % /Author (Clea F.\ Rees)
143 % /Title (librisadf)
144 % /Subject (TeX)
145 % /Keywords (TeX,LaTeX,font,fonts,tex,latex,Libris,libris,librisadf,LibrisADF,ADF,adf,Arkandis,Digital,Foundry,arkandis,digital,foundry,Hirwen,Harendal,Clea,Rees)}
146 % \pdfcatalog{%
147 % /URL ()
148 % /PageMode /UseOutlines}
149 % \setlength{\parindent}{0pt}
150 % \setlength{\parskip}{0.5em}
151 %
152 %
153 % \begin{abstract}
154 % \hspace*{-\parindent}Hirwen Harendal, Arkandis Digital Foundry (\adf) has produced the Libris \adf\ font collection. This guide outlines the \emph{experimental} \TeX/\LaTeX\ support provided with version 1.007 of the fonts.
155 % \end{abstract}
156 %
157 % This document explains how to use the \TeX/\LaTeX\ support included with version 1.007 of the Libris \adf\ font collection. The fonts were developed by Hirwen Harendal of the Arkandis Digital Foundry (\adf) and information about the fonts themselves can be found at \url{http://arkandis.tuxfamily.org/adffonts.html}. The fonts are released under the \textsc{gnu} General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version, with font exception. For details, see \textsc{notice}.txt and \textsc{copying}.
158 %
159 % The \TeX/\LaTeX\ support package consists of all files listed in \path{manifest.txt}\ and these files are released under the \LaTeX\ Project Public Licence as explained in the included licensing notices. Please let me know of any problems so that I can solve them if I can. If you can correct the problems and send me the fix, that would be even better. Unlike the fonts themselves, the \TeX/\LaTeX\ support is still somewhat experimental.
160 %
161 % \section{The collection}
162 %
163 % Libris \adf\ is a sans-serif family with lining figures. The family currently includes upright and italic shapes in each of regular and bold weights. The support package renames the fonts according to the Karl Berry fontname scheme and defines two families. The first of these is primarily designed to provide access to the ``standard'' or default characters while the second ``swash'' family supports alternate characters and additional ligatures. The included package files provide access to these features in \LaTeX\ as explained in \fref{sec:support} and \fref{sec:commands}.
164 %
165 % \begin{table}
166 % \centering
167 % \caption{LibrisADF original and Berry font names.}\label{tab:fonts}
168 % \begin{tabular}{llll}
169 % \toprule
170 % {\fontseries{b}\selectfont Original grouping} & {\fontseries{b}\selectfont\TeX\ directory/group} & {\fontseries{b}\selectfont Original} \textbf{name} & {\fontseries{b}\selectfont\TeX\ name}\\\midrule
171 % Libris-Std & libris & LibrisADFStd-Regular & ylyr8a\\
172 % & & LibrisADFStd-Italic & ylyri8a\\
173 % & & LibrisADFStd-Bold & ylyb8a\\
174 % & & LibrisADFStd-BoldItalic & ylybi8a\\
175 % \bottomrule
176 % \end{tabular}
177 % \end{table}
178 %
179 % \section{Requirements}
180 %
181 % Apart from such obvious requirements as \LaTeXe, the \LaTeX\ support provided by \path{libris.sty} requires \lpack{nfssext-cfr}.
182 % Without this, you will get errors complaining that the package cannot be found and you will not be able to use any of the additional font commands described in \fref{sec:commands}.
183 %
184 % The documentation requires in addition:
185 % \begin{itemize}
186 % \item \lpack{array}
187 % \item \lpack{babel}
188 % \item \lpack{bookmark}
189 % \item \lpack{booktabs}
190 % \item \lpack{caption}
191 % \item \lpack{csquotes}
192 % \item \lpack{enumitem}
193 % \item \lpack{fancyhdr}
194 % \item \lpack{fancyref}
195 % \item \lpack{fixfoot}
196 % \item \lpack{geometry}
197 % \item \lpack{hyperref}
198 % \item \lpack{lm}
199 % \item \lpack{microtype}
200 % \item \lpack{xcolor}
201 % \item \lpack{xurl}
202 % \end{itemize}
203 %
204 % Note that creating the font files, as opposed to just the package and documentation files, \emph{requires} \texttt{l3build} and a set of custom \texttt{lua} scripts available on \texttt{codeberg}.
205 % More specifically, if you want to build the font definition files (\texttt{.fd}) yourself, you \emph{must} use \texttt{l3build fnttarg} and this requires files available from the code repository, but not included in this package.
206 %
207 % The reason for this is that \lpack{fontinst} provides no way\footnote{Or no way I've yet discovered.} to enable variable scaling.
208 % While it is entirely possible to scale a font by any factor you please, it is not, as far as I can tell, possible to enable scaling by any factor a user later pleases.
209 % In particular, while it is possible to define shapes and families to use a variable factor, it is not possible to write a definition of that factor into the font definition file, which is the way variable scaling is usually configured.
210 %
211 % In order to enable this functionality, \texttt{lua} is used to inject the relevant code into the \texttt{.fd} files after \lpack{fontinst} has generated them.
212 % If you simply process the relevant \TeX{} files by hand, you will create broken definition files, since the code produced by \lpack{fontinst} assumes the relevant lines have been injected.
213 %
214 % \section{The support package}\label{sec:support}
215 %
216 % \subsection{Encodings}
217 %
218 % The package supports modified \textsc{ec}/\textsc{t1} and Text Companion (\textsc{ts1}) encodings. Most characters in the \textsc{ec} encoding are available and the fonts provide a small number of characters from the \textsc{ts1} encoding as well, including the \texteuro. The regular version of the \textsc{ec}/\textsc{t1} encoding (\path{t1-libris.enc}) reassigns three slots which would otherwise be empty due to missing glyphs which \path{fontinst} cannot fake. In the \textsc{t1} encoding, these slots are standardly used for the per thousand zero and the Sami Eng/eng characters (\NG/\ng). \path{t1-libris.enc} uses them for three additional ligatures (`\textsf{tt}', `\textsf{fj}' and `\textsf{ffj}').
219 %
220 % The ‘swash’ version of the \textsc{ec}/\textsc{t1} encoding (\path{t1-librisswash.enc}) provides access to the full range of ligatures available, in addition to replacing default glyphs by alternates. Because additional slots are required to accommodate the additional ligatures, a number of characters normally available in the \textsc{ec} encoding are unavailable. These are the \textsc{ascii} circumflex (\textsf{\textasciicircum}), the \textsc{ascii} tilde (\textsf{\textasciitilde}), the IJ/ij ligature (\textsf\IJ/\textsf\ij), dbar (\textsf\dj), the Eth/eth (\textsf\DH/\textsf\dh) and the Thorn/thorn (\textsf\TH/\textsf\th). Attempting to access these characters while using this font may result in errors of various kinds and will certainly produce unexpected output even though the characters are provided by the font, as the previous sentence demonstrates. To access these glyphs, ensure that the regular version of the font is active.
221 %
222 % \subsection{\LaTeX\ package}
223 %
224 % To use the fonts in a \LaTeX\ document, add \verb|\usepackage{libris}| to your document preamble. This will set the default sans-serif family to \fname{yly} (\fgroup{libris}) and enable access to the various alternates and additional glyphs available in \fname{ylyw}.
225 %
226 % Note that loading \path{libris.sty} will not affect the default roman family or, therefore, the default document font. To use \fgroup{libris} (\fname{yly}) as the default document font, add the line \verb|\renewcommand{\familydefault}{\sfdefault}| to your preamble as well.
227 %
228 % \section{Additional font selection commands}\label{sec:commands}
229 %
230 % The \LaTeX\ package \lpack{libris}\ loads \lpack{nfssext-cfr}\ which is an extension of the package \lpack{nfssext}\ supplied by Philipp Lehman as part of The Font Installation Guide. The file extends the font selection commands to facilitate access to various font features. Both the original and the extension are designed for use with a wide range of fonts. For this reason, only a subset of the additional commands are relevant to any particular font support package. Those relevant to \lpack{librisadf}\ are described below.
231 %
232 % I consider my additions to \lpack{nfssext-cfr}\ to be \emph{highly experimental}. If things don't work as advertised, apart from letting me know about the problem, you may be able to access the features you need by issuing a \verb|\normalfont| and then selecting features from there. This command will return you to the default document text font --- typically the relevant serif in regular weight, standard width and upright shape with oldstyle or lining figures etc.\ as determined by the packages and options loaded or your distribution's setup.
233 %
234 % \subsection{nfssext-cfr}
235 %
236 % These commands are available when \lpack{libris} is loaded. If for some reason you wish to make them available when no relevant package is loaded, use \verb|\usepackage{nfssext-cfr}| in your document preamble.
237 %
238 % \subsubsection{Styles}
239 %
240 % Commands for switching to the ‘swash’ variant, which provides more ligatures and alternate characters are shown in \fref{tab:styles}.
241 % \begin{table}
242 % \centering
243 % \caption{LibrisADF styles.}\label{tab:styles}
244 % \begin{tabular}{lll}
245 % \toprule
246 % \textbf{style} & \textbf{style command} & \textbf{text command}\\\midrule
247 % swash & \verb|\swashstyle| & \verb|\textswash{}|\\
248 % \bottomrule
249 % \end{tabular}
250 % \end{table}
251 %
252 % For example, if \lpack{libris}\ was loaded then:
253 % \begin{verbatim}
254 % \newcommand*{\fytext}{%
255 % ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrs{}tuvwxyz\\
256 % 0123456789 \textonequarter \textonehalf \textthreequarters \textsurd \texttimes
257 % \textdiv \textpm\ \& \texteuro \textcent \textsterling \textcurrency \textyen
258 % \textflorin \textdollar\ \textregistered \textcopyright \texttrademark
259 % \textestimated \textnumero\ \textohm \textmu\ \textsection \textparagraph\
260 % \textdagger \textdaggerdbl\ \textcelsius\\
261 % Sphinx of black quartz, judge my vow.\\
262 % The quick brown fox jumps over the lazy dog.\\
263 % The quick bronzing wax lay over the impish fjord.\\
264 % A churlish skittish bespectacled clerk strictly slacks.}
265 % \newcommand*{\fytest}{\fytext\\[.5em]\textswash{\fytext}}
266 % \textsf{%
267 % \fytest\\[1em]
268 % \textit{\fytest}\\[1em]
269 % \textbf{\fytest}\\[1em]
270 % \textbf{\textit{\fytest}}}
271 % \end{verbatim}
272 % produces:
273 % \begin{center}
274 % \newcommand*{\fytext}{%
275 % ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrs{}tuvwxyz\\
276 % 0123456789 \textonequarter \textonehalf \textthreequarters \textsurd \texttimes
277 % \textdiv \textpm\ \& \texteuro \textcent \textsterling \textcurrency \textyen
278 % \textflorin \textdollar\ \textregistered \textcopyright \texttrademark
279 % \textestimated \textnumero\ \textohm \textmu\ \textsection \textparagraph\
280 % \textdagger \textdaggerdbl\ \textcelsius\\
281 % Sphinx of black quartz, judge my vow.\\
282 % The quick brown fox jumps over the lazy dog.\\
283 % The quick bronzing wax lay over the impish fjord.\\
284 % A churlish skittish bespectacled clerk strictly slacks.}
285 % \newcommand*{\fytest}{\fytext\\[.5em]\textswash{\fytext}}
286 % \textsf{%
287 % \fytest\\[1em]
288 % \textit{\fytest}\\[1em]
289 % \textbf{\fytest}\\[1em]
290 % \textbf{\textit{\fytest}}}
291 % \end{center}
292 %
293 %
294 % \appendix
295 %
296 % \DeclareFixedFootnote \fnupdmap {%
297 % See, for example, \href{https://tex.stackexchange.com/q/255709/}{Why shouldn't I use \texttt{getnonfreefonts} to install additional fonts? Why shouldn't I use \texttt{updmap} when installing or removing fonts?}.}
298 %
299 % \section{Installation}
300 %
301 % \textbf{The vast majority of users should IGNORE this section entirely.}
302 % \lpack{librisadf} is included in all major \TeX{} distributions and should be installed as part of your \TeX{} installation.
303 % Installing the package yourself should be done only as a last resort or an educational exercise.
304 %
305 % Note, in particular, that this version of \lpack{librisadf} should \textbf{not} be installed on older \LaTeX{} kernels as it is designed to work with the (New) New Font Selection Scheme, as updated around 2020\footnote{%
306 % The package should\texttrademark{} work fine on older kernels, but the new version is bound to have some bugs and there is no reason to use it on these systems.
307 % The sole purpose of the update is to accommodate the breaking changes made to font selection.
308 % If you don't have those changes installed locally, nothing should be broken and the newer version of \lpack{librisadf} offers no advantage at all.%
309 % }.
310 % Use the initial release of \lpack{librisadf} if your installation of \LaTeX{} predates those changes.
311 %
312 % Installation varies with \TeX\ distribution so you should consult the documentation which came with your system for details.
313 % In most cases, you will need to perform three steps:
314 % \begin{enumerate}
315 % \item move or copy the package files to appropriate locations on your system;
316 % \item refresh the \TeX\ database;
317 % \item incorporate the included map file fragments for the different engines your distribution supports.
318 % \end{enumerate}
319 %
320 % The following instructions assume you are using \TeX~Live\footnote{This includes Mac\TeX\ for OS X users.}.
321 % They should not be too difficult to adapt if you are using a different distribution.
322 %
323 % \subsection{Install the files}
324 %
325 % The files should be installed in one of two locations: \emph{either} the local system-wide \TeX\ tree \emph{or} your personal tree.
326 % If the package is installed system-wide, all users will have access to it.
327 % On the other hand, you may need privileges you do not have to do this in which case you must use your personal tree.
328 %
329 % \textbf{There are serious disadvantages to installing the package into your personal tree.
330 % In particular, these pertain to use of \verb|updmap --user| rather than \verb|updmap --sys|.
331 % If you are not aware of these disadvantages, please ensure you are fully cognisant of them before proceeding\fnupdmap.
332 % Merely removing the package from your personal tree at a later point will \emph{not} undo the effects.}
333 %
334 % For \TeX~Live, \verb|kpsewhich -var-value TEXMFLOCAL| will return the path to the local tree and \verb|kpsewhich -var-value TEXMFHOME| the path to your personal tree.
335 % The package already includes a hierarchy of files to help you install them correctly.
336 % Ignoring any symbolic link in the top directory, move or copy the files in \path{doc}, \path{fonts} and \path{tex} into the appropriate locations.
337 % If the tree is initially empty, you can simply move or copy the directories in as they are.
338 % If the tree already contains other packages, you may need to merge the package hierarchy with the pre-existing one.
339 % For example, if you already have a \path{doc/fonts} directory, move or copy \path{doc/fonts/libris} into \path{doc/fonts/}.
340 % If you have a \path{doc} directory but not a \path{doc/fonts}, move \path{doc/fonts} into \path{doc/}.
341 %
342 % \subsection{Refresh the database}
343 %
344 % Again, this depends on your distribution. For \TeX~Live, \verb|mktexlsr <path to directory>| for the directory you used in the first step should do the trick.
345 % Note that you \emph{may} be able to skip this step if you install into your personal tree.
346 % Whether this is so depends on the details of your set-up.
347 % As a test, move to a directory containing none of the package files and try \verb|kpsewhich libris.sty|.
348 % If the file is found, you don't need to refresh the database; otherwise use \verb|mktexlsr| and then try again.
349 %
350 % \subsection{Install the map fragments}
351 %
352 % For \TeX~Live, there are at least two ways of doing this.
353 % The second method varies according to the version of \TeX~Live and instructions are provided accordingly.
354 % Both methods depend on whether you installed into \verb|TEXMFLOCAL| or \verb|TEXMFHOME|.
355 % If you installed system-wide, the choice is relatively straightforward --- it obviously makes sense in that case to update the font maps system-wide as well.
356 %
357 % If, on the other hand, you installed into your personal tree, the matter is more complex.
358 % On the one hand, updating the system-wide maps may create difficulties or confusion for other users because while the map files will list the fonts as available, they will not be able to access them.
359 % On the other hand, maintaining personal font map files can produce difficulties and confusions of its own\fnupdmap.
360 % Whether it is to be preferred or not is a complex issue and depends on the details of your \TeX\ distribution, local configuration and personal preference.
361 % The one clear case is that in which you install into your personal tree because you lack the privileges needed to install system-wide.
362 % In that case, you have no choice but to maintain personal font map files or forgo the use of all fonts not provided by your administrator.
363 % Other cases are thankfully beyond the scope of this document.
364 %
365 % \subsubsection{Method 1}
366 %
367 % If you installed the package system-wide, use the command:
368 % \iffalse
369 %^^A ateb Heiko Oberdiek: https://tex.stackexchange.com/a/172896/
370 %^^A dyw hwn ddim yn gweithio tu mewn i arg macro!
371 %^^A (*wrth gwrs* dyw e ddim yn weithio! wyt ti'n *hollol* dwp?)
372 %<*verb>
373 % \fi
374 \begin{verbatim}
375 updmap-sys --enable Map=yly.map
376 \end{verbatim}
377 % \iffalse
378 %</verb>
379 % \fi
380 %
381 % If you installed the package in your personal tree, you \emph{may} prefer\fnupdmap:
382 % \iffalse
383 %<*verb>
384 % \fi
385 \begin{verbatim}
386 updmap --enable Map=yly.map
387 \end{verbatim}
388 % \iffalse
389 %</verb>
390 % \fi
391 % Either way, \verb|updmap| will output a good deal of information after each incantation.
392 % This is normal.
393 % Just check that it does not end with an error and that it found the new map file.
394 %
395 % \subsubsection{Method 2: \TeX~Live 2008 (and probably earlier)}
396 %
397 % If you installed the package system-wide, use \verb|updmap-sys --edit|.
398 %
399 % If you installed into your personal tree, you \emph{may} prefer to use \verb|updmap --edit|\fnupdmap.
400 %
401 % Either way, a configuration file will be opened which you can edit.
402 % Move to the end of the file and add the following line:
403 % \iffalse
404 %<*verb>
405 % \fi
406 \begin{verbatim}
407 Map yly.map
408 \end{verbatim}
409 % \iffalse
410 %</verb>
411 % \fi
412 % When you are done, save the file.
413 % \verb|updmap| or \verb|updmap-sys| will produce a great deal of output if all is well.
414 % Just check that it does not end with an error and that \path{yly.map} is found.
415 %
416 % \subsubsection{Method 2: \TeX~Live 2009 (and possibly later)}
417 %
418 % If you installed the package system-wide, edit or or create \path{TEXMFLOCAL/web2c/updmap-local.cfg} and add the following line to the end of the file:
419 % \iffalse
420 %<*verb>
421 % \fi
422 \begin{verbatim}
423 Map yly.map
424 \end{verbatim}
425 % \iffalse
426 %</verb>
427 % \fi
428 % Save the file and tell \verb|tlmgr| to merge in your addition using the command:
429 % \iffalse
430 %<*verb>
431 % \fi
432 \begin{verbatim}
433 tlmgr generate updmap
434 \end{verbatim}
435 % \iffalse
436 %</verb>
437 % \fi
438 % \verb|tlmgr| will then tell you that you need to ensure the changes are propagated correctly by calling \verb|updmap-sys|.
439 % This should produce a great deal of output.
440 % Check that it finds the new map file and does not end with an error.
441 %
442 % If you installed into your personal tree, you \emph{may} prefer to use \verb|updmap --edit| as described above for \TeX~Live 2008\fnupdmap.
443 %
444 % \subsubsection{Method 3: Current/Recent \TeX~Live}
445 %
446 % If you installed the package system-wide, tell \cs{updmap} to enable the map file:
447 % \iffalse
448 %<*verb>
449 % \fi
450 \begin{verbatim}
451 updmap --sys --enable Map=yly.map
452 \end{verbatim}
453 % \iffalse
454 %</verb>
455 % \fi
456 % This should produce a great deal of output.
457 % Check that it finds the new map file and does not end with an error.
458 %
459 % If you installed into your personal tree, you \emph{could} use \verb|updmap --user| in place of \verb|updmap --sys| as described above for \TeX~Live 2008, but this is \textbf{not} recommended\fnupdmap.
460 %
461 % To test your installation and that the package works on your system, latex this file (\path{librisadf.tex}).
462 % The console output and/or log should tell you whether any fonts were not found.
463 % If you are careful not to overwrite it, you may also compare your output with \path{librisadf.pdf}.%
464 %
465 % \MaybeStop{%
466 % \PrintChanges
467 % \PrintIndex
468 % }
469 %
470 % \section{Implementation}
471 %
472 % You do not need to read the remainder of this document in order to install
473 % or use the fonts.
474 %
475 % \iffalse
476 %<*sty>
477 % \fi
478 % \begin{macrocode}
479 \NeedsTeXFormat{LaTeX2e}
480 \RequirePackage{svn-prov}
481 \ProvidesPackageSVN[libris.sty]{$Id: librisadf.dtx 10402 2024-09-27 02:35:48Z cfrees $}[v1.1 \revinfo]
482 \DefineFileInfoSVN[libris]
483 \RequirePackage[T1]{fontenc}
484 \RequirePackage{nfssext-cfr}[2024/01/01]
485 % \end{macrocode}
486 % \lpack{nfssext-cfr} provides \cs{ProcessKeyOptions}, \cs{IfFormatAtLeastTF} on older kernels.
487 % \begin{macrocode}
488 \IfFormatAtLeastTF {2020-02-02}{%
489 % \end{macrocode}
490 % To get the available ASCII accents etc.\ used from TS1, we need to set the subset to 0 or 1.
491 % Unfortunately, this means characters missing from the fonts will not use default symbols as fallback, but this seems to be unavoidable.
492 % Note this approach is at odds with the kernel's: the kernel prefers losing font-specific glyphs to missing glyphs, whereas we prefer missing to lost glyphs\footnote{%
493 % I probably wouldn't do this for a non-Arkandis font with coverage as poor as Lbris's, where it is markedly less plausible than is the case for something like Electrum.
494 % But note that some Arkandis fonts include glyphs deemed to exist only in \TeX-world fonts by the architects of \LaTeX's TS1 support, which also seems more aimed at \texttt{autoinst}-installed fonts than use of \texttt{fontinst}.
495 % But maybe there is a better solution I'm just not seeing here \dots?%
496 % }.
497 % \begin{macrocode}
498 \DeclareEncodingSubset{TS1}{yly}{1}%
499 \DeclareEncodingSubset{TS1}{ylyw}{1}%
500 }{%
501 \RequirePackage{textcomp}}
502 \UndeclareTextCommand{\textperthousand}{T1}
503 \ExplSyntaxOn
504 % \end{macrocode}
505 % The actual \verb|sty| is ultra simple.
506 % Only a single option is provided, in case the fonts should be scaled.
507 % \texttt{scale} takes a factor by which to scale the fonts.
508 % This is empty by default, which is equivalent to \texttt{1}, but more efficient.
509 % \begin{macrocode}
510 \keys_define:nn { libris }
511 {
512 scale .tl_set:N = \yly@scale,
513 scale .initial:V = \@empty,
514 }
515 % \end{macrocode}
516 % Note the optional argument is mandatory in case we're on an older kernel.
517 % \begin{macrocode}
518 \ProcessKeyOptions[libris]
519 \ExplSyntaxOff
520 \renewcommand{\sfdefault}{yly}
521 %% end libris.sty
522 %^^A paid â chynnwys \endinput - docstrip yn chwilio amddo fe yn arbennigol
523 %^^A & bydd doctrip yn ei ychwanegu fe beth bynnag
524 %^^A (Martin Scharrer: https://tex.stackexchange.com/a/28997/)
525 %% end libris.sty
526 % \end{macrocode}
527 % \iffalse
528 %</sty>
529 % \fi
530 %
531 % The remaining files are not used directly, but are required to generate the files which allow \TeX{} and \LaTeX{} to use the fonts.
532 % The sources use \verb|fontinst| as explained in the (sparse) comments.
533 % While you can install these files into a \TeX{} tree, they are not required for typesetting.
534 %
535 % \subsection{Driver}
536 %
537 % The file does all the initial setup of the fonts.
538 % It organises the fonts into families, defines shapes and reencodes as required.
539 %
540 % \iffalse
541 %<*drv>
542 % \fi
543 % \begin{macrocode}
544 \input fontinst.sty
545 \needsfontinstversion{1.926}
546 % \end{macrocode}
547 % Substitutions
548 % Bold for bold extended
549 % \begin{macrocode}
550 \substitutesilent{bx}{b}
551 % \end{macrocode}
552 % upright for small-caps
553 % \begin{macrocode}
554 \substitutesilent{sc}{n}
555 % \end{macrocode}
556 % italic for oblique
557 % \begin{macrocode}
558 \substitutesilent{sl}{it}
559 % \end{macrocode}
560 % italic for italic small-caps
561 % \begin{macrocode}
562 \substitutesilent{scsl}{sl}
563 \substitutesilent{scit}{scsl}
564 \substitutesilent{si}{scit}
565 % \end{macrocode}
566 % Record transformations for later map file creation
567 % \begin{macrocode}
568 \recordtransforms{yly-rec.tex}
569 % \end{macrocode}
570 % Allow fonts to be scaled via variable in fd files
571 % Also requires fontinst.lua fnttarg as no means to define variable in fontinst
572 % \begin{macrocode}
573 \declaresize{}{<-> \string\yly@@scale}
574 % \end{macrocode}
575 % Transformations : reencode fonts
576 % \begin{macrocode}
577 \transformfont{ylyr-t1}{\reencodefont{t1-cfr}{\fromafm{ylyr8a}}}
578 \transformfont{ylyri-t1}{\reencodefont{t1-cfr}{\fromafm{ylyri8a}}}
579 \transformfont{ylyb-t1}{\reencodefont{t1-cfr}{\fromafm{ylyb8a}}}
580 \transformfont{ylybi-t1}{\reencodefont{t1-cfr}{\fromafm{ylybi8a}}}
581 \transformfont{ylyr-ts1}{\reencodefont{ts1-euro}{\fromafm{ylyr8a}}}
582 \transformfont{ylyri-ts1}{\reencodefont{ts1-euro}{\fromafm{ylyri8a}}}
583 \transformfont{ylyb-ts1}{\reencodefont{ts1-euro}{\fromafm{ylyb8a}}}
584 \transformfont{ylybi-ts1}{\reencodefont{ts1-euro}{\fromafm{ylybi8a}}}
585 \transformfont{ylyr8s}{\reencodefont{libris-supp}{\fromafm{ylyr8a}}}
586 \transformfont{ylyri8s}{\reencodefont{libris-supp}{\fromafm{ylyri8a}}}
587 \transformfont{ylyb8s}{\reencodefont{libris-supp}{\fromafm{ylyb8a}}}
588 \transformfont{ylybi8s}{\reencodefont{libris-supp}{\fromafm{ylybi8a}}}
589 \input reglyph-yly.tex
590 % \end{macrocode}
591 % Installation: creation of virtual fonts
592 % \begin{macrocode}
593 \installfonts
594 \installfamily{T1}{yly}{}
595 \installfont{ylyr8t}{ylyr-t1,ylyr8sr,newlatin}{t1-libris}{T1}{yly}{m}{n}{}
596 \installfont{ylyri8t}{ylyri-t1,ylyri8sr,newlatin}{t1-libris}{T1}{yly}{m}{it}{}
597 % \end{macrocode}
598 % Repeat for bold fonts
599 % \begin{macrocode}
600 \installfont{ylyb8t}{ylyb-t1,ylyb8sr,newlatin}{t1-libris}{T1}{yly}{b}{n}{}
601 \installfont{ylybi8t}{ylybi-t1,ylybi8sr,newlatin}{t1-libris}{T1}{yly}{b}{it}{}
602 % \end{macrocode}
603 % Swash
604 % \begin{macrocode}
605 \installfamily{T1}{ylyw}{}
606 \installfont{ylyrw8t}{ylyr-t1,ylyr8sr,resetalt,newlatin}{t1-librisswash}{T1}{ylyw}{m}{n}{}
607 \installfont{ylyriw8t}{ylyri-t1,ylyri8sr,resetalt,newlatin}{t1-librisswash}{T1}{ylyw}{m}{it}{}
608 \installfont{ylybw8t}{ylyb-t1,ylyb8sr,resetalt,newlatin}{t1-librisswash}{T1}{ylyw}{b}{n}{}
609 \installfont{ylybiw8t}{ylybi-t1,ylybi8sr,resetalt,newlatin}{t1-librisswash}{T1}{ylyw}{b}{it}{}
610 % \end{macrocode}
611 % Install with TS1 encoding for extra glyphs through textcomp
612 % \begin{macrocode}
613 \installfamily{TS1}{yly}{}
614 \installfont{ylyr8c}{ylyr-t1,ylyr-ts1,ylyr8sr,textcomp}{ts1-euro}{TS1}{yly}{m}{n}{}
615 \installfont{ylyri8c}{ylyri-t1,ylyri-ts1,ylyri8sr,textcomp}{ts1-euro}{TS1}{yly}{m}{it}{}
616 % \end{macrocode}
617 % Repeat for bold fonts
618 % \begin{macrocode}
619 \installfont{ylyb8c}{ylyb-t1,ylyb-ts1,ylyb8sr,textcomp}{ts1-euro}{TS1}{yly}{b}{n}{}
620 \installfont{ylybi8c}{ylybi-t1,ylybi-ts1,ylybi8sr,textcomp}{ts1-euro}{TS1}{yly}{b}{it}{}
621 % \end{macrocode}
622 % Swash
623 % \begin{macrocode}
624 \installfamily{TS1}{ylyw}{}
625 \installfontas{ylyr8c}{TS1}{ylyw}{m}{n}{}
626 \installfontas{ylyri8c}{TS1}{ylyw}{m}{it}{}
627 \installfontas{ylyb8c}{TS1}{ylyw}{b}{n}{}
628 \installfontas{ylybi8c}{TS1}{ylyw}{b}{it}{}
629 \endinstallfonts
630 \endrecordtransforms
631 \bye
632 % \end{macrocode}
633 % \iffalse
634 %</drv>
635 % \fi
636 % \subsection{Map}
637 %
638 % This file is compiled to produce the map file fragment \verb|updmap| needs to install the fonts.
639 % It uses files recorded during compilation of the driver.
640 % \iffalse
641 %<*map>
642 % \fi
643 % \begin{macrocode}
644 \input finstmsc.sty
645 \resetstr{PSfontsuffix}{.pfb}
646 \adddriver{dvips}{yly.map}
647 \adddriver{pltotf}{yly-pltotf.sh}
648 \input yly-rec.tex
649 \donedrivers
650 \bye
651 % \end{macrocode}
652 % \iffalse
653 %</map>
654 % \fi
655 %
656 % \subsection{Encodings}
657 %
658 % \lpack{librisadf} uses several custom encoding files (\texttt{.etx}) to generate the files required to use LibrisADF in \LaTeXe{}.
659 % These are included in the package, listed in \texttt{librisadf-build.pdf} and briefly described in this section.
660 %
661 % \subsubsection{Supplementary (raw)}
662 %
663 % We need an additional ‘raw’ encoding to pick up characters otherwise missed.
664 % Many of these are here just because they are named differently, but this also covers fancy ligatures, alternate styles of digits etc.
665 %
666 % Note that \verb|etx| files may specify raw and/or output encodings.
667 % Those which are specific to LibrisADF are described below and included in this package.
668 % Those which are not are included as separate sources unless provided by \verb|fontinst|.
669 % \begin{itemize}
670 % \item \texttt{libris-supp.etx}
671 % \end{itemize}
672 %
673 % \subsubsection{Reglyph}
674 %
675 % We need to rename characters whose names don't match our TeX font encodings.
676 % \begin{itemize}
677 % \item \texttt{reglyph-yly.tex}
678 % \end{itemize}
679 %
680 % \subsubsection{Encodings (output)}
681 %
682 % These files define variant T1 and TS1 font encodings.
683 % \begin{itemize}
684 % \item \texttt{t1-libris.etx}
685 % \item \texttt{t1-librisswash.etx}
686 % \end{itemize}
687 % In addition to these encodings, we use encoding files supplied by \verb|fontinst|, along with
688 % \begin{itemize}
689 % \item \texttt{t1-cfr.etx}
690 % \item \texttt{ts1-euro.etx}
691 % \end{itemize}
692 %
693 % The \verb|etx| files are not used directly by \LaTeX{} or \TeX.
694 % Where needed, they are processed to produce \verb|enc| files.
695 % In some cases, however, they are not themselves standalone encodings.
696 % Instead, they change how some other encoding is interpreted.
697 %
698 % \subsubsection{MTX}
699 %
700 % \verb|mtx| files are used to build ‘fake’ glyphs where these are missing from the original fonts.
701 % We do not fake small-caps or bold, but only glyphs which can be constructed without altering the original design.
702 %
703 % \verb|mtx| files are also used to adjust or reset kerning.
704 % \lpack{librisadf} uses
705 % \begin{itemize}
706 % \item \texttt{resetalt.mtx}
707 % \end{itemize}
708 % in addition to standard files supplied by \lpack{fontinst}.
709 %
710 % \iffalse
711 %<*ee>
712 % \fi
713 % \begin{macrocode}
714 %% !TEX TS-program = pdflatex
715 %% !TEX encoding = UTF-8 Unicode
716 \documentclass[12pt]{article}
717 \usepackage{libris}
718 \usepackage{csquotes}
719 \MakeAutoQuote{‘}{’}
720 \MakeAutoQuote*{“}{”}
721 \title{\textswash{Libris ADF Sample (yly, ylyw)}}
722 \author{\textswash{splendid spiky strains of active fjords}}
723
724 \providecommand{\zeroslash}{}
725 \providecommand{\textsi}[1]{}
726 \newcommand{\alphaline}{%
727 \begin{flushleft}
728 ABCDEFGHIJKLMNOPQRSTUVWXYZ\par abcdefghijklmnopqrs{}tuvwxyz\par
729 0123456789 f\kern0pt f ff f\kern0pt i fi f\kern0pt j fj f\kern0pt l fl f\kern0pt f\kern0pt i ffi f\kern0pt f\kern0pt j ffj f\kern0pt f\kern0pt l ffl c\kern0pt h ch c\kern0pt k ck c\kern0pt l cl c\kern0pt t ct s\kern0pt h sh s\kern0pt k sk s\kern0pt l sl s\kern0pt p sp s\kern0pt t st t\kern0pt t tt\par
730 % ^^A \^{A} \^{a} \^{C} \^{c} \^{E} \^{e} \^{G} \^{g} \^{H} \^{h} \^{I} \^{i} \^{J} \^{j} \^{O} \^{o} \^{U} \^{u} \^{W} \^{w} \^{Y} \^{y} \capitalcircumflex{A}\par
731 Â â Ĉ ĉ Ê ê Ĝ ĝ Ĥ ĥ Î î Ĵ ĵ Ô ô Û û Ŵ ŵ Ŷ ŷ \capitalcircumflex{A}\par
732 % ^^A \"A \"a \"E \"e \"I \"i \"O \"o \"U \"u \"W \"w \"Y \"y \capitaldieresis{A}\par
733 Ë ë Ï ï Ÿ ÿ \capitaldieresis{A}\par
734 % ^^A \`A \`a \`E \`e \`I \`i \`O \`o \`U \`u \capitalgrave{A}\par
735 À à È è Ì ì Ò ò Ù ù \capitalgrave{A}\par
736 % ^^A \'A \'a \'C \'c \'E \'e \'I \'i \'L \'l \'N \'n \'O \'o \'R \'r \'S \'s \'U \'u \'W \'w \'Y \'y \'Z \'z \capitalacute{A}\par
737 Á á Ć ć É é Í í Ĺ ĺ Ń ń Ó ó Ŕ ŕ Ś ś Ú ú Ý ý Ź ź \capitalacute{A}\par
738 % ^^A \r{A} \r{a}
739 % ^^A \r{U} \r{u}
740 % ^^A \={A} \={a} \={E} \={e} \={I} \={\i} \={O} \={o} \={U} \={u} \AA\ \aa\ \capitalring{A} \capitalmacron{A}\par
741 Ā ā Ē ē Ī ī Ō ō Ū ū \capitalring{A} \capitalmacron{A}\par
742 \u{A} \u{a} \u{E} \u{e}
743 \u{G} \u{g}
744 \H{A} \H{a} \H{U} \H{u} \capitalbreve{A}\par
745 \.{A} \.{a} \.{C} \.{c} \.{E} \.{e}
746 \.{I} \.{i}
747 \.{Z} \.{z}
748 \~A \~a %
749 \~I \~\i\ %
750 \~N \~n \~O \~o %
751 \capitaldotaccent{I} \capitaltilde{A}\par
752 % ^^A Ȧ ȧ İ
753 \par
754 \v{C} \v{c} \v{D} \v{d} \v{E} \v{e} \v{L} \v{l} \v{N} \v{n} \v{R} \v{r} \v{S} \v{s} \v{T} \v{t} \v{Z} \v{z} \capitalcaron{C}\par
755 \k{A} \k{a} %
756 \k{E} \k{e} %
757 \c{C} \c{c} \c{D} \c{d} \c{E} \c{e} \c{G} \c{g} \c{K} \c{k} \c{L} \c{l} \c{N} \c{n} \c{R} \c{r} \c{S} \c{s} \c{T} \c{t} \capitalogonek{A} \capitalcedilla{C}\par
758 \O\ \o\ \AE\ \ae\ \OE\ \oe\ \L\ \l\smallskip\par
759 <\kern0pt< << >\kern0pt> >> - -\kern0pt- -- -\kern0pt-\kern0pt- ---\par
760 \& \texteuro\ \textdollar\ \textsterling\ \textyen\ \textcurrency\ \textflorin\ \textcent\ \textohm\ \textmu\ \textcelsius\ \textnumero\ \textdiv\ \texttimes\ \textpm\ \textregistered\ \textcopyright\ \texttrademark\ \textparagraph\ \textestimated\ \textonequarter\ \textonehalf\ \textthreequarters\ \textonesuperior\ \texttwosuperior\ \textthreesuperior\par\ \textservicemark\smallskip\par
761 Sphinx of black quartz, judge my vow.\par
762 The quick brown fox jumps over the lazy dog.\par
763 Somewhat splendid fjords act last.\par
764 A churlish skittish lisping clerk strictly slows.
765 \end{flushleft}%
766 }
767 \newcommand{\alphatest}{%
768 \begin{flushleft}
769 {\upshape upright shape:\par \alphaline}\smallskip\par
770 {\itshape italics:\par \alphaline}\smallskip\par
771 {\bfseries
772 {\upshape upright shape:\par \alphaline}\smallskip\par
773 {\itshape italics:\par \alphaline}\smallskip\par}
774 \end{flushleft}}
775
776 \pdfmapfile{+yly.map}
777 \usepackage{libris}
778 \renewcommand\thepage{\textsf{\arabic{page}}}
779 \begin{document}
780 \sffamily
781 \maketitle
782 \setlength{\parindent}{0pt}
783
784 \section*{regular modified encoding (yly)}
785
786 A sans-serif family with lining figures.
787
788 \alphatest
789
790 \section*{alternative modified encoding (ylyw)}
791
792 \swashstyle
793 A ‘swash’ variant with alternate characters and additional ligatures:
794
795 \alphatest
796
797 \end{document}
798 % \end{macrocode}
799 % \iffalse
800 %</ee>
801 % \fi
802 %\Finale
803 %^^A vim: tw=0: