-
Notifications
You must be signed in to change notification settings - Fork 1
/
bibliographyformat.tex
235 lines (211 loc) · 10.2 KB
/
bibliographyformat.tex
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
%\chapter{The Bibliography}
\chapter{参考文献表}
\label{ch:bibliographyformat}
\index{customization!bibliography title|see{bibliography, title}}
\index{customization!bibliography heading|see{bibliography, heading}}
\index{bibliography!printing}
Citations written, we come to the actual printing of the
bibliography. The magic command is:\csindex{printbibliography}\manref{\S~3.7.7}
\begin{center}
\cs{printbibliography}\manref{\S~3.7.2}
\end{center}
And, for simple cases, it may even be as easy as that! But there are
quite a number of refinements.
The refinements can be classified as follows:\marginpar{\footnotesize printbibliography 是打印文献表的基本命令,对其还有做如下几类修改:标题、条目格式、排序、筛选、多文献表。
}
\begin{itemize}
\item Changes to the way the bibliography is headed: what is it
called? Is it treated as if it were a new chapter, or a new section?
How is the heading printed? Is it included in the table of contents?
\item Changes to the appearance of the bibliography items: what font
are they printed in? Are they indented? How? How much?
\item Changes to the way the bibliography is sorted.
\item Selection of the material to be printed in the bibliography: are
all sources cited, or only some? How are they selected?
\item Provisions for creating multiple bibliographies, such as
different bibliographies for different chapters, or different
bibliographies for different topics.
\end{itemize}
The last two items overlap a bit, because in one sense producing
multiple biographies is a matter of selecting what works go in which
bibliography. It's simpler, however, to defer most discussion of this
to a chapter of its own.\intref{Chapter~\ref{ch:subdivisions}} We are
also going to leave sorting for a separate discussion. So this chapter
is really going to concentrate on the headings, the physical format of
the bibliography.
%\section{Headings}
\section{标题}
\indexstart{bibliography!heading}
In a \LaTeX\ document, a heading is more than just its words: a
heading command (such as \cs{chapter} or \cs{section}) doesn't just
print its text, formatted a certain way. It may add a number, and
advance a counter. It may change what gets printed in the running
headers or footers.
\index{bibliography!title} Let's start with the actual title. A
default\footnote{The default is `Bibliography' for books and articles,
and `References' for articles.} will be set by the |heading| option,
described below. The easiest way to change it is using the |title|
option in the \cs{printbibliography} command.
So, for instance, if we wanted to call our bibliography `List of
Sources', we could put the following:
\begin{center}
\cs{printbibliography[title=\{List of Sources\}]}
\end{center}
This is fairly straightforward. Beyond that, some degree of complexity
lurks.
It's all fairly easy if you want to have the bibliography title
treated as if it were a chapter heading (for the |book| and |report|
classes) or a section heading (for the |article| class). This is,
after all, the ordinary case, and \biblatex\ then provides you with
the following options:
\begin{itemize}
\item If \marginnote{\gives\ \textbf{References}\\(not in
table of contents)}you want the heading inserted, but without any
number and without being added to the table of contents, you're all
set. This is what \biblatex\ will do by default.
\item If\marginnote{\gives\ \textbf{References}\\(in table of
contents)} you want the heading added to the table of contents,
but you don't want it numbered, then add the option
|heading=bibintoc| to your \cs{printbibliography} command.
\item If\marginnote{\gives\ \textbf{6.\ References}\\(in table
of contents)} you want the heading numbered and added to the table
of contents, then add the option |heading=bibnumbered| to your
\cs{printbibliography} command.
\end{itemize}
It's also easy enough if you want the bibliography dealt with at
\emph{one level below} the default: in other words, you want it
treated as a section (in the |book| or |report| classes) or
as a sub-section (in the |article| class:
\begin{itemize}
\item To have just the heading (no table of contents or numbering),
choose the option |heading=subbibliography|.
\item To have the heading included in the table of contents, but not
numbered, choose the option |heading=subbibintoc|.
\item To have the heading numbered and included in the table of
contents, choose the option |heading=subbibnumbered|.
\end{itemize}
Finally (and perhaps easiest of all), if you want no heading at all,
just choose |heading=none|.
\newthought{These are all the options} that \biblatex\ gives you by
default. Combined with |title=...| (to overrride the default titles)
this will usually suffice. If, however, you want to define a special
heading for your bibliography, you will need to proceed as
follows:\intref{\emph{Manual} \S\ 3.6.7}
\begin{enumerate}
\item Define a bibliography heading style using\csindex{defbibheading}
\begin{center}
\cs[\angled{title}][\angled{definition}]{defbibheading\{\angled{name}\}}
\end{center}
The \angled{name} is a name you will use, as an option passed to\linebreak
\cs{printbibliography}, to refer to the type of heading that you have
defined; it can be anything you choose. The \angled{title} is the
default title for your heading. The definition part is a complete set
of commands to create a heading and anything (such as the marking of
headers and footers, table of contents, and so forth) that needs to go
with it. It takes the form of a macro definition which assumes it will
be passed the title of the bibliography as its single argument, |#1|.
\item Use the name of the |heading| you have defined as the
|heading| option to your \cs{printbibliography} command.
\end{enumerate}
So, for instance, suppose we wanted to set up our bibliography to be
formatted as a subsection, but without any number; we also want it
added to the table of contents, and we want it to mark both recto and
verso pages. The default title is to be `Works Cited':
\begin{verbatim}
\defbibheading{myheading}[Works Cited]{%
\subsection*{#1}%
\addcontentsline{toc}{subsection}{#1}%
\markboth{#1}{#1}}
\end{verbatim}
There's one tiny trick to bibliography headings. It's normally best to
do all your customization in the preamble of your document, before you
(or \LaTeX) gets to \cs[document]{begin}. But for bibliography
headings (and title, and notes) it's actually better to set them up
after \cs[document]{begin}.
\indexstop{bibliography!heading}
%\section{Bibliography appearance}
\section{文献著录格式}
\indexstart{bibliography!appearance}
The appearance of a bibliography is largely controlled by a
pre-defined bibliography environment. You can change the default by
defining a modified bibliography environment of your own, and then
passing the name of that environment as
\begin{center}
\cs{printbibliography[env=\angled{your environment}]}
\end{center}
\csindex{defbibenvironment}
\index{customization!bibliography appearance}
The environment needs to be set up in advance, for that purpose, you
use the command \cs{defbibenvironment}:
\begin{pseudoverb}
\cs{defbibenvironment}\{\angled{name}\}\{\angled{start}\}\{\angled{end}\}\{\angled{per-item}\}
\end{pseudoverb}
The way this works is as follows:
\begin{description}
\item[\angled{name}] is the name you choose to refer to this style of
environment: it's what you will use with the option \texttt{env=} to
typeset a bibliography using this environment.
\item[\angled{start}] is code to be executed at the beginning of the
bibliography, before any entries are printed. It's customary (though
not essential) to set a bibliography using a list environment of
some sort, and this lets you set that up.
\item[\angled{item}] is code to be executed at the beginning of each
\emph{entry} in the bibliography: for instance \cs{item}.
\item[\angled{end}] is code to be executed at the end of the
bibliography, for instance to end the environment you began with
\angled{start}.
\end{description}
Let's give a practical example. People writing CVs sometimes want to
number the items while using a non-numeric bibliography style, such as
verbose or author-year. Suppose you loaded the |authoryear| style, but
then defined a bibliography environment as follows:
\begin{verbatim}
\defbibenvironment{myenv}
{\begin{enumerate}}
{\end{enumerate}}
{\item}
\end{verbatim}
Now, using
\begin{pseudoverb}
\cs{printbibliography}\relax[env=myenv,heading=myheading]
\end{pseudoverb}
we get
\begin{figure}
\framebox{\includegraphics{./examples/cotton-springer-myenv.pdf}}
\caption{Customized bibliography environment\label{custom-env}}
\end{figure}
\indexstop{bibliography!appearance}
%\section{Other lists and indexing}
\section{其它列表和索引}
\index{shorthand!list of shorthands}
If you use `shorthands'\intref{See p~\pageref{shorthands}} to define abbreviations for particular works, you can print these with the command:
\begin{pseudoverb}
\centering
\cs{printbiblist}[\angled{options}]\{shorthand\}
\end{pseudoverb}
\index{indexing}
You will almost certainly want to provide a suitable title using the
option |title=...|. As the general form of the command suggests, it is
in fact an instance of a general way of printing special forms of
bibliographical list.\manref{\S~3.7.3}
\biblatex\ also enables styles to permit the creation of an
\emph{index} of sources. The details are elaborate, and you will need
to understand something about how \LaTeX's indexing methods work. Some
styles (such as \package{oscola}) make very extensive and complex use
of this facility. But, as it is a rather advanced topic, the curious
reader is referred to the manual, both for \biblatex\manref{\S~3.1.1}
and for any package that is being used.
\index{backreferences|see{bibliography, references}}\index{bibliography!references}
Slightly simpler, however, than an index (which is a separate
document), it is possible also with standard styles to print, in the
bibliography, a list of the pages where the source in question was
referred to. To do this, you pass \biblatex\ the option
|backref=true|. There are various options\manref{\S~3.1.1} for
|backrefstyle| which will determine how back references are actually
printed (for instance, when references in consecutive pages are
compressed).
%%% Local Variables:
%%% coding: utf-8
%%% mode: LaTeX
%%% TeX-master: "biblatex-tutorial"
%%% End: