Latex:章节标题中的引文首先放入目录

时间:2022-02-28 06:13:53

I have some citations for sections of my document that I have put in the section heading:

对于我在文章中添加的文档部分,我有一些引用:

\section{The title \cite{abc}, \cite{def}} Text

\ section {标题\引用{abc},\ cite {def}}文字

I am also using the table of contents function, but Latex must look at the citations in the headings (for the table of contents) first and assign them the first citation rankings, regardless of their place in the overall document.

我也使用目录功能,但Latex必须首先查看标题中的引文(对于目录),并为它们分配第一个引文排名,无论它们在整个文档中的位置如何。

So, any citations inside of \section or \subsection will be assigned [1], [2], and so on, and the citations within the text in the section follow after.

因此,\ section或\ subsection中的任何引用都将被分配[1],[2],依此类推,并且该部分文本中的引用将在之后进行。

Has anyone encountered this problem before? Is there any way of getting around this other than simply putting the \cite command somewhere inside the paragraph? I'd like to avoid this if possible.

以前有人遇到过这个问题吗?除了简单地将\ cite命令放在段落中的某个位置之外,有什么方法可以解决这个问题吗?如果可能的话,我想避免这种情况。

Cheers in advance!

提前干杯!

5 个解决方案

#1


You may perhaps not like this answer, but I think citations in headings is a bad style. I would rather recommend that you use another heading and then throw your citation references in the paragraphs following it. I've read quite some papers and none of those I recall used references in headings.

您可能不喜欢这个答案,但我认为标题中的引用是一种糟糕的风格。我宁愿建议您使用另一个标题,然后在其后面的段落中引用您的引文参考。我已经阅读了很多论文,而且我没有回忆过标题中使用过的参考文献。

In the same vein, may I recommend using bibTex and bibtool for managing your bibliography database. Bibtool can normalize the citation keys so you can just drop other peoples bibtex references, run bibtool, and then you have standardized keys.

同样,我可以建议使用bibTex和bibtool来管理您的书目数据库。 Bibtool可以对引文键进行规范化,这样您就可以删除其他人的bibtex引用,运行bibtool,然后就可以使用标准化键。

#2


I agree with jlouis' recommendation of avoiding citations in section headings. But if you insist, one solution may be to use the following form of the \section command:

我同意jlouis关于在章节标题中避免引用的建议。但是如果你坚持,一个解决方案可能是使用以下形式的\ section命令:

\section[Section title sans citation]{Section title with citation\cite{key}}

The table of contents will contain an entry consisting of the first (optional) argument ("Section title sans citation") and the section heading itself will be the second (required) argument ("Section title with citation[34]").

目录将包含一个由第一个(可选)参数组成的条目(“Section title sans citation”),而section标题本身将是第二个(必需的)参数(“section section with citation [34]”)。

The first (optional) argument will also be used as the text in the running heads by default.

默认情况下,第一个(可选)参数也将用作运行头中的文本。

#3


The problem is that the reference has not been registered. Use \nocite{abc} everywhere, for instance just after subsection{... \cite{abc}...}.

问题是引用尚未注册。在任何地方使用\ nocite {abc},例如在{。\ cite {abc} ...}小节之后。

#4


Just place the citation after the attribute.

只需在属性后面放置引文即可。

Exapmle," \section{Conclusion}\cite{citation} ".

Exapmle,“\ section {结束} \ cite {citation}”。

The citation label will not show up in table of contents and will show only beside the section title.

引文标签不会显示在目录中,只会显示在标题旁边。

#5


I ran into a similar problem when writing my thesis, but rather than being with headings it was citations embedded in figure captions. I got around the caption problem with the following:

在撰写我的论文时,我遇到了类似的问题,但不是在标题中,而是在图标题中嵌入了引文。我通过以下方法解决了标题问题:

\caption{main caption. taken from \cite{abc}}{main caption}

LaTeX takes the first argument for the figure caption, and the second argument for the caption that it puts in the list of figures. The lack of citations in the figure list means the ordering in the main body is correct.

LaTeX采用数字标题的第一个参数,以及它放在数字列表中的标题的第二个参数。图表中缺少引用意味着主体的排序是正确的。

I'm working from memory so the order of arguments above may be backwards. Regardless, see if headings can be defined in the same way.

我正在从记忆中工作,所以上面论点的顺序可能是倒退的。无论如何,看看标题是否可以以相同的方式定义。

#1


You may perhaps not like this answer, but I think citations in headings is a bad style. I would rather recommend that you use another heading and then throw your citation references in the paragraphs following it. I've read quite some papers and none of those I recall used references in headings.

您可能不喜欢这个答案,但我认为标题中的引用是一种糟糕的风格。我宁愿建议您使用另一个标题,然后在其后面的段落中引用您的引文参考。我已经阅读了很多论文,而且我没有回忆过标题中使用过的参考文献。

In the same vein, may I recommend using bibTex and bibtool for managing your bibliography database. Bibtool can normalize the citation keys so you can just drop other peoples bibtex references, run bibtool, and then you have standardized keys.

同样,我可以建议使用bibTex和bibtool来管理您的书目数据库。 Bibtool可以对引文键进行规范化,这样您就可以删除其他人的bibtex引用,运行bibtool,然后就可以使用标准化键。

#2


I agree with jlouis' recommendation of avoiding citations in section headings. But if you insist, one solution may be to use the following form of the \section command:

我同意jlouis关于在章节标题中避免引用的建议。但是如果你坚持,一个解决方案可能是使用以下形式的\ section命令:

\section[Section title sans citation]{Section title with citation\cite{key}}

The table of contents will contain an entry consisting of the first (optional) argument ("Section title sans citation") and the section heading itself will be the second (required) argument ("Section title with citation[34]").

目录将包含一个由第一个(可选)参数组成的条目(“Section title sans citation”),而section标题本身将是第二个(必需的)参数(“section section with citation [34]”)。

The first (optional) argument will also be used as the text in the running heads by default.

默认情况下,第一个(可选)参数也将用作运行头中的文本。

#3


The problem is that the reference has not been registered. Use \nocite{abc} everywhere, for instance just after subsection{... \cite{abc}...}.

问题是引用尚未注册。在任何地方使用\ nocite {abc},例如在{。\ cite {abc} ...}小节之后。

#4


Just place the citation after the attribute.

只需在属性后面放置引文即可。

Exapmle," \section{Conclusion}\cite{citation} ".

Exapmle,“\ section {结束} \ cite {citation}”。

The citation label will not show up in table of contents and will show only beside the section title.

引文标签不会显示在目录中,只会显示在标题旁边。

#5


I ran into a similar problem when writing my thesis, but rather than being with headings it was citations embedded in figure captions. I got around the caption problem with the following:

在撰写我的论文时,我遇到了类似的问题,但不是在标题中,而是在图标题中嵌入了引文。我通过以下方法解决了标题问题:

\caption{main caption. taken from \cite{abc}}{main caption}

LaTeX takes the first argument for the figure caption, and the second argument for the caption that it puts in the list of figures. The lack of citations in the figure list means the ordering in the main body is correct.

LaTeX采用数字标题的第一个参数,以及它放在数字列表中的标题的第二个参数。图表中缺少引用意味着主体的排序是正确的。

I'm working from memory so the order of arguments above may be backwards. Regardless, see if headings can be defined in the same way.

我正在从记忆中工作,所以上面论点的顺序可能是倒退的。无论如何,看看标题是否可以以相同的方式定义。