我正在使用 LaTeX2e,并且不希望我的文本中出现的缩写(在\cite
)也出现在参考书目的左边距,因此:
\documentclass{article}
\usepackage{graphicx}\usepackage{rotating}
\usepackage{amsmath}
%...
\makeatletter
%...
\def\@biblabel#1{}
%...
\makeatother
%...
\begin{document}
%...
\begin{thebibliography}{}
\bibitem[Aitken 1935]{Aitken}Aitken AC (1935): Note on selection from a multivariate normal population. \emph{Proceedings of the Edinburgh Mathematical Society}, 4:106--110.
%...
\end{thebibliography}
%...
\end{document}
问题在于参考书目项目的缩进比文章其余部分的缩进稍微多一些:
我希望它们缩进与文章正文相同。如何将参考文献移到左侧?
(注意:我不想使用 BibTeX,因为(a)将它用于此有点小题大做(特别是因为我不打算在未来的论文中使用这些参考文献)并且(b)这是我必须学习的另一件事。)
答案1
您可以重新定义thebibliography
环境,如中所定义article.cls
,以抑制额外的空间;在下面的例子中,我展示了重新定义(它包括注释掉该行\advance\leftmargin\labelsep
):
\documentclass{article}
\makeatletter
\def\@biblabel#1{}
\renewenvironment{thebibliography}[1]
{\section*{\refname}%
\@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
\list{\@biblabel{\@arabic\c@enumiv}}%
{\settowidth\labelwidth{\@biblabel{#1}}%
\leftmargin\labelwidth
%\advance\leftmargin\labelsep
\@openbib@code
\usecounter{enumiv}%
\let\p@enumiv\@empty
\renewcommand\theenumiv{\@arabic\c@enumiv}}%
\sloppy
\clubpenalty4000
\@clubpenalty \clubpenalty
\widowpenalty4000%
\sfcode`\.\@m}
{\def\@noitemerr
{\@latex@warning{Empty `thebibliography' environment}}%
\endlist}
\makeatother
\begin{document}
\begin{thebibliography}{}
\bibitem[Aitken 1935]{Aitken}Aitken AC (1935): Note on selection from a multivariate normal population. \emph{Proceedings of the Edinburgh Mathematical Society}, 4:106--110.
\end{thebibliography}
\end{document}
使用该etoolbox
包,可以以更短的方式完成重新定义:
\documentclass{article}
\usepackage{etoolbox}
\makeatletter
\def\@biblabel#1{}
\makeatother
\patchcmd{\thebibliography}{\advance\leftmargin\labelsep}{}{}{}
\begin{document}
\begin{thebibliography}{}
\bibitem[Aitken 1935]{Aitken}Aitken AC (1935): Note on selection from a multivariate normal population. \emph{Proceedings of the Edinburgh Mathematical Society}, 4:106--110.
\end{thebibliography}
\end{document}