2

I would like to have the page number of the index entries in smallcaps, at least for the part of the work that uses roman style. Unfortunately, the Imakeidx manual doesn't provide any explanation about customising.

This is the MWE

% !BIB TS-program = biber
% !BIB program = biber
% !TEX encoding = UTF-8 Unicode
% !TeX TS-program = xelatexmk

\begin{filecontents}{archivio.bib}

@book{Dol2,
    Address = {Moskwa},
    Author = {Philip Döllinger},
    Publisher = {Sinodal'naja tip.},
    Title = {Sistematičeskoe opisanie rukopisej moskovskoj Sinodal'noj (patriaršej) biblioteki},
    Year = {1894}}


\end{filecontents}

\documentclass[11pt, openany]{book}
\usepackage{polyglossia}
\setmainlanguage[babelshorthands=true]{italian}
\setotherlanguages{latin, english, french}
\usepackage[]{csquotes}
\usepackage{xpatch}
\usepackage[style=verbose-trad2,
            language=auto,
            ibidpage=true,
            autolang=other,
            useprefix=true,
            giveninits=true,
            indexing=true,
            dateabbrev=false,
            backend=biber,
        ]{biblatex}



\addbibresource{archivio.bib}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


\usepackage{imakeidx}
\makeindex[name=nomi]

\renewbibmacro*{citeindex}{%
  \ifciteindex
    {\ifnameundef{namea}{\indexnames{labelname}}{\indexnames{namea}}}
    {}}

\DeclareIndexNameFormat{default}{%      Formato del nome dell'autore
  \usebibmacro{index:name}
    {\index[nomi]}
    {\namepartfamily}
    {\namepartgiveni}
    {\namepartprefix}
    {\namepartsuffix}}


\begin{document}
\pagenumbering{roman}


I should like see the pagenumber of \cite{Dol2} printed in smallcaps



\printindex[nomi]       % Indice dei nomi   
\end{document}

1 Answer 1

3

You have to pass the index entry as

\index[nomi]{<entry>|textsc}

The simplest way is to use a specific macro:

\begin{filecontents}{\jobname.bib}
@book{Dol2,
    Address = {Moskwa},
    Author = {Philip Döllinger},
    Publisher = {Sinodal'naja tip.},
    Title = {Sistematičeskoe opisanie rukopisej moskovskoj Sinodal'noj (patriaršej) biblioteki},
    Year = {1894}}
\end{filecontents}

\documentclass[11pt, openany]{book}
\usepackage{polyglossia}
\setmainlanguage[babelshorthands=true]{italian}
\setotherlanguages{latin, english, french}
\usepackage[]{csquotes}
\usepackage{xpatch}
\usepackage[style=verbose-trad2,
            language=auto,
            ibidpage=true,
            autolang=other,
            useprefix=true,
            giveninits=true,
            indexing=true,
            dateabbrev=false,
            backend=biber,
        ]{biblatex}

\addbibresource{\jobname.bib}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\usepackage{imakeidx}
\makeindex[name=nomi]
\newcommand{\scindex}[2][]{\index[#1]{#2|textsc}}

\renewbibmacro*{citeindex}{%
  \ifciteindex
    {\ifnameundef{namea}{\indexnames{labelname}}{\indexnames{namea}}}
    {}}

\DeclareIndexNameFormat{default}{%      Formato del nome dell'autore
  \usebibmacro{index:name}
    {\scindex[nomi]}
    {\namepartfamily}
    {\namepartgiveni}
    {\namepartprefix}
    {\namepartsuffix}}


\begin{document}
\pagenumbering{roman}

I should like see the pagenumber of \cite{Dol2} printed in smallcaps

\printindex[nomi]       % Indice dei nomi   
\end{document}

enter image description here

3
  • but what if you have another citation for the book on (arabic) page 12? how do you keep them from being listed separately? Jun 5, 2018 at 17:43
  • @barbarabeeton I tried and they're not listed separately.
    – egreg
    Jun 5, 2018 at 17:47
  • thanks. (i tried to try, but we don't have all the necessary pieces installed.) Jun 5, 2018 at 17:50

You must log in to answer this question.

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