Am 05.04.10 14:04, schrieb Vianney le Clément:
Hello again,

Section 10.3 of the manual says that one can disable numbering for one
item of an enumeration by putting [-]. However, this seems to affect
the following item instead of the current one. For example,

\defineenumeration[MyEnum][location=left]
\starttext
\MyEnum First\par
\MyEnum[-] Second\par
\MyEnum Third\par
\MyEnum Fourth\par
\stoptext

removes the number of the third line, instead of the second one.
A perfect example.

\unprotect

%\def\@@makedescription[#1]#2%
%  {\postponenotes % new, assumes grouping
%   \doenumerationcheckconditions
% \dodescriptioncomponent[\c!reference=#1,\c!label={\descriptionparameter\c!text},\c!title={#2},\c!bookmark=,\c!list=][]%
%   \@@dostartdescriptionindeed}

\def\@@makedescription[#1]#2%
  {\postponenotes % new, assumes grouping
   \doenumerationcheckconditions{#1}%
\dodescriptioncomponent[\c!reference=#1,\c!label={\descriptionparameter\c!text},\c!title={#2},\c!bookmark=,\c!list=][]%
   \@@dostartdescriptionindeed}

%\def\doenumerationcheckconditions
%  {\doifelse{\descriptionparameter\c!number}\v!yes
%     {\ifx\currentdescriptionreference\enumerationdisablenumbersignal
% \setfalse\enumerationnumberenabled \else \settrue\enumerationnumberenabled
%      \fi}%
%     {\setfalse\enumerationnumberenabled}%
%   \edef\currentenumerationcoupling{\descriptionparameter\c!coupling}}

\def\doenumerationcheckconditions#1%
  {\doifelse{\descriptionparameter\c!number}\v!yes
{\doifelse{#1}\enumerationdisablenumbersignal\setfalse\settrue\enumerationnumberenabled}
     {\setfalse\enumerationnumberenabled}%
   \edef\currentenumerationcoupling{\descriptionparameter\c!coupling}}

\protect

\defineenumeration[MyEnum][location=left]
\starttext
\MyEnum First\par
\MyEnum[-] Second\par
\MyEnum Third\par
\MyEnum Fourth\par
\stoptext

Wolfgang

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to