Hans, thanks for your swift reply…


> On 24. May 2017, at 19:31, Hans Hagen <pra...@wxs.nl> wrote:
> 
> On 5/24/2017 6:28 PM, Thomas Floeren wrote:
>> Hi,
>> I used to use the “command=” parameter when setting up itemize. Now I 
>> noticed that it introduces a spurious horizontal whitespace after the item 
>> symbol when the item is of type “\sym{}”.
>> I also noticed that the problem goes away if I use “inner=” instead of 
>> “command=”.
> 
> command is applied to the text, try command=\WORD and after \sym is a space 
> so it depends on what command does with it


I see, \WORD does not introduce the whitespace. But I don’t understand why 
\setupwhitespace[none] should do anything with the space after \sym, what \WORD 
doesn’t do.


> 
>> Example:
>> \setuppapersize [A6]
>> \starttext
>> \start
>> \setupitemize [each][command={\setupwhitespace[none]}]
>> With \type{\command=}
>> \startitemize
>> \item \dorecurse{20}{bla }
>> \sym{Y} \dorecurse{20}{bla }
>> \stopitemize
>> \stop
>> \setupitemize [each][inner={\setupwhitespace[none]}]
>> With \type{\inner=}
>> \startitemize
>> \item \dorecurse{20}{bla }
>> \sym{Y} \dorecurse{20}{bla }
>> \stopitemize
>> \stoptext
>> This is with ConTeXt 2017.05.15 21:48. With an older ConTeXt, for example 
>> 2015.01.13 15:54, “inner=” and “command=” deliver identical, correct results.
>> So, I’m asking, has “command=” been deprecated or is it just a bug?
>> Or was I using it the wrong way, and “inner=” is the only correct parameter 
>> in the example above?
> \setupitemize [each][nowhite]


Tried that, but it does not the same as \setupwhitespace[none]. (It completely 
annihilates any whitespace.)

Compile this to see what I mean:



\definepapersize[Tmp][width=120mm,height=400mm]
\setuppapersize [Tmp]
\setupwhitespace[2\lineheight]

\startbuffer
bla, bla\crlf bla, bla 
\stopbuffer

\starttext

Normal text:

\getbuffer\par
\getbuffer

Itemize, unmodified:
\startitemize 
\item \getbuffer 
\sym{Y} \getbuffer 
\stopitemize

\start
\setupitemize [each][command={\setupwhitespace[none]}]
Itemize with \type{command={\setupwhitespace[none]}}:
\startitemize 
\item \getbuffer 
\sym{Y} \getbuffer 
\stopitemize
\stop

\start
\setupitemize [each][inner={\setupwhitespace[none]}]
Itemize with \type{inner={\setupwhitespace[none]}}:
\startitemize 
\item \getbuffer 
\sym{Y} \getbuffer 
\stopitemize
\stop

\start
\setupitemize [each][nowhite]
Itemize with \type{nowhite}:
\startitemize 
\item \getbuffer 
\sym{Y} \getbuffer 
\stopitemize
\stop

\stoptext


So it seems the only ways to get the desired result are either 
inner={\setupwhitespace[none]} or command={\setupwhitespace[none]}, where the 
first one seems to work correctly and the latter one introduces the whitespace 
with recent Betas. (well, recent = younger than 2 years or so)

Should I change all my existing documents to “inner”?


Thanks,
best,

– Tom

-- 
For macOS:      
http://dflect.net/context-typeset-tool/
___________________________________________________________________________________
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 via email to