summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-07-14 16:22:32 +0000
committerKarl Berry <karl@freefriends.org>2012-07-14 16:22:32 +0000
commit8ff57bdca1f2f31861913ebc22961fdb89240cbd (patch)
tree16bce8182f2d5b16a36d589de033fd2ea5f7e8e2 /Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty
parent7580e0584873d1ed5ed97c98b87e3aa32753ea46 (diff)
computational-complexity 2.24 (18jun12)
git-svn-id: svn://tug.org/texlive/trunk@27047 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty')
-rw-r--r--Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty12
1 files changed, 11 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty b/Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty
index 927aaf1fe99..3138eb30e1a 100644
--- a/Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty
+++ b/Master/texmf-dist/tex/latex/computational-complexity/ccthm.sty
@@ -92,8 +92,15 @@
\defprefix{enumiv}##1{(\theenumi.\theenumii.\theenumiii##1)}
}
\fi
+\def\reset@prefixrefstepcounter#1{%
+ \let\refstepcounter\cc@normal@refstepcounter% Put refstepcounter back to normal
+ \refstepcounter{#1}% do normal operation
+ \defprefix{equation}##1{(##1)}% reset equation prefix
+}
\def\theorempreamblenn\@thm#1#2{%
\defprefix{#1}##1{#2}%
+ \let\cc@normal@refstepcounter\refstepcounter
+ \let\refstepcounter\reset@prefixrefstepcounter
\EnumerationInTheorems{#1}%
\pagebreak[3]\relax
\the\everytheorem
@@ -169,18 +176,21 @@
{\qed\csname endnamedtheorem*\endcsname}
\def\theorempreamble\@thm#1#2{%
\defprefix{#1}##1{#2~##1}%
+ \let\cc@normal@refstepcounter\refstepcounter
+ \let\refstepcounter\reset@prefixrefstepcounter
\EnumerationInTheorems{#1}%
\pagebreak[3]\relax
\the\everytheorem
\@thm{#1}{#2}}
\theorem@bodyfont{\theorempreamble}
\theoremstyle{cc}
-\newtheorem{namedth@@r@m}{\the\theoremtitle}
\if@ccnosepeqncnt
%%% \let\c@namedth@@r@m\c@equation
%%% \def\thenamedth@@r@m{\theequation}
\def\cc@thmcnter{equation}
+\newtheorem{namedth@@r@m}[\cc@thmcnter]{\the\theoremtitle}
\else
+\newtheorem{namedth@@r@m}{\the\theoremtitle}
\def\cc@thmcnter{namedth@@r@m}
\fi
\newenvironment{namedtheorem}[1]