
LaTeX ファイルに定義を追加したいのですが、定義という単語の後にドットがあります。これを削除するにはどうすればよいですか? 必要なのは:
定義 定義は次のとおりです
ない
定義。これが定義です
\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
}