ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Jan Tosovsky" <j.tosovsky@email.cz>
To: "'mailing list for ConTeXt users'" <ntg-context@ntg.nl>
Subject: Re: LMTX deeptextcommand issue
Date: Wed, 3 Apr 2019 00:35:13 +0200	[thread overview]
Message-ID: <005f01d4e9a4$575084b0$05f18e10$@email.cz> (raw)
In-Reply-To: <345b4db2-c902-9ba0-30c6-b2fcf8ab9c3d@xs4all.nl>

On 2019-04-02 Hans Hagen wrote:
> On 4/2/2019 8:41 PM, Jan Tosovsky wrote:
> >
> > my document ends with the index
> >
> > \startbackmatter
> > \chapter{Rejstřík jmenný}
> > \start
> > \switchtobodyfont[8pt]
> > \placeindexname
> > \stop
> > \stopbackmatter
> > \startbackmatter
> > \chapter{Rejstřík věcný}
> > \start
> > \switchtobodyfont[8pt]
> > \placeindexsubject
> > \stop
> > \stopbackmatter
> >
> > At the beginning there is a condition for one word (kind of manual column
> > balancing) - but according to the log, see below, this seems to be an issue:
> > \newconditional\IndexState
> > \define[1]\IndexInternalCommand
> >
> >
> {\doifelse{#1}{Dolsko}{\global\settrue\IndexState}{\global\setfalse\IndexSt
> a
> > te}#1}
> >
> > \define[1]\IndexCommand
> >    {\setfalse\IndexState
> >     \setbox\scratchbox\hbox{#1}%
> >     \ifconditional\IndexState
> >       \column
> >     \fi
> >     \box\nextbox}
> 
> does
> 
> \unexpanded\def\IndexCommand#1%
>    {....
> 
> work?

I've modified that block this way:

\newconditional\IndexState
%\define[1]\IndexInternalCommand
\unexpanded\def\IndexInternalCommand#1%
  {\doifelse{#1}{Dolsko}{\global\settrue\IndexState}{\global\setfalse\IndexState}#1}

%\define[1]\IndexCommand
\unexpanded\def\IndexCommand#1%
  {\setfalse\IndexState
   \setbox\scratchbox\hbox{#1}%
   \ifconditional\IndexState
     \column
   \fi
   \box\nextbox}


Is it what you propose? If so, I am still getting the same error.

Jan

___________________________________________________________________________________
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

  reply	other threads:[~2019-04-02 22:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-02 18:41 Jan Tosovsky
2019-04-02 21:13 ` Hans Hagen
2019-04-02 22:35   ` Jan Tosovsky [this message]
2019-04-02 22:42     ` 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='005f01d4e9a4$575084b0$05f18e10$@email.cz' \
    --to=j.tosovsky@email.cz \
    --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).