[NTG-context] label in enumerations broken?

2012-02-19 Thread Andreas Mang
Dear all,

As I have learned from the mailing list, there have been some changes in the 
enumeration / description environment. Did I miss something (i.e. has there 
also been a change in how to define the labels for the description / 
enumeration?) I have attached my prefs, a minimal example and an error message.

Your help is very much appreciated.

Thanks in advance,
Andreas

%
% PREFS 
%
% ConTeXt  ver: 2012.02.18 10:50 MKIV  fmt: 2012.2.18  int: english/english
% LuaTeX, Version beta-0.70.1-2011051908 (rev 4277)

%
% MINIMAL EXAMPLE 
%
\setupenumerations%
[%
alternative=hanging,%
width=broad,%
headstyle=bold,%
titlestyle=bold,% 
]%

\defineenumeration[mydefinition]%
[text=Definition,%
style=italic,%
title=yes,%
listtext={Definition }%
]%


\starttext

% \startmydefinition WITHOUT [ref2mydef] and/or the title {The Definition}  
works fine
% note: I have added alternative instead of location as suggested in the 
mailing list
% note: I have switched the title on and off and accordingly have also removed 
The Definition

\startmydefinition[ref2mydef]{The Definition}

Let something be defined.

\stopmydefinition

\stoptext



%
% ERROR MESSAGE
%
\strc_descriptions_start_yes_reference ...e_state 
  \expandafter \strc_descrip...
\strc_descriptions_start_yes ...art_yes_reference 
  [#1]
l.21 \startmydefinition[ref2mydef]
  {The Definition}
? 
! Emergency stop.

system   tex  error on line 21 in file 
/Users/Chip/Desktop/dump/context-minimal/minimal.tex: Emergency stop


___
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
___


Re: [NTG-context] label in enumerations broken?

2012-02-19 Thread Wolfgang Schuster

Am 19.02.2012 um 14:47 schrieb Andreas Mang:

 Dear all,
 
 As I have learned from the mailing list, there have been some changes in the 
 enumeration / description environment. Did I miss something (i.e. has there 
 also been a change in how to define the labels for the description / 
 enumeration?) I have attached my prefs, a minimal example and an error 
 message.
 
 Your help is very much appreciated.
 
 Thanks in advance,
 Andreas
 
 %
 % PREFS 
 %
 % ConTeXt  ver: 2012.02.18 10:50 MKIV  fmt: 2012.2.18  int: english/english
 % LuaTeX, Version beta-0.70.1-2011051908 (rev 4277)
 
 %
 % MINIMAL EXAMPLE 
 %
 \setupenumerations%
 [%
 alternative=hanging,%
 width=broad,%
 headstyle=bold,%
 titlestyle=bold,% 
 ]%
 
 \defineenumeration[mydefinition]%
 [text=Definition,%
 style=italic,%
 title=yes,%
 listtext={Definition }%
 ]%

There is no need for all these comments.

 \starttext
 
 % \startmydefinition WITHOUT [ref2mydef] and/or the title {The 
 Definition}  works fine
 % note: I have added alternative instead of location as suggested in the 
 mailing list
 % note: I have switched the title on and off and accordingly have also 
 removed The Definition
 
 \startmydefinition[ref2mydef]{The Definition}

You can now write this as “\startmydefinition[reference=ref2mydef,title=The 
Definition]”

 Let something be defined.
 
 \stopmydefinition
 
 \stoptext

strc-enu.mkvi (move \donothing before 
\strc_enumerations_inject_extra_text_indeed):

\unexpanded\def\strc_enumerations_inject_extra_text
  {\ifconditional\c_strc_constructions_title_state
 
\ctxcommand{doiflisthastitleelse(\currentconstructionmain,\currentconstructionlistentry)}
+ \donothing
   \strc_enumerations_inject_extra_text_indeed
- \donothing
   \fi}

strc-des.mkvi:

\unexpanded\def\strc_descriptions_start_yes_reference
+ {\ifconditional\c_strc_constructions_title_state
- {\ifconditional\c_strc_descriptions_title_state
 \expandafter\strc_descriptions_start_yes_titled
   \else
 \expandafter\strc_descriptions_start_yes_normal
   \fi}

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
___