summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex')
-rw-r--r--macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex170
1 files changed, 170 insertions, 0 deletions
diff --git a/macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex b/macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex
new file mode 100644
index 0000000000..6a79b52d89
--- /dev/null
+++ b/macros/latex/contrib/biblatex-ms/doc/examples/01-introduction-ms.tex
@@ -0,0 +1,170 @@
+%
+% This file briefly presents the main citation commands. It also
+% illustrates the typical structure of a document based on biblatex.
+%
+\documentclass[a4paper]{article}
+\usepackage[T1]{fontenc}
+\usepackage[utf8]{inputenc}
+%
+% We load the babel package and specify the main language of the
+% document. If babel is detected, biblatex will automatically adjust
+% to the default language of the document.
+\usepackage[american]{babel}
+%
+% We load the csquotes package, which is required for
+% language-specific quotation marks. See the csquotes manual for
+% further information about this package.
+\usepackage{csquotes}
+%
+% We are using the 'authoryear' style in this example.
+% The default is the 'numerical' style.
+\usepackage[style=authoryear,backend=biber]{biblatex-ms}
+%
+% We use the database biblatex-examples.bib.
+\addbibresource{biblatex-examples.bib}
+%
+% Some generic settings.
+\newcommand{\cmd}[1]{\texttt{\textbackslash #1}}
+\setlength{\parindent}{0pt}
+\begin{document}
+
+\section*{Standard citation commands}
+
+\subsection*{The \cmd{cite} command}
+
+% The \cite command prints a bare citation without parentheses.
+
+\cite{companion}
+
+\cite[59]{companion}
+
+\cite[see][]{companion}
+
+\cite[see][59--63]{companion}
+
+\subsection*{The \cmd{parencite} command}
+
+% The \parencite command, which is intended for in-text citations,
+% encloses the citation in parentheses. Note that the 'numeric' and
+% 'alphabetic' styles use square brackets instead.
+
+This is just filler text \parencite{companion}.
+
+This is just filler text \parencite[59]{companion}.
+
+This is just filler text \parencite[see][]{companion}.
+
+This is just filler text \parencite[see][59--63]{companion}.
+
+\subsection*{The \cmd{footcite} command}
+
+% The \footcite command is similar to \parencite, except that the
+% citation is given in a footnote.
+
+This is just filler text.\footcite{companion}
+
+This is just filler text.\footcite[59]{companion}
+
+This is just filler text.\footcite[See][]{companion}
+
+This is just filler text.\footcite[See][59--63]{companion}
+
+\subsection*{The \cmd{textcite} command}
+
+% The \textcite command is intended for citations integrated in the
+% flow of text, replacing the subject of the sentence.
+
+\textcite{companion} show that this is just filler text.
+
+\textcite[59]{companion} show that this is just filler text.
+
+% With \textcite, the first optional argument is of limited use
+% only, since you could simply place the prenote in front of the
+% citation. It is still supported for the sake of consistency.
+
+\textcite[see][]{companion} show that this is just filler text.
+
+\textcite[see][59--63]{companion} show that this is just filler text.
+
+\section*{Style-independent commands}
+
+\subsection*{The \cmd{autocite} command}
+
+% The point of the \autocite command is that it automatically adapts
+% to the predominant citation format (inline or footnote) normally
+% used with the selected citation style. It should be used at the
+% end of the sentence and usually works like \parencite or
+% \footcite, depending on the citation style and the setting of the
+% 'autocite' package option. With the author-year style used in this
+% example, it works like \parencite:
+
+This is just filler text \autocite{companion}.
+
+\section*{Text commands}
+
+% There are a few predefined commands for bibliographic data which
+% is frequently used in the flow of text. Note that biblatex also
+% grants access to all lists and fields at a lower level, see below.
+
+\citeauthor{companion} show that this is just filler text.
+
+% Note that \citetitle will use the 'shorttitle' field, if
+% available.
+
+See the \citetitle{companion} for more filler text.
+
+% \citetitle*, on the other hand, always prints the 'title'
+% field.
+
+See also: \citetitle*{companion}. It has more filler text.
+
+\citetitle*{companion} by \citeauthor{companion} was
+published in \citeyear{companion}.
+
+\section*{Special commands}
+
+% The \nocite command adds an entry to the bibliography without
+% printing any citation. If the argument is an asterisk (i.e.,
+% '\nocite{*}'), all entries found in the bib file are added to the
+% bibliography.
+
+No citation here.\nocite{knuth:ct}
+
+% The \fullcite command prints a verbose citation similar to the
+% full bibliography entry.
+
+\fullcite{companion}
+
+% \footfullcite is similar to \fullcite, except that the citation is
+% put in a footnote.
+
+This is just filler text.\footfullcite{companion}
+
+\section*{Low-level commands}
+
+% The commands in this section grant low-level access to all
+% bibliographic data. See the biblatex manual for details about the
+% different data types (name lists, literal lists, fields).
+
+% The \citename command prints a name list. For example, the
+% \citeauthor command shown above is similar to the following
+% low-level command:
+
+\citename{companion}{author}
+
+% The \citelist command is similar to \citename but prints literal
+% lists.
+
+\citelist{companion}{publisher}
+
+% The \citefield command prints fields. For example, the
+% \citetitle* command shown above is similar to the following
+% low-level command (except for the formatting):
+
+\citefield{companion}{title}
+
+% The list of references is printed by way of \printbibliography.
+
+\printbibliography
+
+\end{document}