0

I need to make a change to a LaTeX template. Specifically, in the \footcite that, after researching, I don't know how to do. This would be as follows: include the short name (not just the surname) in the \footcite.

I give you an example. After I have cited a book for the first time, the following times it automatically makes me this style of short citation:

Tolkien, The Lord of the Rings, p. 12

But they ask me to also get the letters of the author's name, as in the following example:

J. R. Tolkien, The Lord of the Rings, p. 12

The template has a separate document where the styles are. There is a coding for the footer references:

\usepackage[
backend=biber,
style=philosophy-verbose,
isbn=false,
giveninits=true,
idemtracker=context,
ibidtracker=context,
loccittracker=context,
opcittracker=context,
citetracker=context,
latinemph=true,
commacit=false,
scauthors=all,
lowscauthors=false
annotation=true,
classical=true,
singletitle=false,
editionformat=superscript,
shorthandintro=true,
%volumeformat=romansc,
%library=true,
hyperref,
%backref,
sorting=cst, % if one wants to implement a custom sorting of reference list
lowscauthors=false]{biblatex}

\addbibresource{biblio.bib} % The filename of the bibliography
%\addbibresource{biblio-secondary.bib} % Other bibliography sources

\NewBibliographyString{opted}
\DefineBibliographyStrings{english}{%
    %idem = {\textsc{Id}\adddot}
    idem = {\textsc{Idem}},
    ibidem = {Ibid\adddot},
    %ibidem = {Ibidem},
    %loccit = {},
    opcit = {\addcomma\,op\adddot\,cit\adddot,},
    %opcit = {},
    opcited = {},
}

% To put the names of the curators in the majority
\renewcommand*{\mkbibnamefamily}[1]{\textsc{#1}}

Would anyone know how to do this?

1 Answer 1

1

It should be enough to redefine the name format labelname to print the name initials.

The original definition can be found in philosophy-standard.bbx. We just change the \case switch checking the value of uniquename to a simple \ifnum that only distinguishes whether or not the full name is needed for disambiguation.

\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[
  backend=biber,
  style=philosophy-verbose,
  isbn=false,
  giveninits=true,
  idemtracker=context,
  ibidtracker=context,
  loccittracker=context,
  opcittracker=context,
  citetracker=context,
  latinemph=true,
  commacit=false,
  scauthors=all,
  lowscauthors=false,
  annotation=true,
  classical=true,
  singletitle=false,
  editionformat=superscript,
  shorthandintro=true,
  %volumeformat=romansc,
  %library=true,
  %backref,
%  sorting=cst,
  lowscauthors=false,
]{biblatex}

\NewBibliographyString{opted}
\DefineBibliographyStrings{english}{%
  %idem    = {\textsc{Id}\adddot}
  idem    = {\textsc{Idem}},
  ibidem  = {Ibid\adddot},
  %ibidem  = {Ibidem},
  %loccit  = {},
  opcit   = {\addcomma\,op\adddot\,cit\adddot,},
  %opcit   = {},
  %opcited = {},
}

\renewcommand*{\mkbibnamefamily}[1]{\textsc{#1}}

\DeclareNameFormat{labelname}{%
  \iftoggle{cbx:scauthorscite}{\usebibmacro{bbx:scswitch}}{}%
  \iftoggle{cbx:scauthorscitefn}{\iffootnote{\usebibmacro{bbx:scswitch}}{}}{}%
  \bibhyperref{\nameparts{#1}%
  \ifnum\value{uniquename}<2
    \ifuseprefix
      {\usebibmacro{name:given-family}%
        {\namepartfamily}%
        {\namepartgiveni}%
        {\namepartprefix}%
        {\namepartsuffixi}}%
      {\usebibmacro{name:given-family}%
        {\namepartfamily}%
        {\namepartgiveni}%
        {\namepartprefixi}%
        {\namepartsuffixi}}%
  \else
    \usebibmacro{name:given-family}%
      {\namepartfamily}%
      {\namepartgiven}%
      {\namepartprefix}%
      {\namepartsuffix}%
  \fi
  \usebibmacro{name:andothers}}}%


\addbibresource{biblatex-examples.bib}

\begin{document}
Lorem \autocite{sigfridsson}
ipsum \autocite{nussbaum}
dolor \autocite{sigfridsson}

\printbibliography
\end{document}

E. Sigfridsson and U. Ryde, ‘Comparison of methods for deriving atomic charges from the electrostatic potential and moments’, op.cit.

2
  • Thank you very much! I already included the code you put in! It worked perfectly!
    – nrlat
    Jan 5, 2021 at 8:50
  • @nrlat If the answer worked for you and resolved your issue, please consider accepting it to show that the question is answered: tex.stackexchange.com/help/someone-answers
    – moewe
    Jan 5, 2021 at 9:00

You must log in to answer this question.

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