0

I am using Xelatex for several years. But I never understood, how to make a bibliography with Latex. {thebibliography} works great for me, because it was easy to get my own style. Now I have such a quantity of references, that I need to use Biblatex? Biber? I am confused, what to do now. So, how do I start to use Latex possibilities and at the same time keep up the style I am used to.

I can produce an .bib file, but what should be written in the preamble, so that it looks as if nothing has changed.

I am thankfully for every hint...

    \documentclass[12pt,headsepline,pagesize=auto,ngerman,greek,hebrew,english,russian,latin,bibliography=totocnumbered,twoside]{scrreprt}\usepackage[a4paper,left=2.25cm, right=2.5cm,top=2.75cm,bottom=2.25cm]{geometry}
\usepackage{blindtext}
\usepackage{cite}
\renewcommand{\citeleft}{}
\renewcommand{\citeright}{.}
\renewcommand{\thefootnote}{\arabic{footnote}} 
\deffootnote{2em}{2.5em}{\makebox[2em][l]{\textsuperscript{\thefootnotemark}}} 
\let\footnoteold=\footnote\renewcommand{\footnote}[1]{\renewcommand{\baselinestretch}{1.0}\footnoteold{#1}} 
\raggedbottom
\newcommand{\enquote}[1]{»#1«}


\begin{document}

Book\footnote{Vgl. \cite[123]{serresparasit}}

Article\footnote{Vgl. \cite[123]{Steiger}}

Article in a Book\footnote{Vgl. \cite[123]{rationalclowns}}

Internet\footnote{Vgl. \cite[123]{meeksaufsatz}}

\begin{thebibliography}{99} 
\itemindent -1cm
\leftmargin 1.25cm
\makeatletter
\renewcommand\@biblabel[1]{}
\makeatother
\providecommand{\natexlab}[1]{#1}
\providecommand{\url}[1]{\texttt{#1}}
\providecommand{\urlprefix}{URL }
\expandafter\ifx\csname urlstyle\endcsname\relax
\providecommand{\doi}[1]{doi:\discretionary{}{}{}#1}\else
\providecommand{\doi}{doi:\discretionary{}{}{}\begingroup
\urlstyle{rm}\Url}\fi \providecommand{\eprint}[2][]{\url{#2}}
\parskip 0pt minus 2pt

%\bibitem[{\textsc{}: \textit{} ()}]{}
%\textsc{} [] \textit{}, 
% : .
%bibfindex&&&
%\bibitem[{\textsc{}: \textit{} (1986)}]{}
%\textsc{} [] \enquote{}, 
% S.\,in:
% (Hg.), \textit{}, 
% : . 

\bibitem[{\textsc{Serres}: \textit{Der Parasit} (2014)}]{serresparasit} 
\textsc{Serres, Michel} [2014] \textit{Der Parasit}, Suhrkamp: Frankfurt am Main.

\bibitem[{\textsc{Meeks}: \textit{Economy of Grace and the Market Logic} (2004)}]{meeksaufsatz}
\textsc{Meeks, M. Douglas} [2004] \enquote{The Economy of Grace and the Market Logic}, 
 abgerufen am 13.12.2016 unter \url{http://www.councilofchurches.ca/xxx.pdf}. 

\bibitem[{\textsc{Sen}: \textit{Rationalclowns} (2014)}]{rationalclowns}
\textsc{Sen, Amartya K.} [2014] \enquote{Rationalclown: Eine Kritik der behavioristischen grundlagen der Wirtschaftstheorie}, 
 S.\,438--469 in: Honneth, Axel; Herzog, Lisa (Hgg.), \textit{Der Wert des Marktes: Ein ökonomisch-philosophischer Diskurs vom 18.\,Jahrhundert bis zur Gegenwart},  Suhrkamp: Berlin.

 \bibitem[{\textsc{Steiger}: \textit{Communicatio Idiomatum} (1996)}]{Steiger}
\textsc{Steiger, Johann Anselm} [1996] \enquote{Die communicatio idiomatum als Achse und Motor der Theologie Luthers},
 S.\,1--28 in: \textit{NZSTh 38}.

\end{thebibliography}
\end{document}

I produced a minimal example. How do I define my own style? Is it possible to describe the appearance of the entries as I did it before, or do I have to adjust an existing format.

   %jobname NICHT ersetzen 
\begin{filecontents}{\jobname.bib} 
@webpage{meeksaufsatz,
    Author = {Douglas M. Meeks},
    Lastchecked = {13.12.2016},
    Title = {The Economy of Grace and the Market Logic},
    Url = {councilofchurches.ca},
    Year = {2004},
    shorttitle = {Economy of Grace}}

@incollection{rationalclowns,
    Address = {Berlin},
    Author = {Amartya K. Sen},
    Booktitle = {Der Wert des Marktes: Ein {\"o}konomisch-philosophischer Diskurs vom 18.\,Jahrhundert bis zur Gegenwart},
    Date-Added = {2017-08-09 09:08:10 +0000},
    Date-Modified = {2017-08-09 09:11:12 +0000},
    Editor = {Axel Honneth, Lisa Herzog,},
    Pages = {438-469},
    Publisher = {Suhrkamp},
    Title = {Rationalclown: Eine Kritik der behavioristischen grundlagen der Wirtschaftstheorie},
    Year = {2014},
    shorttitle = {Rationalclowns}}

@book{serresparasit,
    Address = {Frankfurt am Main},
    Author = {Michael Serres},
    Publisher = {Suhrkamp},
    Title = {Der Parasit},
    Year = {2014},
    shorttitle = {Parasit}}

@article{Steiger,
    Author = {Johann Anselm Steiger},
    Journal = {NZSTh},
    Pages = {1-28},
    Title = {Die communicatio idiomatum als Achse und Motor der Theologie Luthers},
    Volume = {38},
    Year = {1996},
    shorttitle = {Communication Idiomatum}}
} 

\end{filecontents} 
\documentclass[12pt,headsepline,pagesize=auto,ngerman,greek,hebrew,english,russian,latin,bibliography=totocnumbered,twoside]{scrreprt}\usepackage[a4paper,left=2.25cm, right=2.5cm,top=2.75cm,bottom=2.25cm]{geometry}
\usepackage{blindtext}
\renewcommand{\thefootnote}{\arabic{footnote}} 
\deffootnote{2em}{2.5em}{\makebox[2em][l]{\textsuperscript{\thefootnotemark}}} 
\let\footnoteold=\footnote\renewcommand{\footnote}[1]{\renewcommand{\baselinestretch}{1.0}\footnoteold{#1}} 
\raggedbottom


\usepackage[backend=biber,
citestyle=authoryear]{biblatex}
\addbibresource{\jobname.bib}

\begin{document}

Book\footnote{Vgl. \cite[123]{serresparasit}}

Article\footnote{Vgl. \cite[123]{Steiger}}
%
Article in a Book\footnote{Vgl. \cite[123]{rationalclowns}}
%
Internet\footnote{Vgl. \cite[123]{meeksaufsatz}}

%\bibitem[{\textsc{}: \textit{} ()}]{}
%\textsc{} [] \textit{}, 
% : .
%bibfindex&&&
%\bibitem[{\textsc{}: \textit{} (1986)}]{}
%\textsc{} [] \enquote{}, 
% S.\,in:  \textit{}.


\printbibliography


\end{document}
Joseph Wright
  • 259,911
  • 34
  • 706
  • 1,036
C.-P.
  • 119

1 Answers1

2

Here is a way to do it, using the authoryear style, and some patches:

 \documentclass[12pt,headsepline,pagesize=auto, greek, hebrew, english, russian, latin , ngerman, bibliography=totocnumbered, twoside]{scrreprt}%
 \usepackage[a4paper, left=2.25cm, right=2.5cm, top=2.75cm, bottom=2.25cm]{geometry}
 \usepackage[utf8]{inputenc}
 \usepackage[T1]{fontenc}
 \usepackage{babel}
 \usepackage[german =swiss]{csquotes}
\usepackage{blindtext}
\usepackage{xpatch}
\usepackage[backend=biber, style=authoryear, sorting=none]{biblatex}
\addbibresource{demo.bib}
\renewcommand{\mkbibnamefamily}[1]{\textsc{#1}}
\renewcommand{\mkbibnamegiven}[1]{\textsc{#1}}
\xpatchbibmacro{date+extrayear}{%
\printtext[parens]}{%
\printtext[brackets]}{}{}

\renewbibmacro*{cite}{%
\printtext{Vgl.}
 \iffieldundef{shorthand}
 {\ifthenelse{\ifnameundef{labelname}\OR\iffieldundef{labelyear}}
 {\usebibmacro{cite:label}%
 \setunit{\printdelim{nonameyeardelim}}}
 {\printnames{labelname}%
 \setunit{\addcolon\addspace}
 \printfield{labeltitle}}
 \setunit{\printdelim{nameyeardelim}}}
\printfield[parens]{labelyear}}
 {\usebibmacro{cite:shorthand}}}

\DeclareFieldFormat{pages}{#1}
\DeclareFieldFormat{postnote}{#1}

\begin{document}

Book\footcite[123]{serresparasit}

Article\footcite[123]{Steiger}

Article in a Book\footcite[123]{rationalclowns}

Internet\footcite[123]{meeksaufsatz}

\printbibliography

\end{document} 

enter image description here enter image description here

Bernard
  • 271,350
  • That's awesome. Exactly what I needed. Thanks a lot. Now I try to understand what you did. Thanks very much. – C.-P. Aug 10 '17 at 06:37
  • Feel free to ask questions. You might comment the patches I've added and see the result with the default authoryear style. – Bernard Aug 10 '17 at 08:00
  • I am astonished, how useful biblatex is. I implemented the code into my preamble and it works very well. Just two things I have to change: The pagemark "S." should be deleted in the footnotes as well as in the bibliography.

    (I found things like this but could not change it to get what I wanted. \DefineBibliographyStrings{english}{% page = {p\ifbibliography{}{\adddot}}, pages = {pp\ifbibliography{}{\adddot}}, })

    – C.-P. Aug 10 '17 at 16:27
  • And the second question is a little embarrassing: Until now I had an automated period at the end of every citation. (I used: \usepackage{cite} \renewcommand{\citeleft}{} \renewcommand{\citeright}{.} so that \cite[123]{xyz} has a dot after the 123.) After some hundred citations I realized, that this was a bad idea, but now I have to change every footnote. I cant do that right now, so I need temporarily a final dot. – C.-P. Aug 10 '17 at 16:28
  • By the way: I started to read the Biblatex manual.... – C.-P. Aug 10 '17 at 16:31
  • @C.-P. I'll try to find a solution a little later (unless some has found one in the meantime). – Bernard Aug 10 '17 at 16:46
  • \newcommand{\citex}[2][]{\cite[#1]{#2}.}

    This is a solution for the period and can be done by replacing cite with citex in the document. It is probably not a goog idea, but it is a solution.

    – C.-P. Aug 11 '17 at 19:08
  • @C.-P.: I've posted a modified code which removes the prefix to page numbers. The problem was note to redefined the string, but to not use it, redefining the relevant \DeclareFieldFormat. I don't understand where you don't want a dot, but anyway you shouldn't load the cite package: it will conflict with biblatex. For it's normal that a footnote citation ends with dot, as all footnotes, so cou you explain more in detail? – Bernard Aug 11 '17 at 21:47
  • You are missing a few %s at the end of lines in the redefinition of cite. Instead of \iffieldundef{shorttitle}{\printfield[title:hook]{title}}{\printfield[title:hook]{shorttitle}} you can simply print labeltitle - that field automatically uses shortitle if available and title otherwise. Plus I don't think hook:title is the correct format here. \printfield[parens]{labelyear} will not allow the OP to benefit from EDTF date handling. Strictly speaking nameyeardelim is not applicable any more because it is another position where you use it. – moewe Sep 13 '17 at 17:26
  • ... I added these comments because the code came up again in http://golatex.de/ebd-bzw-ibid-t19731.html – moewe Sep 13 '17 at 17:27
  • @moewe: Thank you for your comments. I didn't know for labeltitle. I've changed it. For EDTF date handling, I didn't even think of it, as there were only years to put between parentheses. Is there a way to add parentheses to a date in this context? And what should I use to replace nameyeardelim? – Bernard Sep 13 '17 at 18:55
  • I'd use \printtext[parens]{\usebibmacro{cite:labelyear+extrayear}} that could be a bit problematic if there is no year, but I could not be bothered to add another check. Once could also copy the definition of cite:labelyear+extrayear and add parentheses directly. You could define a new delimiter or just hard-code the punctuation instead of nameyeardelim, but really that was just me being fussy - strictly speaking nameyeardelim does not separate name and year here. – moewe Sep 13 '17 at 19:01
  • Thanks for all this. I'll try so see tomorrow the simplest way to code. There are many things involved in biblatex code at times, and I must say I'm far from mastering everything! – Bernard Sep 13 '17 at 19:09