summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2014-09-04 21:10:23 +0000
committerKarl Berry <karl@freefriends.org>2014-09-04 21:10:23 +0000
commit23550e4b6a7407977d39f6339f6f9fe2db2ba99e (patch)
treed617006b38f0e36523c53b14219500d24f8ef939 /Master/texmf-dist/doc/latex
parent44619feacee76d2abea54c66454f19077701adbc (diff)
assoccnt (4sep14)
git-svn-id: svn://tug.org/texlive/trunk@35106 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex')
-rw-r--r--Master/texmf-dist/doc/latex/assoccnt/README26
-rw-r--r--Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.pdfbin49574 -> 77420 bytes
-rw-r--r--Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.tex108
-rw-r--r--Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.pdfbin198651 -> 254717 bytes
-rw-r--r--Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.tex288
5 files changed, 375 insertions, 47 deletions
diff --git a/Master/texmf-dist/doc/latex/assoccnt/README b/Master/texmf-dist/doc/latex/assoccnt/README
index 28aa89f3723..a3211634d6f 100644
--- a/Master/texmf-dist/doc/latex/assoccnt/README
+++ b/Master/texmf-dist/doc/latex/assoccnt/README
@@ -1,7 +1,7 @@
-%% LaTeX package assoccnt - version 0.3 (2014/08/21)
+%% LaTeX package assoccnt - version 0.4 (2014/09/04)
%%
%% -------------------------------------------------------------------------------------------
-%% Copyright (c) 2014 by Dr. Christian Hupfer <christian dot hupfer at siebenfelsen dot de>
+%% Copyright (c) 2014 by Dr. Christian Hupfer <christian dot hupfer at yahoo dot de>
%% -------------------------------------------------------------------------------------------
%%
%% This work may be distributed and/or modified under the
@@ -25,13 +25,21 @@ can be used without it too.
Further improvements will follow
-This version provides some new routines for queries on the properties of counters
-whether they are drivers or associated counters and a better documentation.
+
+This version provides
+
+-- a revised scheme -- \addtocounter is used instead of \stepcounter
+-- \setcounter is redefined to obtain an optional argument, which holds
+ a list of associated counters, which should be set to the value as well.
+-- Suspension/resuming of counter is possible, i.e. the counting can be put on hold
+ and resumed later on.
+-- some new routines for queries on the properties of counters
+ whether they are drivers or associated counters and a better documentation.
Directory listing:
- assoccntdoc.pdf 198651 08/21/14 18:33:30
- assoccntdoc.tex 20011 08/21/14 18:33:30
-assoccnt_example.pdf 49574 08/21/14 18:33:30
-assoccnt_example.tex 2681 08/21/14 18:33:25
- assoccnt.sty 8774 08/21/14 18:33:25
+ assoccntdoc.pdf 254717 09/04/14 03:19:44
+ assoccntdoc.tex 29162 09/04/14 03:19:45
+assoccnt_example.pdf 77420 09/04/14 03:19:45
+assoccnt_example.tex 3955 09/04/14 03:15:58
+ assoccnt.sty 14299 09/04/14 03:15:58
diff --git a/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.pdf b/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.pdf
index 1ba1f89e91e..63fe2a67cbe 100644
--- a/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.pdf
+++ b/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.tex b/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.tex
index 8d58612b262..462ed9f7d08 100644
--- a/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.tex
+++ b/Master/texmf-dist/doc/latex/assoccnt/assoccnt_example.tex
@@ -23,20 +23,25 @@
+
\newcounter{loopcounter}%
-\newcommand{\ShowNiceCounterOutput}[5]{%
+\newcommand{\QuickSections}[2]{%
+\forloop{loopcounter}{1}{\value{loopcounter} < \numexpr #1+1}{%
+\csuse{#2}{Dummy #2 -- \theloopcounter}
+}%
+}%
+
+\newcommand{\ShowNiceCounterOutput}[6]{%
\begin{center}%
-\begin{tabular}{llll}%
-& & & \tabularnewline
-& \multicolumn{3}{c}{totcount page values} \tabularnewline
-Page & \textcolor{red}{#1} & \textcolor{blue}{#2} & \textcolor{gray}{#3} \tabularnewline
-\thepage & \textcolor{red}{\number\totvalue{#1}} & \textcolor{blue}{\number\value{#2}} & \textcolor{gray}{\number\value{#3}} \tabularnewline
-& & & \tabularnewline
-% & \multicolumn{3}{c}{totcount section values} \tabularnewline
-%Section & \textcolor{red}{#4} & \textcolor{blue}{#5} \tabularnewline
-%\thesection & \textcolor{red}{\number\totvalue{#4}} & \textcolor{blue}{\number\totvalue{#5}} & \tabularnewline
-& & & \tabularnewline
+\begin{tabular}{lllll}%
+& & & & \tabularnewline
+& \multicolumn{4}{c}{totcount page values} \tabularnewline
+Page & \textcolor{red}{#1} & \textcolor{blue}{#2} & \textcolor{gray}{#3} & \textcolor{violet}{#4}\tabularnewline
+\thepage & \textcolor{red}{\number\totvalue{#1}} & \textcolor{blue}{\number\value{#2}} & \textcolor{gray}{\number\value{#3}} & \textcolor{violet}{\number\totvalue{#4}} \tabularnewline
+Section & \textcolor{red}{#5} & Subsection & \textcolor{blue}{#6} & \tabularnewline%
+\thesection & \textcolor{red}{\number\totvalue{#5}} & \thesubsection & \textcolor{blue}{\number\totvalue{#6}} & \tabularnewline
+& & & & \tabularnewline
\end{tabular}
\end{center}%
}%
@@ -46,62 +51,111 @@ Page & \textcolor{red}{#1} & \textcolor{blue}{#2} & \textcolor{gray}{#3} \tabula
%
\forloop{loopcounter}{1}{\value{loopcounter} < \numexpr #1+1}{%
\pagenumbering{arabic}% -> pagenumber reset to zero , on purpose inside the loop
-\ShowNiceCounterOutput{page}{totalpages}{anotherpagescounter}{section}{totalsections}%
+\ShowNiceCounterOutput{page}{associatedpages}{anotherpagescounter}{yetanotherpagescounter}{associatedsections}{associatedsubsections}%
\blindtext%
\newpage% some pages
}%
}%
-\newcounter{totalpages}
-\newtotcounter{totalsections}%
+
+
+\newcounter{associatedpages}%
\newcounter{anotherpagescounter}%
\regtotcounter{page} % Register a total value counter --> this will be the driver counter
\newtotcounter{yetanotherpagescounter}% 3rd driven counter
+\newtotcounter{associatedsections}%
+
+\newtotcounter{associatedsubsections}%
-\DeclareAssociatedCounters{page}{totalpages,anotherpagescounter,totalpages}% Register the driver and the driven counters
-\DeclareAssociatedCounters{totalpages}{anotherpagescounter}% Register the driver and the driven counters
-\DeclareAssociatedCounters{section}{totalsections}%
+\DeclareAssociatedCounters{page}{associatedpages,anotherpagescounter,associatedpages,yetanotherpagescounter}% Register the driver and the driven counters
+\DeclareAssociatedCounters{section}{associatedsections}%
+\DeclareAssociatedCounters{subsection}{associatedsubsections}%
+
\begin{document}
\tableofcontents%
+\chapter*{Introduction}
+
+This is a dummy document -- it just shows how some of the commands work.
+In section \ref{section::query} same queries and statistics are shown.
\chapter{Chapter one}
\section{First}
+\QuickSections{10}{subsection}%
+
+
+\QuickOutput{10}
+% Suspend the associatedsubsections counters%
+\typeout{Hello!}
+\SuspendCounters{associatedsubsections,associatedpages}%
\QuickOutput{10}
+\clearpage
+
+\subsection[Suspended counters checking]{Checking for suspended counters}
+
+\IsSuspendedCounter{associatedsubsections}{Yes, Counter associatedsubsections is suspended}{No!}
+
+\IsSuspendedCounter{yetanothertotalpages}{Yes}{No!}
-\section{Query routines}%
+\clearpage
+
+\section{Dummy section}%
+
+\QuickSections{10}{subsection}%
+
+% Resume all counters
+\ResumeSuspendedCounters
+\QuickSections{20}{subsection}%
+
+
+
+\clearpage
+
+\section{Query routines} \label{section::query}%
+\setlength{\parindent}{0pt}%
\IsAssociatedCounter{totalsections}{Yes, it's associated}{Nope, it's not associated}
\IsAssociatedCounter{anotherpagescounter}{Yes, it's associated}{Nope, it's not associated}
-\AssociationStatistics%
+\hrule\par
+
+Setting counter section explicitly to another value:
+
+\setcounter{section}{12}%
+
+\hrule\par
+
+Setting counter section explicitly to another value with option enabled:
+
+\setcounter[AssociatedCounters={associatedpages,anotherpagescounter,gandalf}]{page}{20}%
+
+
+
+\AssociatedDriverCounterInfo{page}%
-\IsDriverCounter{section}{Yes, it's a driver counter}{No, it does not have this feature}%
+\AssociatedDriverCounterInfo{associatedpages}%
-\ClearAssociatedCountersList{section}
+\AssociatedDriverCounterInfo{section}%
-\IsDriverCounter{section}{Yes, it's a driver counter}{No, it does not have this feature}%
+\AddAssociatedCounters{page}{associatedpages}%
+\AddAssociatedCounters{page}{associatedpages}%
-\AssociationStatistics%
-Clearing the counters:
+Clearing the counters (This will report wrong values for the associated counters!!!)
-\ClearDriverCountersList
-Show Statistics%
-\AssociationStatistics%
\end{document}
diff --git a/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.pdf b/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.pdf
index 292b4b322a9..d820aa2d4fd 100644
--- a/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.pdf
+++ b/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.tex b/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.tex
index 7d848fd1088..6688576aaaa 100644
--- a/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.tex
+++ b/Master/texmf-dist/doc/latex/assoccnt/assoccntdoc.tex
@@ -23,7 +23,7 @@
\usepackage{amsthm}%
\usepackage{totcount}%
-\usepackage{assoccnt}%
+\usepackage[globalsuspend=false]{assoccnt}%
\usepackage{bookmark}%
@@ -37,10 +37,13 @@
}%
+\let\DeclareAssociatedCountersOrig\DeclareAssociatedCounters
+
+
\newtcolorbox{docCommandArgs}[1]{colbacktitle={blue},coltitle={white},title={Description of arguments of command \cs{#1}}}
-\def\packageversion{0.3}%
+\def\packageversion{0.4}%
\makeindex
@@ -100,6 +103,7 @@ Author: Christian Hupfer\(^\mathrm{\fnsymbol{footnote}}\)% }{\makeatletter chris
+
\pagestyle{scrheadings}%
\setheadsepline{2pt}[\color{blue}]
@@ -122,17 +126,62 @@ This will work, as long there is no reset of the page counter, as it might happe
This package provides associate counters, i.e. counters that are increased simultaneously with a driver counter and are not influenced by a a resetting of the driver counter, as long as not being added to the reset list by definition of the counter or explicitly by \cs{@addtoreset}.
-This package defines some macros to handle associated counters. The only interception to the standard behaviour is within the redefined commands \cs{stepcounter} and \cs{refstepcounter}. The usual commands still work, as there is code added to their definition.
+This package defines some macros to handle associated counters. The only interception to the standard behaviour is within the redefined commands \cs{addtocounter} and \cs{setcounter}. The usual commands still work, as there is code added to their definition. In a previous version, \cs{stepcounter} and \cs{refstepcounter} were redefined, but since these use \cs{addtocounter} effectively, it was decided to use the basic command.
Internally, the associated counters are stored in one list per counter -- it is not recommended to operate on those lists directly.
+Please note, that this package does not provide means for simultaneous stepping of counters defined by plain \TeX{} \cs{newcount} command.
+
+\section{Package options}%
+
+As of version \packageversion~ the package has only one option, regarding the suspending of counters globally, regardless, whether they are drivers or associated counters (more on this facility of the package, see \ref{section::suspendedresumedcounters}.
+
+\begin{docKey}{globalsuspend}{=\meta{true/false}}{initially false}
+ If this key is set to \meta{true}, a a general driver can be set to the suspended list, i.e, it is not updated via \cs{addtocounter}. If unsure, do not use this option or say explicitly
+
+ \begin{dispListing}
+ \usepackage[globalsuspend=false]{assoccnt}
+ \end{dispListing}%
+\end{docKey}
\section{Documentation of Macros}
\tcbset{color command={blue}}
+
+\subsection{Redefined standard commands}
+
+\begin{docCommand}{setcounter}{\oarg{options}\marg{counter}\marg{counter value}}
+
+This command behaves like the standard macro \cs{setcounter}, but has an additional optional 1st argument. This optional argument can be used to enable the setting of the driver counter value as well as the associated counter values at once.
+
+\begin{docCommandArgs}{setcounter}%
+
+
+\begin{enumerate}[label={\textcolor{blue}{\#\arabic*}}]
+ \item \oarg{options}: As of version \packageversion, the only option is the key value argument
+
+ \begin{docKey}{AssociatedToo}{=\meta{true/false}}{initially false}
+ If enabled (\meta{true}), \cs{setcounter} will use the counter value for \underline{all} counters associated to this driver counter as well. Initially, this option is set to \meta{false}.
+ \end{docKey}
+
+ \begin{docKey}{AssociatedCounters}{=\meta{csv list of counters}}{initially unset}
+ If the comma separated list of counter is set, \cs{setcounter} increases those counters only, that are driven counters of the 2nd argument, any unknown counter in this list will generate a warning and is ignored otherwise.
+ \end{docKey}
+ The option keys \refKey{AssociatedToo} and \refKey{AssociatedCounters} are mutually exclusive!
+
+ \item \marg{counter}
+
+ Holds the name of the counter to be set.
+\item \marg{counter value}
+ Holds the value to be set
+\end{enumerate}
+\end{docCommandArgs}
+
+\end{docCommand}%
+
All macros have the general rule, that the driver counter is specified as 1st argument to the macro.
\subsection{Associated counters commands}
@@ -162,7 +211,6 @@ This command is the main macro of the package. It declares the counter names bei
% Relax for documentation purposes
-\let\DeclareAssociatedCountersOrig\DeclareAssociatedCounters
\renewcommand{\DeclareAssociatedCounters}[3][]{\relax}%
\begin{dispExample}
%%%% The association of anothertotalpages in this example just takes place here, so the stepping of the counter will start from here and providing a 'wrong' value.
@@ -213,6 +261,8 @@ This command adds some counters to the associated counter list for a specific dr
This command removes a counter from the existing list for a driver counter, i.e. the counter will not be increased any longer by \cs{stepcounter}. It can be increased however manually, of course.
\end{docCommand}
+
+
\begin{dispExample}
\RemoveAssociatedCounter{page}{anothertotalpages}
This document has \number\totvalue{totalpages} (beware: \number\totvalue{anothertotalpages}) pages.
@@ -311,6 +361,7 @@ See also
\item \refCom{IsAssociatedCounter} for checking whether a counter is associated
\item \refCom{IsDriverCounter} in order to check whether a counter is a driver.
\item \refCom{GetDriverCounter} returns the driver counter name for a given associated counter name
+ \item \refCom{AssociatedDriverCounterInfo} prints verbose information to the document (not to the screen!)
\end{itemize}
@@ -398,6 +449,174 @@ This commands tests, whether a given counter name is a driver counter and expand
\end{docCommand}%
+\begin{docCommand}{IsSuspendedCounter}{\marg{counter name}\marg{true branch}\marg{false branch}}
+See \nameref{section::suspendedresumedcounters} on this topic.
+
+This command checks, whether a counter is suspended, i.e. not updated at all and expands the corresponding branches.
+
+\begin{docCommandArgs}{IfSuspendedCounter}%
+
+\begin{enumerate}[label={\textcolor{blue}{\#\arabic*}}]
+\item \marg{counter name}%
+
+ Contains the name of counter presumed to be suspended
+
+\item \marg{True branch}
+
+ This code is expanded if the counter is suspended, otherwise it is ignored
+
+\item \marg{True branch}
+
+ This code is expanded if the counter is \textbf{not} suspended, otherwise it is ignored
+
+\end{enumerate}
+\end{docCommandArgs}
+
+
+
+\end{docCommand}
+
+
+\begin{docCommand}{AssociatedDriverCounterInfo}{\marg{counter name}}
+
+This command is purposed for statistics only, for package/class authors for example and should not be used in a real document, as it generates verbose output to the document.
+
+
+
+\begin{dispExample}
+%% Adding the counter anothertotalpages first
+\AddAssociatedCounters{page}{anothertotalpages}%
+\AssociatedDriverCounterInfo{page}%
+\end{dispExample}
+
+\begin{dispExample}
+% This shows information on an associated counter
+\AssociatedDriverCounterInfo{totalpages}%
+\end{dispExample}
+
+\begin{dispExample}
+% This shows information on a counter which is neither a driver nor an associated counter
+\AssociatedDriverCounterInfo{equation}%
+\end{dispExample}
+
+
+\end{docCommand}%
+
+\subsection{Minor macros}
+
+For the informational output on counter properties in conjunction with the macro
+ \refCom{AssociatedDriverCounterInfo}, some helper macros have been defined:
+
+\begin{docCommand}{PrettyPrintCounterName}{\oarg{countertype}\marg{counter name}}
+This command just prints a counter name with frame. It's meant of informational use only.
+\begin{docCommandArgs}{PrettyPrintCounterName}
+\begin{enumerate}[label={\textcolor{blue}{\#\arabic*}}]
+\item \oarg{options}%
+
+ As of version \packageversion, the only option is a key value:
+ \begin{docKey}{countertype}{=\meta{general,driver,associated}}{general}
+ Use
+ \begin{itemize}
+ \item \meta{general} for an arbitrary counter name
+ \item \meta{driver} for a driver counter
+ \item \meta{associated} for an associated counter
+ \end{itemize}
+ \end{docKey}
+
+\item \marg{counter name}
+ Contains the name of counters to be displayed
+
+\end{enumerate}
+\end{docCommandArgs}%
+
+Please note, that as of version \packageversion, this command does not autodetect the property of the counter nor if the 2nd argument holds a real counter name at all
+\end{docCommand}%
+
+\begin{docCommand}{GeneralCounterInfoColor}{}
+This macro holds the text color for a general counter, it defaults to \meta{\textcolor{\GeneralCounterInfoColor}{\expandafter{\GeneralCounterInfoColor}}}%
+\end{docCommand}
+
+
+\begin{docCommand}{DriverCounterInfoColor}{}
+This macro holds the text color for a driver counter, it defaults to \meta{\textcolor{\DriverCounterInfoColor}{\expandafter{\DriverCounterInfoColor}}}%
+\end{docCommand}
+
+\begin{docCommand}{AssociatedCounterInfoColor}{}
+This macro holds the text color for an associated counter, it defaults to \meta{\textcolor{\AssociatedCounterInfoColor}{\expandafter\AssociatedCounterInfoColor}}%
+\end{docCommand}
+
+\begin{dispExample}
+ \PrettyPrintCounterName[countertype=general]{equation}
+\end{dispExample}
+
+
+
+\section{Suspending and resuming associated counters}\label{section::suspendedresumedcounters}
+
+Rather than remove an associated counter from the list, it is possible to suspend the automatic stepping for a while and then resume it, for example, if the value of a counter should not be stepped within a specific chapter etc.
+
+\begin{docCommand}{SuspendCounters}{\oarg{options}\marg{counters list}}%
+\begin{docCommandArgs}{SuspendCounters}%
+
+\begin{enumerate}[label={\textcolor{blue}{\#\arabic*}}]
+\item \oarg{options}%
+
+ Not used so far, reserved for later usages
+
+\item \marg{counters list}%
+
+ Contains the name of counters to be suspended, separated by commas (CSV - list)
+\end{enumerate}
+
+\end{docCommandArgs}
+
+Some remarks:
+
+\begin{itemize}
+\item
+Please note, that it is possible, to suspend an arbitrary counter, if the package option \refKey{globalsuspend} is set to \meta{true}. Handle this option with care!
+\item If a driver counter is suspended, all counters associated to it are suspended too!
+\end{itemize}%
+
+\begin{dispExample}
+\textbf{This example shows 4 equations, but only two of them are counted}
+\newtotcounter{totalequations}
+\DeclareAssociatedCounters{equation}{totalequations}
+
+\begin{equation}
+E_{0} = mc^2
+\end{equation}
+
+Now suspend the totalequations:
+
+\SuspendCounters{totalequations}
+\begin{equation}
+E^2 = \left({ pc}\right)^2 + E^{2}_{0}
+\end{equation}
+
+\begin{equation}
+ m(v) = \frac{m_{0}}{\sqrt{1-\frac{v^2}{c^2}}}
+\end{equation}
+
+And resume it: \ResumeSuspendedCounters
+
+\begin{equation}
+ E = h \nu
+\end{equation}
+
+There are \number\totvalue{totalequations}~ equations in here!
+
+
+\end{dispExample}
+
+
+\end{docCommand}%
+
+\begin{docCommand}{ResumeSuspendedCounters}{}
+ This command has no arguments and revokes the suspension of \textbf{all} counters.
+\end{docCommand}
+
+
\section{Internals commands}
@@ -487,15 +706,28 @@ This macro generates a list from the driver counter name and the driver counter
\end{docCommand}
-
+\clearpage
\section{To do list}
\begin{itemize}
\item Check the existence of driver and associated counters
+\item Provide a better internal list organization
+\item Some macro names might be non-intuitive
\item Improve documentation
\end{itemize}
+If you
+
+\begin{itemize}
+ \item find bugs
+ \item errors in the documentation
+ \item have suggestions
+ \item have feature requests
+\end{itemize}
+
+don't hesitate and contact me via \makeatletter christian.hupfer@siebenfelsen.de\makeatother
+
\clearpage
\section{Acknowledgments}
@@ -536,8 +768,13 @@ This document has \number\totvalue{totalsections} section(s)%
In this example, the subsections of this document are counted but later on, the associatedcounter is removed from the list, so it is frozen.
+%\DeclareAssociatedCounters{subsection}{totalsubsections}%
+
+%\renewcommand{\DeclareAssociatedCounters}[3]{\relax}%
+
\begin{dispExample}
\newtotcounter{totalsubsections}%
+\newtotcounter{othertotalsubsections}%
\DeclareAssociatedCounters{subsection}{totalsubsections}%
\subsection{First dummy subsection}
@@ -545,13 +782,12 @@ SubSection counter: \thesubsection~-- \number\totvalue{totalsubsections}
\subsection{Second dummy subsection}
SubSection counter: \thesubsection~-- \number\totvalue{totalsubsections}
-\RemoveAssociatedCounter{subsection}{totalsubsections}
-
+\RemoveAssociatedCounter{subsection}{totalsubsections}%
\subsection{Third dummy subsection after removing the associated counter}
-SubSection counter: \thesubsection~-- \number\totvalue{totalsubsections}
-\end{dispExample}
+SubSection counter: \thesubsection~-- \number\totvalue{totalsubsections}
+\end{dispExample}
\section[Total number of proofs]{Example: Total number of proofs}
@@ -559,8 +795,9 @@ SubSection counter: \thesubsection~-- \number\totvalue{totalsubsections}
\begin{dispExample}
% \usepackage{amsthm} is needed
\newcounter{proof}%
+\newtotcounter{anotherproofcounter}%
\newtheorem{Proof}[proof]{Proof}%
-\DeclareAssociatedCounters{proof}{totalproofs}
+\DeclareAssociatedCounters{proof}{totalproofs,anotherproofcounter}
\begin{Proof}
It's trivial.
\end{Proof}
@@ -578,8 +815,37 @@ See excavations!
\end{align*}
\end{Proof}
-This document has \number\totvalue{totalproofs} proofs %
+This document has \number\value{anotherproofcounter} proofs %
+Now let us manipulate the counter proof again:
+\setcounter[AssociatedCounters={totalproofs}]{proof}{200}
+
+This document has \number\totvalue{totalproofs} (manipulated counter) proofs where as the unmanipulated counter still shows \number\value{anotherproofcounter} proofs %
+\end{dispExample}
+
+This example shows, that the usage of the options to \cs{setcounter} should be used with care!
+
+
+\subsection{Suspension of a non-associated counter}
+This example will show the suspension of a non-associated counter
+
+
+\begin{dispExample}
+\setcounter{equation}{0}%
+\SuspendCounters{equation}%
+\begin{equation}
+E_{0} = mc^2
+\end{equation}
+
+\begin{equation}
+E^2 = \left({ pc}\right)^2 + E^{2}_{0}
+\end{equation}
+
+\begin{equation}
+ m(v) = \frac{m_{0}}{\sqrt{1-\frac{v^2}{c^2}}}
+\end{equation}
+
+There are \number\value{equation}~equations in here!
\end{dispExample}