Debian Codegraph @

texmf-dist/doc/latex/biblatex-opcit-booktitle/documentation/biblatex-opcit-booktitle.tex

raw
1 \documentclass{ltxdockit}[2011/03/25]
2 \usepackage{btxdockit}
3 \usepackage{fontspec}
4 \usepackage[mono=false]{libertine}
5 \usepackage{microtype}
6 \usepackage[american]{babel}
7 \usepackage[strict]{csquotes}
8 \setmonofont[Scale=MatchLowercase]{DejaVu Sans Mono}
9 \usepackage{shortvrb}
10 \usepackage{pifont}
11 \usepackage{minted}
12 \setminted{breaklines}
13 \hypersetup{citecolor=black}
14 % Usefull commands
15 \newcommand{\biblatex}{biblatex\xspace}
16 \newcommand{\meta}[1]{\texttt{<#1>}}
17 \pretocmd{\bibfield}{\sloppy}{}{}
18 \pretocmd{\bibtype}{\sloppy}{}{}
19 \newcommand{\namebibstyle}[1]{\texttt{#1}}
20 % Meta-datas
21 \titlepage{%
22 title={\emph{Op. cit.} for booktitle field},
23 subtitle={Abbreviated references},
24 email={maieul <at> maieul <dot> net},
25 author={Maïeul Rouquette},
26 revision={1.9.0},
27 date={2018/10/24},
28 url={https://git.framasoft.org/maieul/biblatex-opcit-booktitle}}
29
30 % biblatex
31 \usepackage[citestyle=verbose-trad2]{biblatex}
32 \addbibresource{biblatex-opcit-booktitle-example.bib}
33 \usepackage{biblatex-opcit-booktitle}
34
35 \begin{document}
36
37 \printtitlepage
38 \tableofcontents
39
40
41 \section{Aim of the package}
42
43 The default citation styles \verb+verbose-trad1+;\verb+verbose-trad2+;\verb+verbose-trad3+ use the \emph{op. cit.} form in order to have shorter reference when a title have been already cited.
44
45 However, when you cite two entries which share the same \bibfield{booktitle} but not the same \bibfield{title}, the \emph{op. cit.} mechanism does not work.
46
47 For example we obtain the following example:
48
49 \begin{quotation}
50 \makeatletter
51 \cite{Pleiade_Barnabe}
52
53 \csundef{blx@bsee@\the\c@refsection}
54
55 \cite{Pseudo-Hippolyte}
56
57 \csundef{blx@bsee@\the\c@refsection}
58
59 \cite{Pleiade_Tite}
60
61 \csundef{blx@bsee@\the\c@refsection}
62
63 \cite{Pseudo-Epiphane}
64 \makeatother
65 \end{quotation}
66
67 While we would like to obtain:
68
69 \citereset
70
71
72 \begin{quotation}
73
74 \cite{Pleiade_Barnabe}
75
76 \cite{Pseudo-Hippolyte}
77
78 \cite{Pleiade_Tite}
79
80 \cite{Pseudo-Epiphane}
81 \end{quotation}
82
83 The aim of this package is to enable such abbreviation.
84
85 \section{Use}
86
87 The \verb+biblatex-opcit-booktitle+ package must be loaded after the \verb+biblatex+ package, which must be at version 3.4 or greater. You must use a \verb+verbose-trad+ citation style. For example:
88
89 \begin{minted}{latex}
90 \usepackage[bibstyle=verbose,citestyle=verbose-trad1,citepages=omit]{biblatex}
91 \usepackage{biblatex-opcit-booktitle}
92 \end{minted}
93
94 In order to know when two entry share the same \bibfield{booktitle}, you must use the crossref mechanism of \biblatex. In the case of the previous example, we used:
95 \begin{minted}{latex}
96 @book{Pleiade2,
97 Address = {Paris},
98 Number = {516},
99 Publisher = {Gallimard},
100 Series = {Bibliothèque de la Pléiade},
101 Title = {Écrits apocryphes chrétiens},
102 Volume = {2},
103 Year = {2005}}
104
105 @bookinbook{Pleiade_Barnabe,
106 Annotator = {Enrico Norelli},
107 Crossref = {Pleiade2},
108 Pages = {627-642},
109 Title = {Actes de Barnabé},
110 Translator = {Enrico Norelli}}
111
112 @bookinbook{Pleiade_Tite,
113 Annotator = {Willy Rordorf},
114 Bhg = {1850z},
115 Crossref = {Pleiade2},
116 Pages = {609-615},
117 Title = {Actes de Tite},
118 Translator = {Willy Rordorf}}
119
120 @book{Schermann1907,
121 Address = {Leipzig},
122 Editor = {Theodor Schermann},
123 Publisher = {Teubner},
124 Title = {Prophetarum vitae fabulosae indices apostolorum discipulorumque Domini Dorotheo · Epiphanio · Hippolyto aliisque vindicata},
125 Year = {1907}
126 }
127
128 @bookinbook{Pseudo-Hippolyte,
129 Author = {{Pseudo-Hippolyte}},
130 Crossref = {Schermann1907},
131 Pages = {163-170},
132 Title = {Index apostolorum discipulorumque Domini}}
133
134 @bookinbook{Pseudo-Epiphane,
135 Author = {{Pseudo-Épiphane}},
136 Crossref = {Schermann1907},
137 Pages = {107-126},
138 Title = {Index apostolorum discipulorumque Domini}}
139 \end{minted}
140
141 There is not other thing to do!
142
143 The feature works with these entrytypes: \bibtype{inbook}, \bibtype{incollection}, \bibtype{inproceedings}, \bibtype{bookinbook}.
144
145 If you define a \bibfield{shorttitle} in the main entry, it will be used instead of the full title when we need an abbreviated form.
146 \subsection{Limits}
147
148 We have not implemented options to use abbreviation like \verb+ibid+, because we want to have not ambiguous abbreviated forms.
149
150 If you have redefined the \verb+cite+ bibliographic macro, you must changes:
151 \begin{minted}{latex}
152 \usebibmacro{cite:full}%
153 \usebibmacro{cite:save}
154 \end{minted}
155
156 by:
157
158 \begin{minted}{latex}
159 \usebibmacro{cite:test:ifrelated}
160 \end{minted}
161
162 \subsection{Use in final bibliography}\label{bibliography}
163
164 The package has a \opt{bibliography=<value>} option. \meta{value} can be:
165 \begin{description}
166 \item[shorttitle] the final bibliography will print the short form of \bibfield{booktitle} field, and not the full form;
167 \item[onlyshortitle] like the previous one, but also clear the field related to the main entry (except the editor), like the location, the date, the publisher.
168 \end{description}
169 If loaded, the final bibliography will print the short form of \bibfield{booktitle} field, and not the full form.
170
171
172
173 \subsection{Use with own citation style}
174
175 If you have created your own citation style file (\verb.+cbx.), you must create a bibliographic driver called \verb+inbook:rel:<yourcitationstyle>+. You can look at the model \verb+inbook:rel:verbose-trad-xxx+ in the .sty file, or just use \cs{DeclareBibliographyAlias} to use an already existing model.
176
177 If your citation style is public (i. e. published on CTAN), please contact us: we could provide the bibliographic driver directly in this package.
178
179 If you have created your own \verb+cite+ bibmacro, this bibmacro must call, directly or indirectly the `cite:test:ifrelated` bibmacro (or your adaptation of this bibmacro).
180
181
182 \subsection{Customization}
183
184 You can change the \verb+inbook:rel:verbose-trad-xxx+ bibliographic driver to customize the way the main title is printed, \verb+xxx+ meaning 1, 2, or 3, depending of you specific citation style.
185
186 \subsection{Use with new entrytypes}
187
188 If you create new entrytypes, as the \emph{biblatex-bookintother} package does, you can let know to \emph{biblatex-opcit-booktitle} that these entry types are concerned by using short form of the main entry.
189
190
191 To do it, just add in your \verb+.bbx+ or \verb+.dbx+ file:
192 \begin{minted}{latex}
193 \listadd\opcit@booktitle@entrytypes{<newentrytype>}
194 \end{minted}
195
196 \verb+<newentrytype>+ must be the new sub-entrytype concerned. For example, the \emph{biblatex-bookinother} package contains:
197
198 \begin{minted}{latex}
199 \listadd\opcit@booktitle@entrytypes{inarticle}
200 \end{minted}
201
202 In general, you want to have the volume number after the title of the volume. However, for some case, it could be useful to not have it. In this case, add you subtype entry to the \verb+\opcit@booktitle@entrytypes@novolume+ list. For example, the \emph{biblatex-bookinother} package contains:
203
204 \begin{minted}{latex}
205 \listadd\opcit@booktitle@entrytypes@novolume{inarticle}
206 \end{minted}
207
208 Depending of the fields of the new entry, you could have to modify the \verb+inbook:rel:verbose-trad-xxx+. But in this case, please contact us, in order to know if we could provide a generic mechanism directly in this package.
209 \section{Credits}
210
211
212
213 This package was created for Maïeul Rouquette's phd dissertation\footnote{\url{http://apocryphes.hypothese.org}.} in 2015. It is freely inspired by Paul Stanley code.\footnote{\url{http://tex.stackexchange.com/a/172777/7712}.} It is licensed on the \emph{\LaTeX\ Project Public License}.\footnote{\url{http://latex-project.org/lppl/lppl-1-3c.html}.}
214
215
216 All issues can be submitted, in French or English, in the Framasoft issues page\footnote{\url{https://git.framasoft.org/maieul/biblatex-opcit-booktitle/issues}.}.
217
218
219 \section{Change history}
220
221
222 \begin{changelog}
223
224 \begin{release}{1.9.0}{2018-10-24}
225 \item Add \opt{bibliography} option to the package. See~\ref{bibliography}.
226 \item Avoid side effect when mixing entries with direct booktitle and entry with inherited booktitle.
227 \end{release}
228
229 \begin{release}{1.8.0}{2017-03-27}
230 \item Add support entrytype where you don't need to print volume number.
231 \end{release}
232
233 \begin{release}{1.7.0}{2017-02-08}
234 \item Add support for the \option{citetracker=context} option of \biblatex.
235 \end{release}
236
237 \begin{release}{1.6.0}{2016-09-08}
238 \item Add hooks for new entrytype.
239 \end{release}
240
241 \begin{release}{1.5.0a}{2016-06-12}
242 \item Precisions in the handbook.
243 \end{release}
244
245
246 \begin{release}{1.5.0}{2016-06-09}
247 \item Add error message to know more quickly break compatibility with new releases of biblatex.
248 \end{release}
249
250 \begin{release}{1.4.0}{2016-06-07}
251 \item Use new tool of biblatex 3.4.
252 \item Require biblatex 3.4.
253 \end{release}
254 \begin{release}{1.3.0}{2016-03-27}
255 \item Add \emph{op. cit.} also for verbose-trad1.
256 \item Set the entry type for the \emph{op. cit.} as the entry type of the main entry.
257 \end{release}
258
259 \begin{release}{1.2.0}{2015-10-18}
260 \item Fix bug with internal hyperref.
261 \item Fix shorter form to be consistent with verbose-trad1 and verbose-trad2.
262 \item Use short form of name (idem or just last name, depending of style).
263 \item Change bibliography driver name. If you have customized your bibliographic driver, you should adapt name: \verb+inbook:rel:verbose-trad-1+ or \verb+inbook:rel:verbose-trad-2+ or \verb+inbook:rel:verbose-trad-3+.
264 \end{release}
265
266 \begin{release}{1.1.1}{2015-07-02}
267 \item Fix spurious space.
268 \end{release}
269
270 \begin{release}{1.1.0}{2015-06-18}
271 \item If defined, use the \bibfield{shortitle} field of the main entry.
272 \end{release}
273
274 \begin{release}{1.0.2}{2015-06-05}
275 \item Wrap \enquote{op. cit} in \cmd{mkibid}.
276 \end{release}
277
278 \begin{release}{1.0.1}{2015-06-03}
279 \item Correct order of name's part (first name / last name).
280 \end{release}
281
282 \begin{release}{1.0.0}{2015-05-31}
283 \item First public release.
284 \end{release}
285
286 \end{changelog}
287 \end{document}