我正在使用 IEEEtran 定理环境并\newtheorem{definition}{Definition}[section]
自定义定义。总的来说,我对它的输出感到满意:
但是,对于另一个后跟长单词的定义(即此处的 PrecedingWrite),它会拆分该单词(如 Preceding-Write):
我可以用来\mbox{PrecedingWrite}
强制其“完整性”。但是这个定义的第一行变得不对齐。
所以,
如何既能保证单词“PrecedingWrite”的“完整性”,又能使第一行保持对齐?(为此,您可以打破第一行。但是,我不想要全局选项
\newline
。)非常感谢。
上图第二张图的说明代码:
\documentclass{IEEEtran}% http://www.ctan.org/pkg/ieeetran
\newtheorem{definition}{Definition}[section]
\begin{document}
\begin{definition}[\textsl{PrecedingWrite (PW)}] \label{def:precedingwrite}
\textsl{PrecedingWrite} is a matrix such that for each operation
$o$ and each variable $v$, the entry $\textsl{PW}[o][v] = w$ if and only if
\end{definition}
\end{document}
答案1
但是 IEEEtran 会自动执行您描述的过程。一个例子是使用其他一些单词,但结果应该在第二个定义中可见:第一行充满胶水。
\documentclass{IEEEtran}% http://www.ctan.org/pkg/ieeetran
\newtheorem{definition}{Definition}[section]
\begin{document}
\section{}
\begin{definition}[\textsl{PrecedingWrite (PW)}] \label{def:precedingwrite}
\textsl{PrecedingWrite} is a matrix such that for each operation
$o$ and each variable $v$, the entry $\textsl{PW}[o][v] = w$ if and only if
\end{definition}
\begin{definition}[\textsl{LongPrecedingWrite (LPW)}] \label{def:precedingwrite}
\textsl{LongPrecedingWrite} is a matrix such that for each operation
$o$ and each variable $v$, the entry $\textsl{PW}[o][v] = w$ if and only if
\end{definition}
\end{document}
如果这样的结果没有自动完成,您可以随时(从我可以推断的评论中,它只完成一次)强制换行,例如以以下方式:
\begin{definition}[\textsl{PrecedingWrite (PW)}] \label{def:precedingwrite}\hfill
\textsl{PrecedingWrite} is a matrix such that for each operation
$o$ and each variable $v$, the entry $\textsl{PW}[o][v] = w$ if and only if
\end{definition}