看板LaTeX
标 题Re: [问题] \newtheorem
发信站SayYA 资讯站 (Wed Oct 31 12:19:41 2007)
转信站ptt!ctu-reader!ctu-peer!news.nctu!News.Math.NCTU!SayYa
※ 引述《[email protected] (嘿)》之铭言:
> 不好意思借用一下标题
> 因为想再请教一个关於newtheorem的问题
> 我现在定义了一个example的thoerem如下:
> \newtheorem{example}{\rule{0.9\textwidth}{0.1em}\\Example}[section]
> 这样使用\begin{example}... \end{example}会出现的是像这样:
> ------------------------------
> Example x.x ......
> 现在想在example结束时也加画一条像上面那样的横线
> 该怎麽做呢?
> 目前想到的方法是再定义一个environment把这个example包住
> 再在结尾加上一条横线 不知道有没有别的方法呢? 谢谢:)
除非去改 newtheorem 的原始定义,不然只能另定义一个 environment。
\newtheorem{example}{Example}[section]
\newenvironment{examp}{%
\rule{0.9\textwidth}{0.1em}
\begin{example}%
}{%
\end{example}%
\rule{0.9\textwidth}{0.1em}
}
--
一个神圣的目标是很危险的。当一个目标变得神圣时,
要达到这个目标的手段往往会变得很卑下。(林语堂.快乐的天才)
--
※ Origin: SayYA 资讯站 <bbs.sayya.org>
◆ From: edt1023.sayya.org