Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I would like to have the InCollection (also: InProceedings) source type to be changed up.

So I would like to have

  • main title

  • an "in:" behind the (main) source title

  • the editor name after said source title

  • then an ":"

  • booktitle

All the rest is good to go and should not be changed please.

An example of what it should be like is here:

Brandt, A. von/Hoffmann, E. (1987):
Die nordischen Länder von der Mitte des 11. Jahrhunderts bis 1448, in: Seibt, F./Smith, J. (editors): Europa im Hoch und Spätmittelalter, no. 2, 4th ed., Klett-Cotta, Stuttgart, pp. 884–917.

The status quo, produced by the MWE, looks like this currently:

Brandt, A. von/Hoffmann, E. (1987):
Die nordischen Länder von der Mitte des 11. Jahrhunderts bis 1448, in: Europa im Hochund Spätmittelalter, Seibt, F./Smith, J. (editors), no. 2, 4th ed., Klett-Cotta, Stuttgart, pp. 884–917.

MWE

\documentclass[
a4paper
]
{scrreprt}

\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}

\usepackage{lmodern}
\renewcommand{\familydefault}{\sfdefault}


\usepackage[
language=auto,
style=authoryear-ibid,
backend=bibtex,
hyperref=true,
isbn=false,
doi=false,
citereset=chapter,
maxcitenames=3,
dashed=false,
sorting=nyt,
firstinits=true,
ibidtracker=true,
maxbibnames=99
]{biblatex}
\usepackage{xpatch}

%% comma after every item for bibiliography entries
\renewcommand*{\newunitpunct}{\addcomma\space}

%%  parentheses around year in references
\renewbibmacro*{cite:labelyear+extrayear}{%
\iffieldundef{labelyear}
{}
{%
\printtext[bibhyperref]{%
\printtext[parens]{%
\printfield{labelyear}%
\printfield{extrayear}}}}}

%% correct order of publisher and location
\renewbibmacro*{publisher+location+date}{%
\newunit
\printlist{publisher}%
\newunit
\printlist{location}%
\newunit}

%%  right order of words 'volume' und 'issue' with comma in front
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\renewbibmacro*{journal+issuetitle}{%
  \usebibmacro{journal}%
  \setunit*{\addspace}%
  \iffieldundef{series}
    {}
    {\newunit
     \printfield{series}%
     \setunit{\addspace}}%
  \usebibmacro{volume+number+eid}
  \setunit{\addcomma\space}% THIS LINE CHANGED to add comma
  \usebibmacro{issue+date}%
  \setunit{\addcolon\space}%
  \usebibmacro{issue}%
  \newunit}

%taken from standard.bbx
\renewbibmacro*{issue+date}{%
  \printtext{%   REMOVED parenthesis here
    \iffieldundef{issue}
      {\usebibmacro{date}}
      {\printfield{issue}%
       \setunit*{\addspace}%
       \usebibmacro{date}}}%
  \newunit}

%% bold bibliography "label" followed by colon and linebreak
\renewbibmacro*{begentry}{\mkbibbold\bgroup}
\xapptobibmacro{date+extrayear}{\addcolon\egroup}{}{}
\renewcommand*{\labelnamepunct}{\par\nobreak}

%% linebreak before URLs and colon before date of last visit
\xpretobibmacro{url+urldate}{\setunit{\newunitpunct\par\nobreak}}{}{}
\DefineBibliographyStrings{english}{%
urlseen = {last visit\addcolon}
}

%% colon before date of last visit
\DeclareFieldFormat{urldate}{\mkbibparens{\bibstring{urlseen}\addcolon\space#1}}

%% no indent
\setlength{\bibhang}{0pt} 

%% one empty line between to bib-entries
\setlength{\bibitemsep}{\baselineskip} %% \baselineskip gibt hier an, dass Zeilenabstand unterhalb des Absatzes der dokumentweite Abstand ist

%% ``(editor)'' or ``(editors)''
\renewbibmacro*{byeditor+others}{%
  \ifnameundef{editor}
    {}
    {\printnames[byeditor]{editor}%
     \setunit{\addspace}%
     \usebibmacro{byeditor+othersstrg}%
     \clearname{editor}%
     \newunit}%
  \usebibmacro{byeditorx}%
  \usebibmacro{bytranslator+others}}
\xpatchbibmacro{byeditor+othersstrg}{\printtext}{\printtext[parens]}{}{}

%%  ``(editor)'' or ``(editors)'' instead of ``(ed. by)''
\DefineBibliographyStrings{english}{%
byeditor = {editor},%
byeditor = {editors},%
issue  = {\lowercase{i}ss\adddot},%
}

%% edition behind series number ("no.")
\AtEveryBibitem{%
  \iffieldequalstr{edition}{1}
    {\clearfield{edition}}
    {\savefield*{edition}{\savededition}%
     \clearfield{edition}}}

\renewbibmacro*{series+number}{%
  \restorefield{edition}{\savededition}
  \printfield{series}%
  \setunit*{\addspace}%
  \printfield{number}%
  \setunit{\addcomma\space}%
  \printfield{edition}%
  \newunit}

%% all titles in references in normal formatting
\DeclareFieldFormat*{citetitle}{#1\isdot} 

%% annul format of any (main) title in bibliography and add comma+space
\DeclareFieldFormat*{title}{#1\addcomma\addspace} 

%% annul format of any other (parent) titles in bibliography
\DeclareFieldFormat*{booktitle}{#1\addcomma\addspace}
\DeclareFieldFormat*{journaltitle}{#1\addcomma\addspace}
\DeclareFieldFormat*{issuetitle}{#1\addcomma\addspace}
\DeclareFieldFormat*{maintitle}{#1\addcomma\addspace}
\DeclareFieldFormat*{proceedingstitle}{#1\addcomma\addspace}
\DeclareFieldFormat*{collectiontitle}{#1\addcomma\addspace}
%new
\DeclareFieldFormat*{volume}{\bibstring{volume}~#1\space}
\DeclareFieldFormat*{issue}{\bibstring{issue}~#1}
\DeclareFieldFormat*{number}{\bibstring{number}~#1} %comment to leave number as before
\DeclareFieldFormat*{series}{{#1}\addcomma\space} %comment to leave number as before

%% Names: Lastname, Firstname
\DeclareNameAlias{default}{last-first}
\DeclareNameAlias{sortname}{last-first}

\AtBeginBibliography{%
    %% only slash signs between names
    \renewcommand{\multinamedelim}{\addslash}
    \renewcommand{\finalnamedelim}{\addslash}
    %% only slash signs between multiple locations
    \renewcommand{\multilistdelim}{\addslash}
    \renewcommand{\finallistdelim}{\addslash}
}

\begin{filecontents*}{lit.bib}
@InCollection{brandt,
  options     = {useprefix=false},
  hyphenation     = {german},
  author      = {von Brandt, Ahasver and Hoffmann, Erich},
  editor      = {Seibt, Ferdinand and Smith, John},
  title       = {Die nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts bis 1448},
  booktitle  = {Europa im Hoch- und Sp{\"a}tmittelalter},
  number      = {2},
    edition = {4},
  publisher   = {Klett-Cotta},
  location    = {Stuttgart},
  date        = {1987},
  pages       = {884--917}
}
\end{filecontents*}
\addbibresource{lit.bib}

\begin{document}
\begin{itemize}
    \item Place holder for \verb+InCollection+.\footcite[See][p. 5--11]{brandt}
\end{itemize}

\printbibliography
\end{document}
share|improve this question

1 Answer 1

up vote 2 down vote accepted

I made an attempt on my own and it seems to work so far.

  • I took the definition of {maintitle+booktitle} from the file standard.bbx and simply copy and pasted it as \renewbibmacro*{maintitle+booktitle}

  • I commented out \usebibmacro{booktitle}% from said code bit

  • I then added

    \setunit{\addcolon\space}
    \usebibmacro{booktitle}
    

    to the already included redefinition of {byeditor+others} (see MWE above or below), which resulted in:

    \documentclass[12pt,
    a4paper
    ]
    {scrreprt}
    
    \usepackage[T1]{fontenc}
    \usepackage[utf8]{inputenc}
    
    \usepackage{lmodern}
    \renewcommand{\familydefault}{\sfdefault}
    
    
    \usepackage[
    language=auto,
    style=authoryear-ibid,
    backend=bibtex,
    hyperref=true,
    isbn=false,
    dashed=false,
    doi=false,
    citereset=chapter,
    maxcitenames=3,
    sorting=nyt,
    firstinits=true,
    ibidtracker=true,
    maxbibnames=99
    ]{biblatex}
    \usepackage{xpatch}
    
    %% comma after every item for bibiliography entries
    \renewcommand*{\newunitpunct}{\addcomma\space}
    
    %%  parentheses around year in references
    \renewbibmacro*{cite:labelyear+extrayear}{%
    \iffieldundef{labelyear}
    {}
    {%
    \printtext[bibhyperref]{%
    \printtext[parens]{%
    \printfield{labelyear}%
    \printfield{extrayear}}}}}
    
    %% correct order of publisher and location
    \renewbibmacro*{publisher+location+date}{%
    \newunit
    \printlist{publisher}%
    \newunit
    \printlist{location}%
    \newunit}
    
    %%  right order of words 'volume' und 'issue' with comma in front
    \renewbibmacro*{journal+issuetitle}{%
      \usebibmacro{journal}%
      \setunit*{\addspace}%
      \iffieldundef{series}
        {}
        {\newunit
         \printfield{series}%
         \setunit{\addspace}}%
      \usebibmacro{volume+number+eid}
      \setunit{\addcomma\space}% THIS LINE CHANGED to add comma
      \usebibmacro{issue+date}%
      \setunit{\addcolon\space}%
      \usebibmacro{issue}%
      \newunit}
    %taken from standard.bbx
    \renewbibmacro*{issue+date}{%
      \printtext{%   REMOVED parenthesis here
        \iffieldundef{issue}
          {\usebibmacro{date}}
          {\printfield{issue}%
           \setunit*{\addspace}%
           \usebibmacro{date}}}%
      \newunit}
    
    %% booktitle after editors
    \renewbibmacro*{maintitle+booktitle}{%
      \iffieldundef{maintitle}
        {}
        {\usebibmacro{maintitle}%
         \newunit\newblock
         \iffieldundef{volume}
           {}
           {\printfield{volume}%
            \printfield{part}%
            \setunit{\addcolon\space}}}%
      %\usebibmacro{booktitle}%
      \newunit}
    
    %% bold bibliography "label" followed by colon and linebreak
    \renewbibmacro*{begentry}{\mkbibbold\bgroup}
    \xapptobibmacro{date+extrayear}{\addcolon\egroup}{}{}
    \renewcommand*{\labelnamepunct}{\par\nobreak}
    
    %% linebreak before URLs and colon before date of last visit
    \xpretobibmacro{url+urldate}{\setunit{\newunitpunct\par\nobreak}}{}{}
    \DefineBibliographyStrings{english}{%
    urlseen = {last visit\addcolon}
    }
    
    %% colon before date of last visit
    \DeclareFieldFormat{urldate}{\mkbibparens{\bibstring{urlseen}\addcolon\space#1}}
    
    %% no indent
    \setlength{\bibhang}{0pt} 
    
    %% one empty line between to bib-entries
    \setlength{\bibitemsep}{\baselineskip} %% \baselineskip gibt hier an, dass Zeilenabstand unterhalb des Absatzes der dokumentweite Abstand ist
    
    %% ``(editor)'' or ``(editors)''
    \renewbibmacro*{byeditor+others}{%
      \ifnameundef{editor}
        {}
        {\printnames[byeditor]{editor}%
         \setunit{\addspace}%
         \usebibmacro{byeditor+othersstrg}%
         \clearname{editor}%
         \newunit}%
      \usebibmacro{byeditorx}%
      \usebibmacro{bytranslator+others}
        \setunit{\addcolon\space}
        \usebibmacro{booktitle}}
    \xpatchbibmacro{byeditor+othersstrg}{\printtext}{\printtext[parens]}{}{}
    
    %%  ``(editor)'' or ``(editors)'' instead of ``(ed. by)''
    \DefineBibliographyStrings{english}{%
    byeditor = {editor},%
    byeditor = {editors},%
    issue  = {\lowercase{i}ss\adddot},%
    }
    
    %% edition behind number (no.)
    \AtEveryBibitem{%
      \iffieldequalstr{edition}{1}
        {\clearfield{edition}}
        {\savefield*{edition}{\savededition}%
         \clearfield{edition}}}
    \renewbibmacro*{series+number}{%
      \restorefield{edition}{\savededition}
      \printfield{series}%
      \setunit*{\addspace}%
      \printfield{number}%
      \setunit{\addcomma\space}%
      \printfield{edition}%
      \newunit}
    
    %% all titles in references in normal formatting
    \DeclareFieldFormat*{citetitle}{#1\isdot} 
    
    %% annul format of any (main) title in bibliography and add comma+space
    \DeclareFieldFormat*{title}{#1\addcomma\addspace} 
    
    %% annul format of any other (parent) titles in bibliography
    \DeclareFieldFormat*{booktitle}{#1\addcomma\addspace}
    \DeclareFieldFormat*{journaltitle}{#1\addcomma\addspace}
    \DeclareFieldFormat*{issuetitle}{#1\addcomma\addspace}
    \DeclareFieldFormat*{maintitle}{#1\addcomma\addspace}
    \DeclareFieldFormat*{proceedingstitle}{#1\addcomma\addspace}
    \DeclareFieldFormat*{collectiontitle}{#1\addcomma\addspace}
    %new
    \DeclareFieldFormat*{volume}{\bibstring{volume}~#1\space}
    \DeclareFieldFormat*{issue}{\bibstring{issue}~#1}
    \DeclareFieldFormat*{number}{\bibstring{number}~#1} %comment to leave number as before
    \DeclareFieldFormat*{series}{{#1}\addcomma\space} %comment to leave number as before
    
    %% Names: Lastname, Firstname
    \DeclareNameAlias{default}{last-first}
    \DeclareNameAlias{sortname}{last-first}
    
    \AtBeginBibliography{%
        %% only slash signs between names
        \renewcommand{\multinamedelim}{\addslash}
        \renewcommand{\finalnamedelim}{\addslash}
        %% only slash signs between multiple locations
        \renewcommand{\multilistdelim}{\addslash}
        \renewcommand{\finallistdelim}{\addslash}
    }
    
    \begin{filecontents*}{lit.bib}
    @InCollection{brandt,
      options     = {useprefix=false},
      hyphenation     = {german},
      author      = {von Brandt, Ahasver and Hoffmann, Erich},
      editor      = {Seibt, Ferdinand and Smith, John},
      title       = {Die nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts bis 1448},
      booktitle  = {Europa im Hoch- und Sp{\"a}tmittelalter},
      number      = {2},
        edition = {4},
      publisher   = {Klett-Cotta},
      location    = {Stuttgart},
      date        = {1987},
      pages       = {884--917}
    }
    \end{filecontents*}
    \addbibresource{lit.bib}
    
    \begin{document}
    \begin{itemize}
        \item Place holder for \verb+InCollection+.\footcite[See][p. 5--11]{brandt}
    \end{itemize}
    
    \printbibliography
    \end{document}
    
share|improve this answer
    
Your attempt seems to work, but because of the various formatting changes unrelated to the problem at hand it's hard to spot what you did change actually. I'd upvote this if you provided a short explanation so that others with a similar problem can benefit. –  lockstep Jun 30 '13 at 10:49
    
Ok I edited my answer. I hope the notes are ok? –  henry Jun 30 '13 at 11:31
1  
Yes, that's better, so +1. –  lockstep Jun 30 '13 at 11:32

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.