23

我正在编写一个简短的文档,使用部分而不是章节作为顶层(文档类报告)。然而,

\bibliographystyle{amsplain}
\bibliography{general}

导致参考书目作为章节而不是章节插入。有什么办法可以改变这个吗?

4

4 回答 4

32

默认情况下,report文档类\chapter用作书目标题级别。相反,article文档类\section用作书目标题级别。如果您没有\chapter在文档中的任何地方使用,您可能希望使用article该类。

如果您真的想使用report该类,则需要重新定义thebibliography要使用的环境,\section而不是\chapter. 在文档的序言中(行后\documentclass但行前\begin{document},插入以下内容:

\makeatletter
\renewenvironment{thebibliography}[1]
     {\section*{\bibname}% <-- this line was changed from \chapter* to \section*
      \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}%
      \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

现在您的参考书目将有一个\section标题而不是\chapter标题。

请注意,如果您加载任何特殊的书目包,您可能希望在加载这些包之前放置此代码(这样您就不会覆盖它们的工作)。

于 2009-06-24T23:03:16.200 回答
9

查看包tocibind

\usepackage[numbib,notlof,notlot,nottoc]{tocbibind}

numbib确保参考书目被编号,而not*-options 分别禁用显示图形列表、表格和目录本身。

于 2009-07-26T15:14:01.873 回答
0

就我而言,我还更改了@godbyk 的解决方案以包含节号。

@godbyk 的台词:

{\section*{\bibname}% <-- this line was changed from \chapter* to \section*

我的线路:

{\section{\bibname}% <-- this line was changed from \chapter* to \section
于 2013-11-24T14:33:47.387 回答
-1

对于章节级别的参考,可以使用:\addcontentsline{toc}{chapter}{References}。要将它们放在部分级别,可以使用:\addcontentsline{toc}{section}{References}

于 2021-06-06T18:07:50.430 回答