[Tex/LaTex] Biblatex: Changing the font of citation-marks and the references

biblatexformatting

In my main text I use a roman font with oldstyle figures

In all tables I use the same roman font, but with modern figures. Since some of the columns may consist of mainly figures and it looks abit clumsy when those figures are set in oldstyle. Since all my tables are within a floatrow object, I define the font as follows:

\usepackage{floatrow}
\usepackage{fontspec}
\newfontfamily\tablefont[Path=x]{fontname.otf} 
\DeclareFloatFont{tables}{\tablefont}
\floatsetup[table]{font={tables}}

I use biblatex for my reference, as citation marks I use numbers.

Now I found out that the citation marks are formatted according to the font of their direct environment. So In my maintext these citation numbers are modern, while in the tables they are oldstyle. But how can I change the formatting for the citation numbers, so they are consistent in the whole document. I would like to use custom font families for this. Aswell I would like to change the formatting of the Bibliography (\printbibliography) in the same way.

Or is this directly related to the the floatfont declaration, and would these always override my citation format declaration?

Been reading the biblatex manual, and I read something about \bibfont but don't know how I should be using this.

Best Answer

The \bibfont hook is used to set the font for the bibliography. It is an ordinary LaTeX macro (not a BibLaTeX bibmacro), so you need to renew it with \renewcommand, as for example:

\renewcommand*{\bibfont}{\small}

The hook for all citations is \citesetup, which is defined in biblatex.def. You can modify it using the LaTeX \renewcommand* command. By default \citesetup is set to:

\newcommand*{\citesetup}{%
  \biburlsetup
  \frenchspacing}

You would want to put something like \rmfamily or \normalfont or whatever in your renewed version:

\renewcommand*{\citesetup}{%
  \normalfont
  \biburlsetup
  \frenchspacing}

You could be inventive and define a separate command \citefont and put that into \citesetup, thus creating a parallel to \bibfont. If you want to have this in all of your documents then you can put it into the biblatex.cfg file.

I am unaware of any hook run at the end of a citation, so you may not be able to easily tack things on the end without hacking the citation commands.

Related Question