Agrupando citações na bibliografia por título

Agrupando citações na bibliografia por título

Estou escrevendo uma dissertação que faz diversas referências a jornais/periódicos com o mesmo nome, publicados em diversas datas ao longo de muitos anos. Estou tentando agrupar essas referências pelo nome do periódico, de modo que as entradas bibliográficas do mesmo periódico fiquem próximas e separadas de outras entradas de outros periódicos.

Examinei extensivamente a documentação do biblatex e as únicas informações relevantes que consegui encontrar foram os registros de comprimento bibnamesepe . bibitemsepEles parecem fazer exatamente o que eu preciso - os bibitems para periódicos com o mesmo título devem estar mais próximos do que os bibitems que não o são. O único desafio aqui é que bibnamesep parece usar nameparts e um modelo de exclusividade para agrupar trabalhos pelo nome do autor (e não pelo título).

Este é o meu MWE:

\documentclass[12pt]{article}
\usepackage{lipsum}
\usepackage[T1]{fontenc} % Specify font encoding
\usepackage[utf8]{inputenc} % Specify encoding (for example, UTF-8)
\usepackage[dashed=false,sorting=nyt,style=verbose,labeldateparts=true,uniquelist=true,uniquename=true,singletitle=true]{biblatex}
% Preamble - Here you can load packages and define settings
\usepackage[english]{babel}

\begin{filecontents*}[overwrite]{mwe.bib}
  @periodical{TheSun:20220101,
    title = {The Sun},
    date  = {2022-01-01}
  }
  @periodical{TheTimes:20220601,
  title = {The Sun},
    date  = {2022-06-01}
  }
  @periodical{TheTimes:20220901,
  title = {The Sun},
    date  = {2022-09-01}
  }

  @periodical{TheGuardian:20210217,
    title = {The Guardian},
    date  = {2021-02-17}
  }
  @periodical{TheGuardian:20210311,
    title = {The Guardian},
    date  = {2021-03-11}
  }
  @periodical{TheGuardian:20210410,
    title = {The Guardian},
    date  = {2021-04-10}
  }

  @periodical{TheAlmanac:202302,
    title = {The Almanac},
    date  = {2023-02}
  }
  @periodical{TheAlmanac:202303,
    title = {The Almanac},
    date  = {2023-03}
  }
  @periodical{TheAlmanac:202304,
    title = {The Almanac},
    date  = {2023-04}
  }
\end{filecontents*}

\addbibresource{mwe.bib}

\DeclareSortingTemplate{TitleYear}{
  \sort{
    \field{title}
  }
  \sort{
    \field{sortyear}
    \field{year}
    \literal{9999}
  }
  \sort{
    \field{month}
  }
  \sort{
    \field{day}
  }
}

\begin{document}

\bibitemsep=1pt
\bibnamesep=30pt

\nocite{*}
\begin{refcontext}[sorting=TitleYear]
  \printbibliography
\end{refcontext}

\end{document}

Contém 9 @periodicalentradas - 3 para The Sun, 3 para The Guardian e 3 para The Almanac. Ele classifica as entradas pelo título do periódico usando o Modelo de Classificação e define \bibitemsepe \bibnamesepcomo 1pt e 30pt respectivamente.Essa é a parte que não consigo trabalhar:

insira a descrição da imagem aqui

Como você pode ver na imagem acima, todas as referências têm 30pt entre elas, enquanto eu gostaria que os bibitems "The Almanac" tivessem 1pt, mas 30pt separando "The Almanac" do "The Guardian".

Responder1

\bibnamesepaplica-se apenas entre entradas com um nome diferente, conforme codificado em fullhash. Se quiser alterar isso para title, você pode tentar redefinir (localmente) a macro interna relevante que define o separador.

\documentclass[12pt]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage[
  style=verbose,
  sorting=nyt,
  dashed=false,
  labeldateparts=true,
  uniquelist=true,uniquename=true,
  singletitle=true,
]{biblatex}


\makeatletter
\def\blx@namesep@title{%
  \ifnum\c@instcount>\@ne
    \blx@imc@iffieldequals{title}\blx@prevtitle
      {}
      {\addvspace{\bibnamesep}}%
  \fi
  \global\let\blx@prevtitle\abx@field@title}

\newcommand*{\NamesepByTitle}{\let\blx@namesep\blx@namesep@title}
\makeatother


\DeclareSortingTemplate{TitleYear}{
  \sort{
    \field{title}
  }
  \sort{
    \field{sortyear}
    \field{year}
    \literal{9999}
  }
  \sort{
    \field{month}
  }
  \sort{
    \field{day}
  }
}

\begin{filecontents*}[overwrite]{\jobname.bib}
@periodical{TheSun:20220101,
  title = {The Sun},
  date  = {2022-01-01}
}
@periodical{TheTimes:20220601,
title = {The Sun},
  date  = {2022-06-01}
}
@periodical{TheTimes:20220901,
title = {The Sun},
  date  = {2022-09-01}
}

@periodical{TheGuardian:20210217,
  title = {The Guardian},
  date  = {2021-02-17}
}
@periodical{TheGuardian:20210311,
  title = {The Guardian},
  date  = {2021-03-11}
}
@periodical{TheGuardian:20210410,
  title = {The Guardian},
  date  = {2021-04-10}
}

@periodical{TheAlmanac:202302,
  title = {The Almanac},
  date  = {2023-02}
}
@periodical{TheAlmanac:202303,
  title = {The Almanac},
  date  = {2023-03}
}
@periodical{TheAlmanac:202304,
  title = {The Almanac},
  date  = {2023-04}
}
\end{filecontents*}
\addbibresource{\jobname.bib}

\begin{document}
\bibitemsep=1pt
\bibnamesep=30pt

\nocite{*}
\begin{refcontext}[sorting=TitleYear]
  \NamesepByTitle
  \printbibliography
\end{refcontext}

\end{document}

Lista bibliográfica agrupada.

informação relacionada