我是 Latex 的新手,所以请记住这一点。我在 Google Docs 中写了我的论文,但现在我想使用 Latex 打印/格式化它。所以我使用 ShareLatex.com 来实现这一点。现在我花了一段时间才到这里,但它仍然不太好用,我似乎无法在网上找到解决方案。
以下是我得到的结果:
主文本
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[swedish, english]{babel}
\title{Title}
\author{The Auther}
\date{14 November 2016}
\usepackage{graphicx}
\usepackage{csquotes}
\usepackage[backend=biber, style=ieee, urldate=comp]{biblatex}
\addbibresource{references.bib} %Imports bibliography file
\begin{document}
\selectlanguage{swedish}
\maketitle
\pagenumbering{gobble}
\pagebreak
\tableofcontents
\pagebreak
\pagenumbering{arabic}
\section{Inledning}
There is a theory which states that if ever anyone discovers exactly what the Universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarre and inexplicable.
There is another theory which states that this has already happened.
\section{Conclusion}
``I always thought something was fundamentally wrong with the universe'' \cite{einstein}.
\printbibliography
\selectlanguage{english}
\printbibliography
\end{document}
参考文献.bib
@article{einstein,
author = {Andreas Eidehall and Jochen Pohl and Fredrik Gustafsson and Jonas Ekmark},
title = {Toward Autonomous Collision Avoidance by Steering},
journal = {IEEE Transactions on Intelligent Transportation Systems},
volume = 8,
number = 1,
pages = {84-94},
month = dec,
year = 1905,
url = {http://ieeexplore.ieee.org/document/4114341},
urldate = {2015-11-09},
}
正如您在图片上看到的,格式不正确。它只是说“URL:”,它应该说我在图片上评论的内容,“[在线]。Tillgänglig:”
我该如何修复此问题?我可以覆盖语言翻译来修复此问题吗?
答案1
您可以添加缺少的语言定义(我不懂瑞典语所以只翻译了 url):
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[swedish, english]{babel}
\title{Title}
\author{The Auther}
\date{14 November 2016}
\usepackage{graphicx}
\usepackage{csquotes}
\usepackage[backend=biber, style=ieee, urldate=comp]{biblatex}
\addbibresource{references.bib} %Imports bibliography file
\DefineBibliographyStrings{swedish}{
andothers = \mkbibemph{et al\adddot} ,
chapter = ch\adddot ,
editor = Ed\adddot ,
editors = Eds\adddot ,
mathesis = Master's thesis ,
patentjp = Japanese Patent ,
patentus = U\adddot S\adddot\addspace Patent ,
presentedat = presented at the\addspace ,
techreport = Tech\adddot\addspace Rep\adddot ,
url = [Online]\adddot\addspace Tillgänglig ,
}
\begin{document}
\selectlanguage{swedish}
\maketitle
\pagenumbering{gobble}
\pagebreak
\tableofcontents
\pagebreak
\pagenumbering{arabic}
\section{Inledning}
There is a theory which states that if ever anyone discovers exactly what the Universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarre and inexplicable.
There is another theory which states that this has already happened.
\section{Conclusion}
``I always thought something was fundamentally wrong with the universe'' \cite{einstein}.
\printbibliography
\selectlanguage{english}
\printbibliography
\end{document}