![如何更改biblatex包中的中文参考文献格式?](https://linux22.com/image/368166/%E5%A6%82%E4%BD%95%E6%9B%B4%E6%94%B9biblatex%E5%8C%85%E4%B8%AD%E7%9A%84%E4%B8%AD%E6%96%87%E5%8F%82%E8%80%83%E6%96%87%E7%8C%AE%E6%A0%BC%E5%BC%8F%EF%BC%9F.png)
首先,我想提供一个最小的工作样本和我的bib
文件。
工作样本是
\documentclass[a4paper,oneside]{ctexbook}
%%%添加参考文献%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[backend = biber, style = caspervector, utf8,
sorting = ecnty,seconds=true,maxnames = 9999,
ugly]{biblatex}
\addbibresource{liuref.bib}
\begin{document}
\supercite{Aoml1970},\parencite{Aecl1971},\parencite{Lyym1995}三种;
\printbibliography[title = {文献}, heading = bibintoc] \nocite{*}
\end{document}
我的liuref.bib
文件是
@incollection{Aoml1970,
title={Advice on modal logic},
author={D. Scott},
booktitle={Philosophical Problems in Logic: Some Recent Developments},
editor={K. Lambert},
pages={143--173},
year={1970},
publisher={Springer}
}
@phdthesis{Aecl1971,
title = {An Essay in Classical Modal Logic},
school = {Stanford University},
author = {K. Segerberg},
year = {1971},
type = {{PhD} dissertation},
note={\url{http://lpcs.math.msu.su/~zolin/ml/pdf/Segerberg_Essay_1971.pdf}},
}
@article{Lyym1995,
title={方法论研究},
author={神州 and 华夏 and 北极 and 南京},
year={1995},
journal={辽阔大江},
volume={5},
pages={52-56},
language={chinese}
}
@inproceedings{talbot97,
author = {Talbot, Nicola and Cawley, Gavin’},
title = {A fast index assignment algorithm for robust vector quantisation of image data},
booktitle = {Proceedings of the I.E.E.E. International Conference on Image Processing},
address = {Santa Barbara, California, USA},
year = {1997},
}
@article{molodtsov1999soft,
title={Soft set theory—first results},
author={Molodtsov, Dmitriy},
journal={Computers \& Mathematics with Applications},
volume={37},
number={4-5},
pages={19--31},
year={1999},
publisher={Elsevier}
}
我用来xelatex+biber+xelatex+xelatex
编译并得到以下结果:
我的目标是
- 我想让所有标题成为(仅)英文参考的默认字体。
- 我想添加所有标题(包括书籍、小册子、书中、会议记录、会议记录=会议、合集、报纸、文章、硕士论文、博士论文、技术报告、未发表;不包括其他种类的标题)所有(仅)中文参考文献均附有《》。
- 我不想更改所有参考文献的其他格式。
下图是我想要的英文和中文参考文献的格式。我只能获得英文版或中文版,但不能同时获得。
和
谁能帮助我?任何帮助我都会很感激和欢迎!
答案1
您需要修改的定义位于biblatex-caspervector-utf8.def
和中caspervector.bbx
。
这似乎或多或少符合您的要求(请参阅评论以了解描述):
\documentclass[a4paper,oneside]{ctexbook}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@incollection{Aoml1970,
title = {Advice on modal logic},
author = {D. Scott},
booktitle = {Philosophical Problems in Logic: Some Recent Developments},
editor = {K. Lambert},
pages = {143--173},
year = {1970},
publisher = {Springer}
}
@phdthesis{Aecl1971,
title = {An Essay in Classical Modal Logic},
school = {Stanford University},
author = {K. Segerberg},
year = {1971},
type = {{PhD} dissertation},
note = {\url{http://lpcs.math.msu.su/~zolin/ml/pdf/Segerberg_Essay_1971.pdf}},
}
@article{Lyym1995,
title = {方法论研究},
author = {神州 and 华夏 and 北极 and 南京},
year = {1995},
journal = {辽阔大江},
volume = {5},
pages = {52-56},
language = {chinese},
}
@inproceedings{talbot97,
author = {Talbot, Nicola and Cawley, Gavin’},
title = {A fast index assignment algorithm for robust vector quantisation of image data},
booktitle = {Proceedings of the I.E.E.E. International Conference on Image Processing},
address = {Santa Barbara, California, USA},
year = {1997},
}
@article{molodtsov1999soft,
title = {Soft set theory—first results},
author = {Molodtsov, Dmitriy},
journal = {Computers \& Mathematics with Applications},
volume = {37},
number = {4-5},
pages = {19--31},
year = {1999},
publisher = {Elsevier}
}
\end{filecontents}
\usepackage[style=caspervector,utf8,sorting=ecnty,seconds=true,maxnames=99]{biblatex}
\addbibresource{\jobname.bib}
\makeatletter
% use English period for Chinese
\renewcommand*\bbx@cnperiod{\addperiod\space}
% Use Chinese opening double quote
\renewcommand*\bbx@cnldquot{《}
% Use Chinese closing double quote
\renewcommand*\bbx@cnrdquot{》}
% Don't use quotes for English
\renewcommand*{\bbx@mybibquote}[1]%
{\bbx@cepunct{\bbx@cnldquot{#1}\bbx@cnrdquot}{#1}}
% Quote Chinese titles and emphasise English titles
\DeclareFieldFormat*{title}{\bbx@mybibquote{\mkbibemph{#1}}}
\DeclareFieldFormat*{booktitle}{\bbx@mybibquote{\mkbibemph{#1}}}
\DeclareFieldFormat*{maintitle}{\bbx@mybibquote{\mkbibemph{#1}}}
\DeclareFieldFormat*{journaltitle}{\bbx@mybibquote{\mkbibemph{#1}}}
% Don't emphasise English titles for article, etc.
\DeclareFieldFormat[inbook, inproceedings, incollection, article]{title}{%
\bbx@mybibquote{#1}}
% Don't bold volume
\DeclareFieldFormat*{volume}{#1}
% Don't emphasise year
\DeclareFieldFormat*{year}{#1}
\makeatother
\begin{document}
\nocite{*}
\printbibliography[title = {文献}]
\end{document}