如何設定自己的縮寫。用於引用?

如何設定自己的縮寫。用於引用?

如何設定自己的引文縮寫?假設.bib文件中有以下條目:

@book{ChBj,
    title = "Functional Programming in Scala",
    author = "Paul Chiusano and Rúnar Bjarnason",
    year = 2014,
    month = "September",
    isbn = "978-1617290657",
    edition = "1st",
    publisher = "Manning Publications",
}

我想顯示使用過的[ChBj]縮寫。代替[CB14]。我該如何定義呢?

我夢想有兩種可能的方法,但是我無法用谷歌搜尋其中任何一種:

  1. 設定\bibliographystyle為採用文件中定義的引文名稱
  2. 在引文定義中設定一些特殊字段,例如abbr = "MyAbbr"

有可能嗎?如果可以的話,容易嗎?如果是這樣,怎麼辦?

編輯:

我使用 natbib:

\usepackage{natbib}
\bibliographystyle{alpha}

答案1

biblatex包有兩種引用樣式“草稿”和“調試”,這似乎就是這樣做的(使用texdoc biblatex或透過 CTAN 查看文件)。

如果您正在起草文檔,那麼使用這些鍵實際上似乎很有用,因為您可以透過該鍵最快地在參考書目文件中找到條目。

但是,如果您打算在已發表的論文中使用它,請考慮使用習慣的引用樣式,例如authoryear.切換到這個只是設定包的選項。

答案2

biblatex提供了一個shorthand可以在參考書目資料庫中設定的字段,並且將設置該字段而不是 biblatex 樣式將列印的標籤。這是一個簡短的例子:

\documentclass{article}
\usepackage{biblatex}
\begin{filecontents}{\jobname.bib}
    @online{texsx,
        author={{The community}},
        url={https://tex.stackexchange.com/},
        shorthand={TeX.SX},
    }
\end{filecontents}
\addbibresource{\jobname.bib}
\addbibresource{biblatex-examples.bib}
\begin{document}
You can find help reading the \citetitle{companion}
\cite{companion}, but internet communities are also a good place 
\cite{texsx}.
\printbibliography
\end{document}

petrbel速記

相關內容