summaryrefslogtreecommitdiff
path: root/fonts/dingbat/dingbat.dtx
blob: a30fb904004f7f22161a690a276282159018cc0d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
% \iffalse meta-comment
%
% Copyright (C) 2001 Scott Pakin <pakin@uiuc.edu>
% -------------------------------------------------------
%
% This package may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.2
% of this license or (at your option) any later version.
% The latest version of this license is in
%    http://www.latex-project.org/lppl.txt
% and version 1.2 or later is part of all distributions of LaTeX
% version 1999/12/01 or later.
%
% \fi
% \iffalse
%% File: dingbat.dtx Copyright (C) 2001 Scott Pakin <pakin@uiuc.edu>
%
%<package>\NeedsTeXFormat{LaTeX2e}
%<package>\ProvidesPackage{dingbat}
%<package>         [2001/04/27 v1.00 Hands and other dingbats]
%<uarkfd>\ProvidesFile{uark.fd}
%<uarkfd>          [2001/04/27 v1.00 Font definitions for the ark10 font]
%<udingbatfd>\ProvidesFile{udingbat.fd}
%<udingbatfd>      [2001/04/27 v1.00 Font definitions for the dingbat font]
%
%<*driver>
\documentclass{ltxdoc}
\usepackage{dingbat}
\usepackage{tabularx}
\EnableCrossrefs
\CodelineIndex

% Uncomment the following line if you don't want to include a
% source-code listing.
%\OnlyDescription

\begin{document}
\DocInput{dingbat.dtx}
\end{document}
%</driver>
% \fi
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% \CheckSum{76}
% \GetFileInfo{dingbat.sty}
%
% \title{The \textsf{dingbat} package\thanks{This file
%         has version number \fileversion, last
%         revised \filedate.}}
% \author{Scott Pakin\\pakin@uiuc.edu}
% \date{\filedate}
% \maketitle
%
% \changes{v1.00}{2001/04/27}{Initial version}
%
% \DoNotIndex{\newcommand,\selectfont}
%
% \StopEventually{^^A
%   \section{Credits}
%
%   Just so it's clear who did what, here are the various components of
%   the \textsf{dingbat} package and the associated copyright information:
%
%   \begin{center}
%   \begin{tabularx}{0.9\textwidth}{lX}
%     \texttt{ark10.mf} & Copyright (c) 1988 by Arthur M. Keller \\
%     & The ARK font was initially done in MF79
%       by Scott Kim.  It was converted to (new) MF by N.N. Billawala
%       of Metamarks. \\
%     \texttt{dingbat.dtx} & Copyright (C) 2001 Scott Pakin \\
%     \texttt{dingbat.ins} & Copyright (C) 2001 Scott Pakin \\
%     \texttt{dingbat.mf} & Created 3-3-89 by Doug Henderson \\
%     \texttt{uark.fd} & Copyright (C) 2001 Scott Pakin
%   \end{tabularx}
%   \end{center}
%
%   \PrintIndex
% }
%
% \begin{abstract}
%   The \textsf{dingbat} package provides a \LaTeXe\ interface to the
%   |ark10.mf| and |dingbat.mf| fonts.
% \end{abstract}
%
%
% \section{Usage}
%
% ^^A  Typeset a symbol in one column and its name in the next.
% \def\tblsym#1{#1 & \texttt{\string#1}}
%
% \DescribeMacro{\rightpointright}
% \DescribeMacro{\leftpointright}
% \DescribeMacro{\leftthumbsdown}
% \DescribeMacro{\leftthumbsup}
% \DescribeMacro{\rightpointleft}
% \DescribeMacro{\rightthumbsdown}
% \DescribeMacro{\rightthumbsup}
% The \textsf{dingbat} package defines the following hand gestures:
%
% \begin{center}
% \renewcommand{\arraystretch}{1.2}
% \begin{tabular}{lll}
%   \tblsym{\rightpointright}  & Right hand pointing to the right \\
%   \tblsym{\leftpointright}   & Left hand pointing to the right \\
%   \tblsym{\leftthumbsdown}   & Left hand, thumbs down \\
%   \tblsym{\leftthumbsup}     & Left hand, thumbs up \\
%   \tblsym{\rightpointleft}   & Right hand pointing to the left \\
%   \tblsym{\rightthumbsdown}  & Right hand, thumbs down \\
%   \tblsym{\rightthumbsup}    & Right hand, thumbs up \\
% \end{tabular}
% \end{center}
%
% \noindent
% (|\rightpointright| comes from |dingbat.mf|, while the rest come from
% |ark10.mf|, hence, the discrepency in style.)
%
% \DescribeMacro{\squarewithdots}
% \DescribeMacro{\filledsquarewithdots}
% \DescribeMacro{\Sborder}
% \DescribeMacro{\Zborder}
% The following symbols are intended to be used to create fancy borders
% around a box or the entire page.
%
% \begin{center}
% \renewcommand{\arraystretch}{1.2}
% \begin{tabular}{lll}
%   \tblsym{\squarewithdots}       & Unfilled square with dots \\
%   \tblsym{\filledsquarewithdots} & Filled square with dots \\
%   \tblsym{\Sborder}              & \textit{S}-like border design \\
%   \tblsym{\Zborder}              & \textit{Z}-like border design \\
% \end{tabular}
% \end{center}
% 
% \noindent
% Note that if you \emph{are} going to create fancy borders, I recommend
% using the \textsf{niceframe} package.  \textsf{niceframe} is geared
% to drawing fancy borders and knows specifically about the border
% characters in |dingbat.mf|.  The symbols defined by the
% \textsf{dingbat} package, |\squarewithdots|, |\filledsquarewithdots|,
% |\Sborder|, and |\Zborder|, are the only border characters that might
% be useful outside of a border (e.g., in a straight line or as a bullet
% in a fancy itemized list); the other, unnamed, characters defined in
% |dingbat.mf| represent a frame's corners and sides.
%
% \DescribeMacro{\largepencil}
% \DescribeMacro{\anchor}
% \DescribeMacro{\carriagereturn}
% \DescribeMacro{\checkmark}
% \DescribeMacro{\eye}
% \DescribeMacro{\satellitedish}
% \DescribeMacro{\smallpencil}
% The following \textsf{dingbat} symbols don't fit into either of the
% previous categories:
%
% \begin{center}
% \renewcommand{\arraystretch}{1.2}
% \begin{tabular}{lll}
%   \tblsym{\largepencil}    & Large pencil \\
%   \tblsym{\anchor}         & Anchor \\
%   \tblsym{\carriagereturn} & Carriage return \\
%   \tblsym{\checkmark}      & Check mark \\
%   \tblsym{\eye}            & Eye \\
%   \tblsym{\satellitedish}  & DLA satellite dish \\
%   \tblsym{\smallpencil}    & Small pencil \\
% \end{tabular}
% \end{center}
%
% For some of these symbols, most notably |\largepencil|, the font
% metrics seem to be a bit off.  As a result, the symbols tend to jut
% into previous or subsequent lines.
%
%
% \section{Implementation}
%
% There's nothing particularly interesting about the implementation.
% Section~\ref{sec:symbol-commands} defines the symbol commands that
% make up |dingbat.sty|, and Section~\ref{sec:font-definitions} creates
% the |uark.fd| and |udingbat.fd| font definition files, which \LaTeX\
% loads when |dingbat.sty| selects font encoding~|U| and font family
% |ark| or |dingbat|.
%
% \subsection{Symbol commands}
% \label{sec:symbol-commands}
%
%    \begin{macrocode}
%<*package>
%    \end{macrocode}
%
% \begin{macro}{\arkfamily}
% \begin{macro}{\ark@sym}
% Define a macro, |\arkfamily|, which switches the font to |ark| and
% another macro, |\ark@sym| which typesets a symbol in the |ark| font.
%    \begin{macrocode}
\newcommand{\arkfamily}{\fontencoding{U}\fontfamily{ark}\selectfont}
\newcommand{\ark@sym}[1]{{\arkfamily\symbol{#1}}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\carriagereturn}
% \begin{macro}{\leftthumbsdown}
% \begin{macro}{\eye}
% \begin{macro}{\rightpointleft}
% \begin{macro}{\smallpencil}
% \begin{macro}{\leftpointright}
% \begin{macro}{\leftthumbsup}
% \begin{macro}{\largepencil}
% \begin{macro}{\rightthumbsdown}
% \begin{macro}{\rightthumbsup}
% There are only ten symbols in the |ark| font.  We define names
% individually for each of them.  Note that |\largepencil|'s bounding box
% is a little too short, so |\largepencil| may jut into the previous line
% of text.  I think some of the other bounding boxes may be the wrong
% size, as well, but I haven't yet tested that carefully.
%    \begin{macrocode}
\newcommand{\carriagereturn}{\ark@sym{'103}}
\newcommand{\leftthumbsdown}{\ark@sym{'104}}
\newcommand{\eye}{\ark@sym{'105}}
\newcommand{\rightpointleft}{\ark@sym{'114}}
\newcommand{\smallpencil}{\ark@sym{'120}}
\newcommand{\leftpointright}{\ark@sym{'122}}
\newcommand{\leftthumbsup}{\ark@sym{'125}}
\newcommand{\largepencil}{\ark@sym{'127}}
\newcommand{\rightthumbsdown}{\ark@sym{'144}}
\newcommand{\rightthumbsup}{\ark@sym{'165}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\dingbatfamily}
% \begin{macro}{\dingbat@sym}
% Define a macro, |\dingbatfamily|, which switches the font to |dingbat|
% and another macro, |\dingbat@sym| which typesets a symbol in the
% |dingbat| font.
%    \begin{macrocode}
\newcommand{\dingbatfamily}{\fontencoding{U}\fontfamily{dingbat}\selectfont}
\newcommand{\dingbat@sym}[1]{{\dingbatfamily\symbol{#1}}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\checkmark}
% \begin{macro}{\satellitedish}
% \begin{macro}{\rightpointright}
% \begin{macro}{\anchor}
% The following are definitions for all the non-border characters in
% |dingbat.mf|.
%    \begin{macrocode}
\newcommand{\checkmark}{\dingbat@sym{'104}}
\newcommand{\satellitedish}{\dingbat@sym{'111}}
\newcommand{\rightpointright}{\dingbat@sym{'116}}
\newcommand{\anchor}{\dingbat@sym{'117}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\squarewithdots}
% \begin{macro}{\filledsquarewithdots}
% \begin{macro}{\Sborder}
% \begin{macro}{\Zborder}
% The following are the border characters.  There are many more, but I
% haven't yet made up \LaTeX\ names for them.
%    \begin{macrocode}
\newcommand{\squarewithdots}{\dingbat@sym{'102}}
\newcommand{\filledsquarewithdots}{\dingbat@sym{'103}}
\newcommand{\Sborder}{\dingbat@sym{'123}}
\newcommand{\Zborder}{\dingbat@sym{'132}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
%    \begin{macrocode}
%</package>
%    \end{macrocode}
%
% \subsection{Font definition files}
% \label{sec:font-definitions}
%
% \subsubsection{\ttfamily uark.fd}
%
% All we do here is define |ark| as a symbol font (|U|~encoding) and tell
% \LaTeX\ to scale |ark10.mf| to whatever font size is requested.
%
%    \begin{macrocode}
%<*uarkfd>
%    \end{macrocode}
%
%    \begin{macrocode}
\DeclareFontFamily{U}{ark}{}
\DeclareFontShape{U}{ark}{m}{n}{<-> ark10}{}
%    \end{macrocode}
%
%    \begin{macrocode}
%</uarkfd>
%    \end{macrocode}
%
% \subsubsection{\ttfamily udingbat.fd}
%
% Similarly, we define |dingbat| as another, |U|-encoded symbol font and
% instruct \LaTeX\ to scale |dingbat.mf| to whatever font size is requested.
%
%    \begin{macrocode}
%<*udingbatfd>
%    \end{macrocode}
%
%    \begin{macrocode}
\DeclareFontFamily{U}{dingbat}{}
\DeclareFontShape{U}{dingbat}{m}{n}{<-> dingbat}{}
%    \end{macrocode}
%
%    \begin{macrocode}
%</udingbatfd>
%    \end{macrocode}
%
% \Finale
%