Biblatex で特定の引用の著者をスキップし、参考文献に保持するようにします

Biblatex で特定の引用の著者をスキップし、参考文献に保持するようにします

author特定のコマンドで biblatex エントリのフィールドを破棄し\cite(著者がまったくいないかのように)、それでも biliography にリストされるようにしたいと思います。

図は私のオリジナル作品であり、引用文の中で自分の名前を繰り返すのは不自然であるため、これが必要です。つまり、基本的には次のようになります。

\begin{figure}[!hbt]
  \centering
  \includegraphics[width=300px]{image.jpg}
  \caption{\cite[]{the-biblatex-entry}} % *shouldn't* produce my name, only title, date, etc...
\end{figure}

\printbibliography % *should* produce my name, along with title, date, etc...

以外のコマンドを使用してもかまいません。コマンドの作成方法さえわかれば、\cite本当に使いたいです。\citenoauthor

編集: MWEはこちら

\documentclass{article}
\usepackage{filecontents}

\begin{filecontents}{example.bib}
@book{somebook,
title = {Book's title},
author = {Author, Some},
location = {The City},
publisher = {Publisher},
date = {2005},
}
\end{filecontents}

\usepackage[style=verbose,backend=bibtex]{biblatex} %backend tells biblatex what you will be using to process the bibliography file
\bibliography{example}

\begin{document}
\cite{somebook} % I'd like this to not include the author, only the other fields
\printbibliography % All the fields, please
\end{document}

答え1

この\caption問題は、 を賢明に使用するか、 を使って独自の「堅牢な」コマンドを定義することで解決できます(\protectデフォルトではrequires と loads )。つまり、次のようになります。etoolbox\newrobustcmdbiblatexetoolbox

\caption{%
  \AtNextCitekey{\protect\clearname{author}}%
  \cite{somebook}}

または:

\newrobustcmd{\hlcite}[1]{%
  \AtNextCitekey{\clearname{author}}%
  \cite{#1}}

完全な例:

\documentclass{article}
\usepackage{filecontents}

\begin{filecontents}{example.bib}
@book{somebook,
title = {Book's title},
author = {Author, Some},
location = {The City},
publisher = {Publisher},
date = {2005},
}
\end{filecontents}

\usepackage[style=verbose,backend=bibtex]{biblatex}
%\bibliography{example}% <-- deprecated
\addbibresource{example.bib}
\usepackage{caption}

\newrobustcmd{\hlcite}[1]{%
  \AtNextCitekey{\clearname{author}}%
  \cite{#1}}

\begin{document}
\begin{figure}
  \rule{3cm}{3cm}
  \caption{%
    \AtNextCitekey{\protect\clearname{author}}%
    \cite{somebook}}
\end{figure}

\begin{figure}
  \rule{3cm}{3cm}
  \caption{\hlcite{somebook}}
\end{figure}

\printbibliography
\end{document}

関連情報