
Я хочу добавить определение в свой файл LaTeX. Однако у меня есть точка после слова definition. Как мне ее убрать? Я хочу:
Определение Вот определение
НЕТ
Определение. Вот определение.
\newtheorem*{definition*}{Definition}
\begin{definition*}
Here is the definition
\end{definition*}
решение1
Точка, похоже, определяется в макросе \@thm
линией
\thm@headpunct{.}% add period after heading
Я xpatch
это обычно меняю.
\documentclass{article}
\usepackage{amsthm,xpatch}
\makeatletter
\xpatchcmd{\@thm}{.}{}{}{}
\makeatother
\begin{document}
\makeatletter
\newtheorem*{definition*}{Definition}
\begin{definition*}
Here is the definition
\end{definition*}
\end{document}
Для справки, вот определение \@thm
в amsthm.sty
:
\def\@thm#1#2#3{%
\ifhmode\unskip\unskip\par\fi
\normalfont
\trivlist
\let\thmheadnl\relax
\let\thm@swap\@gobble
\thm@notefont{\fontseries\mddefault\upshape}%
\thm@headpunct{.}% add period after heading
\thm@headsep 5\p@ plus\p@ minus\p@\relax
\thm@space@setup
#1% style overrides
\@topsep \thm@preskip % used by thm head
\@topsepadd \thm@postskip % used by \@endparenv
\def\@tempa{#2}\ifx\@empty\@tempa
\def\@tempa{\@oparg{\@begintheorem{#3}{}}[]}%
\else
\refstepcounter{#2}%
\def\@tempa{\@oparg{\@begintheorem{#3}{\csname the#2\endcsname}}[]}%
\fi
\@tempa
}