1

I am still learning LaTeX and I'd like to edit my @incollection from this:

Fairclough, Norman e Wodak, Ruth (1997). “Critical Discourse Analysis: An Overview”. In: Discourse Studies: A Multidisciplinary Introduction. A cura di T. A. van Dijk. London: Sage: 67–97.

into something like this:

Fairclough, Norman e Wodak, Ruth (1997). “Critical Discourse Analysis: An Overview”. In T. A. van Dijk (ed.), Discourse Studies: A Multidisciplinary Introduction. London: Sage, 67–97.

In other words:

  • I have to change the delimiter between Publisher and Pages from a colon to a comma

  • I have to change the position of the editor

  • I have to remove the colon from "In:"

    @incollection{fairclough.wodak-critical.discourse.analysis.overview, author = "Norman Fairclough and Ruth Wodak", title = "Critical Discourse Analysis: An Overview", booktitle = "Discourse Studies: A Multidisciplinary Introduction", pages = "67-97", publisher = "Sage", location = "London", year = "1997", editor = "T. A. van Dijk",

My preamble is as follows (I don't use a specific style for my bibliography):

\documentclass[a4paper,12pt,twoside]{report}
\usepackage[utf8]{inputenc}

\usepackage{fancyhdr}
\usepackage{kantlipsum} 
\usepackage{lipsum} 
\usepackage{setspace} 
\usepackage{xpatch} 
\usepackage{multicol} 
\usepackage{tabularray} 

\usepackage[italian]{babel}
\selectlanguage{italian}

\usepackage{indentfirst}

\usepackage{etoolbox}

\usepackage[autostyle]{csquotes} %% Pacchetto per gestire l'uso delle virgolette
\setquotestyle{english}
\MakeOuterQuote{"}

%=========================================%     BIBLIOGRAFIA E CITAZIONI

\usepackage[backend=biber, natbib=true, citestyle=authoryear-icomp, bibstyle=authoryear-icomp, ibidpage=true, dashed=true, pagetracker=false, maxbibnames=4, maxcitenames=2, autolang=other]{biblatex}
\addbibresource{8.bibliografia.bib} %% File .bib contenente i dati bibliografici

I'd also like to know how I can localize single entries (only in the bibliography, not in cite), in order to have "and" instead of "e" (which is a translation defined by \usepackage[italian]{babel} and \selectlanguage{italian}).

2
  • 2
    Please ask only about one specific, concrete issue per question. That makes your question easier to answer and more relevant for future visitors. You can ask multiple questions (if you are a very new user, you may have to wait a little between questions). See also tex.meta.stackexchange.com/q/7425/35864.
    – moewe
    Sep 10, 2023 at 20:08
  • Ideally you would also split off the three itemize items you have at the moment into three separate questions. The issues are mostly independent of each other and separate questions are easier to answer and more useful for other people.
    – moewe
    Sep 11, 2023 at 7:06

1 Answer 1

2

Welcome to TeX.SE!

To achieve the desired bibliography formatting, you'll need to make some modifications to your existing BibLaTeX settings and create custom formats for the @incollection entry type.

Here is one way to accomplish this (not the most elegant, but straightforward, and relatively simple to revise further), by adding the below to your preamble (after all your current loading and configurations):

% Custom settings to modify incollection entry
\DeclareFieldFormat[incollection]{title}{\mkbibquote{#1\isdot}}
\DeclareDelimFormat[incollection]{nameyeardelim}{\addcomma\space}
\DeclareDelimFormat[between:unit,pair:unit]{nameyeardelim}{\addcomma\space}

% Custom driver
\DeclareBibliographyDriver{incollection}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author}%
  \setunit{\printdelim{nameyeardelim}}\newblock
  \usebibmacro{title}%
  \setunit{\printdelim{nameyeardelim}}\newblock
  \printtext{In }%
  \usebibmacro{editor+others}%
  \setunit{\addspace}\newblock
  \printfield{booktitle}%
  \setunit{\addcomma\space}\newblock
  \printlist{location}%
  \setunit{\addcomma\space}\newblock
  \printfield{publisher}%
  \setunit{\addcomma\space}\newblock
  \printfield{pages}%
  \usebibmacro{finentry}
}

I provide a complete example of this revised MWE, incorporating the above on Overleaf.


Regarding your other question:

In your bib file, you can add the langid field to specify the language for that particular entry. To have "and" instead of "e", you would add an additional field, to each applicable BibLaTeX entry, seting langid to english:

langid = {english}

Your current preamble (i.e., loading of biblatex) already has autolang=other, which should take care of applying the language specifications.


Pursuant to your later comment, you can revise this to the below, to more closely match your desired output. I now also incorporate the above revision (changing "e" to "and"). Additionally, I further generalize the driver, to ensure it is more robust in the face of more complex citations. I retain the above prior revision, as an example of how you can learn to modify this yourself.

% Load biblatex without invalid/interferring style options
\usepackage[backend=biber, natbib=true, pagetracker=false, maxbibnames=4, maxcitenames=2, autolang=other]{biblatex}

% Exactly match: <Author> (<Year>). "<Title>". In <Editor> (ed.), <BookTitle>. <Location>: <Publisher>, <Pages>.

% Custom settings to modify incollection entry
\DeclareFieldFormat[incollection]{title}{\mkbibquote{#1\isdot}}

\renewbibmacro*{byeditor+others}{%
  \ifnameundef{editor}
    {}
    {\printnames[byeditor]{editor}%
     \setunit{\addspace}%
     \printtext{(ed.)}%
     \clearname{editor}%
    }%
  \usebibmacro{byeditorx}%
  \usebibmacro{bytranslator+others}%
}

\renewbibmacro*{publisher+location+date}{%
  \printlist{location}%
  \setunit{\addcolon\space}%
  \printlist{publisher}%
  \newunit}

\DeclareBibliographyDriver{incollection}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author}%
  \setunit{\addspace}\newblock
  \printtext[parens]{\usebibmacro{date}}\newunit\newblock
  \usebibmacro{title}%
  \newunit\newblock
  \printtext{\bibstring{in}}
  \usebibmacro{byeditor+others}%
  \setunit{}%
  \printtext{,}\newblock%
  \setunit{\addspace}\newblock
  \usebibmacro{maintitle+booktitle}%
  \newunit\newblock
  \usebibmacro{publisher+location+date}%
  \setunit{\addcomma\space}\newblock
  \printfield{pages}%
  \newunit\newblock
  \iftoggle{bbx:isbn}{\printfield{isbn}}{}%
  \newunit\newblock
  \usebibmacro{doi+eprint+url}%
  \newunit\newblock
  \usebibmacro{addendum+pubstate}%
  \setunit{\bibpagerefpunct}\newblock
  \usebibmacro{pageref}%
  \newunit\newblock
  \usebibmacro{related}%
  \usebibmacro{finentry}
}

I have now updated the Overleaf document to reflect this revised code, which results in the below compiled output:

The compiled output of the above, final revised, code.

1
  • 1
    Thank you for the answer. While waiting for some reply, I managed to come up with a solution: \DeclareBibliographyDriver{incollection}{% \printnames{author}{ }% \printfield{year}% \newunit\newblock \printfield{title}{. }% \printtext{In} \printnames{editor}{ (ed.),}% \newunit\newblock \printfield{booktitle}{.}% \newunit\newblock \printlist{location}{:}% \newunit\newblock \printlist{publisher}{,} \newunit\newblock \printfield{pages}% \finentry }
    – Noire382
    Sep 15, 2023 at 16:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .