Disable pagetracker in floats as well?
Via https://tex.stackexchange.com/q/506161/35864
Most citation tracking is disabled in floats, but backref is still enabled. This leads to undesirable output such as in the following example
\documentclass{report}
\usepackage[english]{babel}
\usepackage[backref=true,backend=biber,citecounter=true]{biblatex}
\addbibresource{biblatex-examples.bib}
\renewbibmacro*{pageref}
{%
\iflistundef{pageref}
{\printtext{\autocap{n}o citation in the text.}}
{
\printtext{\autocap{c}ited \arabic{citecounter} time\ifnumgreater{\value{citecounter}}{1}{s}{}}%
\setunit{\addspace}%
\ifnumgreater{\value{pageref}}{1}
{\bibstring{backrefpages}\ppspace}
{\bibstring{backrefpage}\ppspace}%
\printlist[pageref][-\value{listtotal}]{pageref}
}
}
\DefineBibliographyStrings{english}{
backrefpage = {on page},
backrefpages = {on pages},
}
\begin{document}
\cite{sigfridsson}
\newpage
\begin{figure}
\caption{\cite{sigfridsson}}
\end{figure}
\printbibliography
\end{document}
cited 1 time on pages 1, 2.
Maybe we could make disabling trackers in floats optional? From time to time people ask about that.
Options to enable/disable cite tracking and back references in floats are implemented in https://github.com/plk/biblatex/commit/18e39d5c835749446e9e0c5512a2c029a11e2636.
@plk Currently back references in floats are enabled (backreffloats=true,) and citation tracking is disabled (trackfloats=false,). Should we disable back references in floats by default for a more uniform experience (braking backwards compatibility) or do we just leave behaviour as it is and tell people to pick the right options if they run into trouble?
I'm in favour of uniformity as this always comes back to bite one in the future. It's a relatively niche option and so a note in the Changes file should suffice for the change.
Actually now that I think about it again, citation tracking and back references are quite different and it may make sense to stick with the current behaviour: Citation tracking is about context, where the float position can be tricky, but back references are just about on which page an entry was cited (that is picked up with \labels, so we can't run into TeXnical trouble) and that is clearly visible no matter how/when you read floats.
I may want to think about decoupling citecounter from the citetracker boolean...
https://github.com/moewew/biblatex/commit/f18276bdc46f728cb02eb2cb68a440ed57de6ac9 has a first stab at decoupling citecounter from the citetracker bool. Conceptually I think this is the right thing to do, since citation tracking is more context dependent and tricky to get right than cite counting.
Unfortunately, the fact that we introduce a new citeounter bool means that \citetrackerfalse (or equivalent \boolfalse{citetracker}) is no longer adequate to avoid citation counting, \citecounterfalse needs to be added as well. Several styles define new commands with \citetrackerfalse, those commands would be affected with citecounterfalse. Probably not very dramatic and the fix is very easy, but the following styles would be affected
archaeologie(indeed very much so, because it actually setscitecounter=true): https://github.com/LukasCBossert/biblatex-archaeologie/issuesbiblatex-abnt(also setscitecounter- at least sometimes) https://github.com/abntex/biblatex-abnt/issuesbiblatex-apa/biblatex-apa6: https://github.com/plk/biblatex-apa/issuesbiblatex-chicagobiblatex-dwbiblatex-lnibiblatex-mlabiblatex-philosophybiblatex-fiwibiblatex-gosthttps://github.com/odomanov/biblatex-gost/issuesbiblatex-musuosbiblatex-sblhttps://github.com/dcpurton/biblatex-sbl/issuesbiblatex-ext