ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Giuseppe Bilotta <bourbaki@bigfoot.com>
Cc: ntg-context@ntg.nl
Subject: Re: Definitions
Date: Sun, 20 Jan 2002 18:56:24 +0100	[thread overview]
Message-ID: <1348356055.20020120185624@bigfoot.com> (raw)
In-Reply-To: <14910577386.20020117144544@bigfoot.com>

Thursday, January 17, 2002 Giuseppe Bilotta wrote:

GB> Hello,

GB> I have a bug report and an enhancement request for enumerations.

GB> First of all: the bug.

I found the bug. It comes from the definition in core-des:

\def\special@@definitiewoord#1#2#3#4[#5]#6#7%
  {\strut
   \doifelsevalue{\??dd#1\c!nummer}{\v!nee}
     {\!!doneafalse}
     {\doifelse{#5}{-}
        {\!!doneafalse}
        {\!!doneatrue}}%
   \chardef\definitiekoppeling=0
   \iflocation
     \doifvaluesomething{\??dd#1\c!koppeling}
       {\processaction % genereert > of <
          [\getvalue{\??dd#1\c!koppelwijze}]
          [ \v!lokaal=>\chardef\definitiekoppeling=1, % old: default
           \v!globaal=>\chardef\definitiekoppeling=2]}% new: global crosslinking
   \fi
   \stelnummerin % the number is called indirectly
     [\getvalue{\??dd#1\??dd\c!nummer}]
     [\c!sectienummer=\getvalue{\??dd#1\c!sectienummer}]%
   \if!!donea
     \getvalue{\e!volgende#2#1}%
     \iflocation
       \bgroup
       \setvalue{\??dd#1\c!sectienummer}{\v!ja}%
       \protectconversion
      %\maakvoorafgaandenummer[#1]%
       \maakvoorafgaandenummer[\getvalue{\??dd#1\??dd\c!nummer}]%
       \ifcase\definitiekoppeling \or
         \xdef\internaldoornummer{#3{#1}}%
         \rawreference{\s!num}{#1:\internaldoornummer}{}%
       \or
         \xdef\internaldoornummer{\countervalue{\??dd\c!koppeling#1}}%
         \rawreference{\s!num}{#1:\internaldoornummer}{}%
       \fi
       \egroup
     \fi
    %\maakvoorafgaandenummer[#1]%
     \maakvoorafgaandenummer[\getvalue{\??dd#1\??dd\c!nummer}]%
     \hbox
       {\let\normalkap\relax % sorry, uppercase causes troubles
        \doattributes        % \nocase primitive needed
          {\??dd#1}\c!kopletter\c!kopkleur
          {\getvalue{\??dd#1\c!commando}% hook for taco 
             {\showdntext{#2#1}%
              \domakednnummer{#1}{#2}{#3}}}%
        \iflocation\ifcase\definitiekoppeling \else
          \edef\localconnection{\getvalue{\??dd#1\c!koppeling}:\internaldoornummer}%
          \doifreferencefoundelse{\localconnection}
            {\in[\localconnection]}{}% genereert > of <
         %\in[\localconnection]%
        \fi\fi}%
     \doifnot{#5}{-}{\rawreference{\s!num}{#5}{#3{#1}}}%
% Here is the bug -----------------------------^^^^^^
% When this gets called with \showdnnummer as #3, there
% is an expansion problem, since \showdnnummer is *not*
% properly expandable: it uses the command sequence
% \preparednumber which is defined by \showdnnummer itself
% If I change the line with something like
     \preparethenumber{\??dd#1}\voorafgaandenummer\preparednumber
     \edef\thenumbertouse{%
       \preparednumber
       \nummer[\getvalue{\??dd#1\??dd\c!nummer}]}%
     \doifnot{#5}{-}{\rawreference{\s!num}{#5}{\thenumbertouse}}%
% everything goes on smoothly.
% Maybe we need and expandable version of showdnnummer?
   \else % Why was this strange expansion needed? 
     \hbox
       {\edef\!!stringa{\showdnpuretext{#2#1}}% nog eens testen binnen \expanded
        \expanded{\doattributes{\??dd#1}\noexpand\c!kopletter\noexpand\c!kopkleur
          {\noexpand\getvalue{\??dd#1\c!commando}%
             {\!!stringa}}}%
        \doifnot{#5}{-}{\rawreference{\s!num}{#5}{}}}%
   \fi}

--
Giuseppe "Oblomov" Bilotta


  reply	other threads:[~2002-01-20 17:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-17 13:45 Definitions Giuseppe Bilotta
2002-01-20 17:56 ` Giuseppe Bilotta [this message]
2002-01-20 23:28   ` Definitions Hans Hagen
2002-01-21 15:31     ` Re[2]: Definitions Giuseppe Bilotta
  -- strict thread matches above, loose matches on Subject: below --
1999-04-10  9:46 Definitions Hans Hagen
1999-04-11 21:41 ` Definitions Tobias Burnus
1999-04-12 10:36   ` Definitions Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1348356055.20020120185624@bigfoot.com \
    --to=bourbaki@bigfoot.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).