On 20 mrt. 2013, at 16:45, Wolfgang Schuster <schuster.wolfg...@gmail.com>
 wrote:

> 
> Am 20.03.2013 um 16:40 schrieb H. van der Meer <h.vanderm...@uva.nl>:
> 
>> Trying to do some date and time processing myself, I ran into problems 
>> caused by ConTeXt makeing it incompatibel with the original plain TeX itself!
>> 
>> In the TeX-book, Appendix B one finds
>> <citation>
>> (Some parameters are set by TeX itself as it runs, so it is inappropriate to 
>> initialize them: \time, \day, \month, and year are established at the 
>> beginning of a job; ..
>> </citation>
>> 
>> Now the results in ConTeXT with a minimal example, put into the log for 
>> easier copying into the mail:
>> \starttext
>> \writestatus{}{\meaning\date -> \date}
>> \writestatus{}{\meaning\day -> \the\day}
>> \writestatus{}{\meaning\month -> \month WHY NOT monthname?}
>> \writestatus{}{\meaning\year -> \the\year}
>> \writestatus{}{\meaning\time -> \the\time}
>> \stoptext
>> 
>> Result:
>> > \protected macro:->\dodoubleempty \syst_converters_date -> \date 
>> > \day-> 20
>> > macro:#1->\ctxcommand {monthname(#1)}-> \labeltext {unknown}HY NOT 
>> > monthname?
>> > \year-> 2013
>> > \time-> 989
>> 
>> Plain TeX here gives:
>> \message{\meaning\day -> \the\day}
>> \message{\meaning\month -> \the\month}
>> \message{\meaning\year -> \the\year}
>> \message{\meaning\time -> \the\time}
>> \end
>> 
>> Result:
>> (./plaindates.tex \day-> 20 \month-> 3 \year-> 2013 \time-> 991 )
>> 
>> I strongly ask that ConTeXt abstains from changing the definition of \month 
>> and reverts to the exact result as given by plain TeX, i.e. a number in the 
>> range [1-12]. Because the change in ConTeXt makes it impossible to do 
>> calculations on the month.
>> 
>> Furthermore I encountered problems with defining expanded macros for 
>> currentdate and currenttime. This seems impossible to accomplish, at least 
>> in a simple manner. See the results from these to examples:
>> \edef\thedate{\currentdate}\writestatus{}{\meaning\thedate -> \thedate}
>> \edef\thetime{\currenttime}\writestatus{}{\meaning\thetime -> \thetime}
>> giving:
>> > macro:->\currentdate -> \currentdate 
>> > macro:->\currenttime -> \currenttime 
>> 
>> This is most unhappy, because one really should be able to put the 
>> expansions of these macros somewhere.
>> I hope the next beta will have solutions for these problems.
> 
> TeX primitives are available under \normal…
> 
> Wolfgang
> 

That is most unfortunate. Why not keep compatibility with plain TeX where 
possible? I see that \time, \day and \year have been left untouched. So why 
messing up \month? Sorry for the expression, no offense meant, but in my eyes 
this is unnecessary tinkering with established macros.
What speaks against keeping \month as is? And doing the translation through 
\monthname? It looks to me even more transparent and it could use the \language 
for translation.
No, this shouldn't have happened and I strongly urge that the original meaning 
returns to ConTeXt.


___________________________________________________________________________________
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