Re: [NTG-context] zint barcode module on LMTX/MacOS

2021-09-07 Thread Henning Hraban Ramm via ntg-context
Since I got zint running (thanks, Hans!), there’s now a wiki page:

https://wiki.contextgarden.net/Barcodes

Have fun!
Hraban
___
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
___


Re: [NTG-context] transparency stopped working in LMTX

2021-09-07 Thread Hans Hagen via ntg-context

On 9/7/2021 11:02 AM, Henning Hraban Ramm via ntg-context wrote:

(Latest LMTX, yesterday’s luametatex binary)

The MWE shows no transparency with LMTX, it works with MkIV:

'''
\setupexternalfigures[location=default]
\definetransparency[light][a=1,t=.05]

\definelayer[bg][x=0mm,y=0mm]
\setupbackgrounds[text][background={bg},state=start]

\starttext

\starttransparent[light]%
\externalfigure[hacker]%
\stoptransparent

\setlayer[bg][
   hoffset=5mm,
   voffset=5mm,
]{
\starttransparent[light]%
\externalfigure[hacker]%
\stoptransparent
}

\stoptext
'''

The layer stuff is not "minimal", but I wanted to check if "multiply" works.

should work in next upload (not today)

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] error: (nodes): fuzzy token cleanup in whatsit node

2021-09-07 Thread Hans Hagen via ntg-context

On 9/7/2021 10:38 AM, Sylvain Hubert via ntg-context wrote:

Dear List,

I think I've just encountered a fragile bug. It is only reproducible
with exactly the same layout as the doc below. Any insertion or
removal of an item that changes the pagination would let the document
compile.
nasty border case (fixed but i'll redo that code some day anyway in a 
more lmtx way)


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] Equation alignment

2021-09-07 Thread Jeong Dal via ntg-context
Dear Sylvain,

I am using ’\startalign’

> 
> \starttext
> \startformula
> \eqalign{
> ax^2+bx+c &= 0 \cr
> x &= \frac{-b \pm \sqrt{b^2-4ac}}{2a} \cr
> }
> \stopformula
> \stoptext
> 

\starttext
\startformula
\startalign
\NC ax^2 + bx + c \NC = 0 \NR
\NC x \NC = = \frac{-b \pm \sqrt{b^2-4ac}}{2a} \NR
\stopalign
\stopformula
\stoptext

There is  a nice guide book "My Way” for math-alignment by Aditya.
https://wiki.contextgarden.net/images/archive/b/b4/20100530075041!Mathalign.pdf 


Best regards,

Dalyoung

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


Re: [NTG-context] no looseness in LMTX?

2021-09-07 Thread Hans Hagen via ntg-context

On 9/7/2021 3:13 PM, Henning Hraban Ramm via ntg-context wrote:


But \updateparagraphproperties (see Hans’ message) helps, it’s just 
inconvenient.
depends ... if you're in some group before a \par is given you won't get 
looseness which is way harder to track down, and carrying that on eover 
an egroup is not something you want to do (let alone carrying over 20 
groups)


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] no looseness in LMTX?

2021-09-07 Thread Henning Hraban Ramm via ntg-context


> Am 07.09.2021 um 13:15 schrieb Wolfgang Schuster 
> :
> 
> Henning Hraban Ramm via ntg-context schrieb am 07.09.2021 um 11:49:
>> In my magazine and book projects, I sometimes fix pagebreaking by stretching 
>> paragraphs with \looseness=1
>> 
>> Unfortunately this works _in my project_ only with MkIV, i.e. \looseness has 
>> no effect with LMTX.
>> 
>> I tried different examples (e.g. the attached file) and can’t reproduce the 
>> problem, there MkIV and LMTX always behave the same.
>> So it must be something in my settings.
>> 
>> What could cause the difference?
>> I tried English and German and different settings of alignment and tolerance.
>> Might it be font dependent?
> 
> Do you enable protrusion and font expansion for your document font or is it 
> just missing in your example?

You’re right, this was missing in the example:

\definefontfeature[default]
[mode=node,liga=no,kern=yes,tlig=no,
  ccmp=yes,language=dflt,
  protrusion=quality,
  expansion=quality]

But that also doesn’t change that the example works the same with MkIV and 
LMTX, but not my project.

> Have you checked if the alignment changes when you use the "extremestretch" 
> keyword for \setupalign?

I see no difference, and again it works in both versions the same.
It also doesn’t change that \looseness isn’t working in my project.


But \updateparagraphproperties (see Hans’ message) helps, it’s just 
inconvenient.

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


Re: [NTG-context] no looseness in LMTX?

2021-09-07 Thread Henning Hraban Ramm via ntg-context

> Am 07.09.2021 um 14:07 schrieb Hans Hagen :
> 
> On 9/7/2021 11:49 AM, Henning Hraban Ramm via ntg-context wrote:
>> In my magazine and book projects, I sometimes fix pagebreaking by stretching 
>> paragraphs with \looseness=1
>> Unfortunately this works _in my project_ only with MkIV, i.e. \looseness has 
>> no effect with LMTX.
>> I tried different examples (e.g. the attached file) and can’t reproduce the 
>> problem, there MkIV and LMTX always behave the same.
>> So it must be something in my settings.
>> What could cause the difference?
>> I tried English and German and different settings of alignment and tolerance.
>> Might it be font dependent?
> 
> explained in manuals ...
> 
> \startlinenumbering
> \startparagraph
> Weit .. beirren.
> \stopparagraph
> \stoplinenumbering
> 
> \startlinenumbering
> \startparagraph\looseness=+2
> Weit .. beirren.
> \stopparagraph
> \stoplinenumbering
> 
> \startlinenumbering
> \startparagraph
> Weit .. beirren.
> \looseness=+2\updateparagraphproperties\stopparagraph
> \stoplinenumbering
> 
> in lmxt we freeze the properties set when a paragraph starts (contrary to 
> using the last set value which actually fails when you set it inside a group)
> 
> so, when you change some property mid paragraph you need to update the 
> properties in order for them to be effective (can be done for looseness only 
> if really needed); that works independent of grouping so it's more robust

Ok, but I thought I needed to use \looseness directly at the beginning of the 
paragraph, since it’s forgotten after the next \par?

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


Re: [NTG-context] Equation alignment

2021-09-07 Thread Wolfgang Schuster via ntg-context

Sylvain Hubert via ntg-context schrieb am 07.09.2021 um 14:29:

Dear List,

The following example of equation alignment copied from An Excursion
is not reproducible under my context 2021.03.05 shipped with texlive
2021:

\starttext
\startformula
\eqalign{
ax^2+bx+c &= 0 \cr
x &= \frac{-b \pm \sqrt{b^2-4ac}}{2a} \cr
}
\stopformula
\stoptext

Both ampersands are rendered literally.

Does anyone know how to properly typeset aligned equations?


\starttext

\startformula
\startmathalignment%[align={right,left}]
\NC ax^2+bx+c \NC = 0    \NR
\NC x \NC = \frac{-b \pm \sqrt{b^2-4ac}}{2a} \NR
\stopmathalignment
\stopformula

\stoptext

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


[NTG-context] Equation alignment

2021-09-07 Thread Sylvain Hubert via ntg-context
Dear List,

The following example of equation alignment copied from An Excursion
is not reproducible under my context 2021.03.05 shipped with texlive
2021:

\starttext
\startformula
\eqalign{
ax^2+bx+c &= 0 \cr
x &= \frac{-b \pm \sqrt{b^2-4ac}}{2a} \cr
}
\stopformula
\stoptext

Both ampersands are rendered literally.

Does anyone know how to properly typeset aligned equations?

Thanks!

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


Re: [NTG-context] no looseness in LMTX?

2021-09-07 Thread Hans Hagen via ntg-context

On 9/7/2021 11:49 AM, Henning Hraban Ramm via ntg-context wrote:

In my magazine and book projects, I sometimes fix pagebreaking by stretching 
paragraphs with \looseness=1

Unfortunately this works _in my project_ only with MkIV, i.e. \looseness has no 
effect with LMTX.

I tried different examples (e.g. the attached file) and can’t reproduce the 
problem, there MkIV and LMTX always behave the same.
So it must be something in my settings.

What could cause the difference?
I tried English and German and different settings of alignment and tolerance.
Might it be font dependent?


explained in manuals ...

\startlinenumbering
\startparagraph
Weit .. beirren.
\stopparagraph
\stoplinenumbering

\startlinenumbering
\startparagraph\looseness=+2
Weit .. beirren.
\stopparagraph
\stoplinenumbering

\startlinenumbering
\startparagraph
Weit .. beirren.
\looseness=+2\updateparagraphproperties\stopparagraph
\stoplinenumbering

in lmxt we freeze the properties set when a paragraph starts (contrary 
to using the last set value which actually fails when you set it inside 
a group)


so, when you change some property mid paragraph you need to update the 
properties in order for them to be effective (can be done for looseness 
only if really needed); that works independent of grouping so it's more 
robust


so .. it's all about more control

Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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
___


Re: [NTG-context] features of fallback font

2021-09-07 Thread Wolfgang Schuster via ntg-context

Sylvain Hubert via ntg-context schrieb am 07.09.2021 um 13:32:

Dear List,

I'm using the chinese simsun font that has no builtin SerifBold.

I'm trying to define a fakebold feature for it, but the following code
does not work:

\definefontfeature[fakebold][effect={width=0.3, delta=0}]

\definefontfallback [sunfallback] [name:simsun] [cjkunifiedideographs]
\definefontfallback [sunbffallback] [name:simsun]
[cjkunifiedideographs][features=fakebold]

\definefontsynonym [Serif] [modern] [fallbacks=sunfallback]
\definefontsynonym [SerifBold] [modern] [fallbacks=sunbffallback]

\starttext
人 foo \bf 人 bar  % bar is bold, the second 人 is not
\stoptext

Does anyone know how to define features for fallback font?


\definefallbackfamily [sylvain] [serif] [SimSun]
  [range=cjkunifiedideographs,
   bf={style:regular,features:boldened}]

\definefontfamily [sylvain] [serif] [Latin Modern Roman]

\definefontfamily [sylvain] [math] [Latin Modern Math]

\setupbodyfont [sylvain]

\starttext
人 foo {\bf 人 bar} 人 foo
\stoptext

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


Re: [NTG-context] Remove vertical space around typing

2021-09-07 Thread Wolfgang Schuster via ntg-context

Sylvain Hubert schrieb am 07.09.2021 um 13:38:

Thanks Wolfgang, this solves my problem.

But now I'm wondering why \starttyping[before=,after=] cannot do the same job?


Works here.

\starttext
Remove space below
\starttyping[before=,after=]
some
code
\stoptyping
\stoptext

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


[NTG-context] features of fallback font

2021-09-07 Thread Sylvain Hubert via ntg-context
Dear List,

I'm using the chinese simsun font that has no builtin SerifBold.

I'm trying to define a fakebold feature for it, but the following code
does not work:

\definefontfeature[fakebold][effect={width=0.3, delta=0}]

\definefontfallback [sunfallback] [name:simsun] [cjkunifiedideographs]
\definefontfallback [sunbffallback] [name:simsun]
[cjkunifiedideographs][features=fakebold]

\definefontsynonym [Serif] [modern] [fallbacks=sunfallback]
\definefontsynonym [SerifBold] [modern] [fallbacks=sunbffallback]

\starttext
人 foo \bf 人 bar  % bar is bold, the second 人 is not
\stoptext

Does anyone know how to define features for fallback font?

Thanks!

Best,
Sylvain
___
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
___


Re: [NTG-context] Remove vertical space around typing

2021-09-07 Thread Wolfgang Schuster via ntg-context

Sylvain Hubert via ntg-context schrieb am 07.09.2021 um 11:49:

Dear List,

How should we remove the vertical space above and below the following typing?

\starttext
Remove space below
\starttyping
some
code
\stoptyping
\stoptext


\setuptyping [before=,after=]

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


Re: [NTG-context] no looseness in LMTX?

2021-09-07 Thread Wolfgang Schuster via ntg-context

Henning Hraban Ramm via ntg-context schrieb am 07.09.2021 um 11:49:

In my magazine and book projects, I sometimes fix pagebreaking by stretching 
paragraphs with \looseness=1

Unfortunately this works _in my project_ only with MkIV, i.e. \looseness has no 
effect with LMTX.

I tried different examples (e.g. the attached file) and can’t reproduce the 
problem, there MkIV and LMTX always behave the same.
So it must be something in my settings.

What could cause the difference?
I tried English and German and different settings of alignment and tolerance.
Might it be font dependent?


Do you enable protrusion and font expansion for your document font or is 
it just missing in your example?


Have you checked if the alignment changes when you use the 
"extremestretch" keyword for \setupalign?


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


[NTG-context] no looseness in LMTX?

2021-09-07 Thread Henning Hraban Ramm via ntg-context
In my magazine and book projects, I sometimes fix pagebreaking by stretching 
paragraphs with \looseness=1

Unfortunately this works _in my project_ only with MkIV, i.e. \looseness has no 
effect with LMTX.

I tried different examples (e.g. the attached file) and can’t reproduce the 
problem, there MkIV and LMTX always behave the same.
So it must be something in my settings.

What could cause the difference? 
I tried English and German and different settings of alignment and tolerance.
Might it be font dependent?


Hraban



loosetest.tex
Description: Binary data
___
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
___


[NTG-context] Remove vertical space around typing

2021-09-07 Thread Sylvain Hubert via ntg-context
Dear List,

How should we remove the vertical space above and below the following typing?

\starttext
Remove space below
\starttyping
some
code
\stoptyping
\stoptext

Thanks!

Best,
Sylvain
___
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
___


Re: [NTG-context] margin of inner item group

2021-09-07 Thread Sylvain Hubert via ntg-context
Thanks but I believe 'distance' means ' * <--> text',
while margin means '<--> * text'.

On 07/09/2021, fv leung via ntg-context  wrote:
> Use
>
> distance=...
>
> instead of
>
> margin=...
>
> .
>
> 在 2021年9月7日週二 16:58,Sylvain Hubert via ntg-context  寫道:
>
>> Dear List,
>>
>> Does anyone know how to set the margin of an inner item group? The
>> natural way does not seem to work:
>>
>> \showframe
>> \starttext
>> \startitemize[margin=5em]
>> \item 1
>> \startitemize[margin=10em]
>> \item 1
>> \item 2
>> \item 3
>> \stopitemize
>> \item 2
>> \item 3
>> \stopitemize
>> \stoptext
>>
>> In the doc above, only the outer item group has a margin.
>>
>> Any help will be appreciated.
>>
>> Best,
>> Sylvain
>>
>> ___
>> 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
>>
>> ___
>>
>
___
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
___


Re: [NTG-context] margin of inner item group

2021-09-07 Thread fv leung via ntg-context
Use

distance=...

instead of

margin=...

.

在 2021年9月7日週二 16:58,Sylvain Hubert via ntg-context  寫道:

> Dear List,
>
> Does anyone know how to set the margin of an inner item group? The
> natural way does not seem to work:
>
> \showframe
> \starttext
> \startitemize[margin=5em]
> \item 1
> \startitemize[margin=10em]
> \item 1
> \item 2
> \item 3
> \stopitemize
> \item 2
> \item 3
> \stopitemize
> \stoptext
>
> In the doc above, only the outer item group has a margin.
>
> Any help will be appreciated.
>
> Best,
> Sylvain
>
> ___
> 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
>
> ___
>
___
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
___


[NTG-context] transparency stopped working in LMTX

2021-09-07 Thread Henning Hraban Ramm via ntg-context
(Latest LMTX, yesterday’s luametatex binary)

The MWE shows no transparency with LMTX, it works with MkIV:

'''
\setupexternalfigures[location=default]
\definetransparency[light][a=1,t=.05]

\definelayer[bg][x=0mm,y=0mm]
\setupbackgrounds[text][background={bg},state=start]

\starttext

\starttransparent[light]%
\externalfigure[hacker]%
\stoptransparent

\setlayer[bg][
  hoffset=5mm,
  voffset=5mm,
]{
\starttransparent[light]%
\externalfigure[hacker]%
\stoptransparent
}

\stoptext
'''

The layer stuff is not "minimal", but I wanted to check if "multiply" works.


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


Re: [NTG-context] itemize problems

2021-09-07 Thread Sylvain Hubert via ntg-context
This works, thanks!

On 07/09/2021, fv leung via ntg-context  wrote:
> Use
>
>  \startitemize[A,text][lefttext=,righttext=,stopper=]
>
> then.
>
> Maybe that's the new way.
>
> Sylvain Hubert via ntg-context  於 2021年9月7日 週二
> 下午4:32寫道:
>
>> Thanks, but this doesn't seem to work on my laptop:
>>
>> \starttext
>> \startitemize[A,text][left=,right=,stopper=]
>> \item 1
>> \item 2
>> \stopitemize
>> \stoptext
>>
>> %output: (A) 1 (B) 2
>>
>> On 07/09/2021, fv leung via ntg-context  wrote:
>> > I add
>> >
>> > left=,right=,
>> >
>> > in the second option group.
>> >
>> > 在 2021年9月7日週二 07:02,Sylvain Hubert via ntg-context 
>> 寫道:
>> >
>> >> A few more information:
>> >>
>> >> For the 1st problem:
>> >>
>> >> It seems that \setupitemize accepts two option groups, to which
>> >> n,packed and margin belong accordingly. However,
>> >> \setupitemize[n][margin=2em] does not seem to work.
>> >>
>> >> For the 2nd problem:
>> >>
>> >> \setupitemize[columns,one], although doing nothing in theory, seems to
>> >> fix the problem.
>> >>
>> >> For the 4th problem:
>> >>
>> >> I've found that we can do \setupitemize[A,text] which makes it like
>> >>
>> >> (A.) 0 (B.) 1 (C.) 2 (D.) 3
>> >>
>> >> The problem now is, how can we remove the parentheses around the item
>> >> labels?
>> >>
>> >> On 07/09/2021, Sylvain Hubert  wrote:
>> >> > Dear List,
>> >> >
>> >> > Here's a collection of four problems about item groups that I've
>> >> > just
>> >> > encountered.
>> >> >
>> >> > 1. 'n' and 'packed' not playing well with other options.
>> >> >
>> >> > This works:
>> >> >
>> >> > \defineitemgroup[myitems][itemize][margin=2em,before=before]
>> >> > \setupmyitems[n,packed]
>> >> >
>> >> > \starttext
>> >> > text
>> >> > \startmyitems
>> >> > \item 1
>> >> > \item 2
>> >> > \stopmyitems
>> >> > \stoptext
>> >> >
>> >> > This does not:
>> >> >
>> >> >
>> >> > \defineitemgroup[myitems][itemize][margin=2em,before=before,n,packed]
>> >> >
>> >> > This does not either:
>> >> >
>> >> > \defineitemgroup[myitems][itemize]
>> >> > \setupmyitems[n,packed,margin=2em,before=before]
>> >> >
>> >> > Is there a rule for this glitch which makes it worth memorizing, or
>> >> > is
>> >> > this just a bug?
>> >> >
>> >> > 2. 'before' not working in nested item groups.
>> >> >
>> >> > \starttext
>> >> > \startitemize[before=before1]
>> >> > \item 1
>> >> > \startitemize[before=before2]
>> >> > \item 2
>> >> > \stopitemize
>> >> > \stopitemize
>> >> > \stoptext
>> >> >
>> >> > Both before1 and before2 should appear, but only before1 is shown.
>> >> >
>> >> > 3. How to wrap the line under the bulletin or number?
>> >> >
>> >> > To be more precise, the current wrapping behavior of, say, "\item 0
>> >> > 1
>> >> > 2 3 4 5 6 7 8 9" is:
>> >> >
>> >> > * 0 1 2 3 4 5 6 7
>> >> >   8 9
>> >> >
>> >> > How can we remove the indentation of the second line and make it
>> >> > like
>> >> >
>> >> > * 0 1 2 3 4 5 6 7
>> >> > 8 9
>> >> >
>> >> > 4. How to put the items on the same line?
>> >> >
>> >> > That is, for "\item 0 \item 1 \item 2", I would like it to be like
>> >> >
>> >> > * 0   * 1   * 2
>> >> >
>> >> > instead of
>> >> >
>> >> > * 0
>> >> > * 1
>> >> > * 2
>> >> >
>> >> > My context version: 2021.03.05 19:11, texlive.
>> >> >
>> >> > Any help with any of the problems above would be greatly
>> >> > appreciated.
>> >> >
>> >> > Best,
>> >> > Sylvain
>> >> >
>> >>
>> >>
>> ___
>> >> 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
>> >>
>> >>
>> ___
>> >>
>> >>
>> >
>>
>> ___
>> 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
>>
>> ___
>>
>
___
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  : 

[NTG-context] margin of inner item group

2021-09-07 Thread Sylvain Hubert via ntg-context
Dear List,

Does anyone know how to set the margin of an inner item group? The
natural way does not seem to work:

\showframe
\starttext
\startitemize[margin=5em]
\item 1
\startitemize[margin=10em]
\item 1
\item 2
\item 3
\stopitemize
\item 2
\item 3
\stopitemize
\stoptext

In the doc above, only the outer item group has a margin.

Any help will be appreciated.

Best,
Sylvain
___
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
___


Re: [NTG-context] itemize problems

2021-09-07 Thread fv leung via ntg-context
Use

 \startitemize[A,text][lefttext=,righttext=,stopper=]

then.

Maybe that's the new way.

Sylvain Hubert via ntg-context  於 2021年9月7日 週二 下午4:32寫道:

> Thanks, but this doesn't seem to work on my laptop:
>
> \starttext
> \startitemize[A,text][left=,right=,stopper=]
> \item 1
> \item 2
> \stopitemize
> \stoptext
>
> %output: (A) 1 (B) 2
>
> On 07/09/2021, fv leung via ntg-context  wrote:
> > I add
> >
> > left=,right=,
> >
> > in the second option group.
> >
> > 在 2021年9月7日週二 07:02,Sylvain Hubert via ntg-context 
> 寫道:
> >
> >> A few more information:
> >>
> >> For the 1st problem:
> >>
> >> It seems that \setupitemize accepts two option groups, to which
> >> n,packed and margin belong accordingly. However,
> >> \setupitemize[n][margin=2em] does not seem to work.
> >>
> >> For the 2nd problem:
> >>
> >> \setupitemize[columns,one], although doing nothing in theory, seems to
> >> fix the problem.
> >>
> >> For the 4th problem:
> >>
> >> I've found that we can do \setupitemize[A,text] which makes it like
> >>
> >> (A.) 0 (B.) 1 (C.) 2 (D.) 3
> >>
> >> The problem now is, how can we remove the parentheses around the item
> >> labels?
> >>
> >> On 07/09/2021, Sylvain Hubert  wrote:
> >> > Dear List,
> >> >
> >> > Here's a collection of four problems about item groups that I've just
> >> > encountered.
> >> >
> >> > 1. 'n' and 'packed' not playing well with other options.
> >> >
> >> > This works:
> >> >
> >> > \defineitemgroup[myitems][itemize][margin=2em,before=before]
> >> > \setupmyitems[n,packed]
> >> >
> >> > \starttext
> >> > text
> >> > \startmyitems
> >> > \item 1
> >> > \item 2
> >> > \stopmyitems
> >> > \stoptext
> >> >
> >> > This does not:
> >> >
> >> >
> >> > \defineitemgroup[myitems][itemize][margin=2em,before=before,n,packed]
> >> >
> >> > This does not either:
> >> >
> >> > \defineitemgroup[myitems][itemize]
> >> > \setupmyitems[n,packed,margin=2em,before=before]
> >> >
> >> > Is there a rule for this glitch which makes it worth memorizing, or is
> >> > this just a bug?
> >> >
> >> > 2. 'before' not working in nested item groups.
> >> >
> >> > \starttext
> >> > \startitemize[before=before1]
> >> > \item 1
> >> > \startitemize[before=before2]
> >> > \item 2
> >> > \stopitemize
> >> > \stopitemize
> >> > \stoptext
> >> >
> >> > Both before1 and before2 should appear, but only before1 is shown.
> >> >
> >> > 3. How to wrap the line under the bulletin or number?
> >> >
> >> > To be more precise, the current wrapping behavior of, say, "\item 0 1
> >> > 2 3 4 5 6 7 8 9" is:
> >> >
> >> > * 0 1 2 3 4 5 6 7
> >> >   8 9
> >> >
> >> > How can we remove the indentation of the second line and make it like
> >> >
> >> > * 0 1 2 3 4 5 6 7
> >> > 8 9
> >> >
> >> > 4. How to put the items on the same line?
> >> >
> >> > That is, for "\item 0 \item 1 \item 2", I would like it to be like
> >> >
> >> > * 0   * 1   * 2
> >> >
> >> > instead of
> >> >
> >> > * 0
> >> > * 1
> >> > * 2
> >> >
> >> > My context version: 2021.03.05 19:11, texlive.
> >> >
> >> > Any help with any of the problems above would be greatly appreciated.
> >> >
> >> > Best,
> >> > Sylvain
> >> >
> >>
> >>
> ___
> >> 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
> >>
> >>
> ___
> >>
> >>
> >
>
> ___
> 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
>
> ___
>
___
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
___


[NTG-context] error: (nodes): fuzzy token cleanup in whatsit node

2021-09-07 Thread Sylvain Hubert via ntg-context
Dear List,

I think I've just encountered a fragile bug. It is only reproducible
with exactly the same layout as the doc below. Any insertion or
removal of an item that changes the pagination would let the document
compile.

\defineitemgroup[choice][itemize]
\setupchoice[packed,columns,one]
\setupchoice[before={\blank[medium]}]

\starttext
.\blank[32*big]

\startitemize
\item 0

\startchoice[text]
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\blank[6*big]
\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\blank[6*big]
\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\item 0
\startchoice
\item 0
\item 0
\item 0
\item 0
\stopchoice

\stopitemize
\stoptext

test.log:

open source > level 1, order 1, name
'/home/me/apps/texlive/2021/texmf-dist/tex/context/base/mkiv/cont-yes.mkiv'
system  >
system  > ConTeXt  ver: 2021.03.05 19:11 MKIV  fmt: 2021.4.24
int: english/english
system  >
system  > 'cont-new.mkiv' loaded
open source > level 2, order 2, name
'/home/me/apps/texlive/2021/texmf-dist/tex/context/base/mkiv/cont-new.mkiv'
system  > beware: some patches loaded from cont-new.mkiv
close source> level 2, order 2, name
'/home/me/apps/texlive/2021/texmf-dist/tex/context/base/mkiv/cont-new.mkiv'
system  > files > jobname 'test', input './test', result 'test'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
open source > level 2, order 3, name '/home/me/code/qs-cs/test.tex'
fonts   > preloading latin modern fonts (second stage)
fonts   > 'fallback modern-designsize rm 12pt' is loaded
backend > xmp > using file
'/home/me/apps/texlive/2021/texmf-dist/tex/context/base/mkiv/lpdf-pdx.xml'
pages   > flushing realpage 1, userpage 1, subpage 1
pages   > flushing realpage 2, userpage 2, subpage 2
! error:  (nodes): fuzzy token cleanup in whatsit node with type
whatsit and subtype 29

Could anyone reproduce or explain this bug?

Thanks!

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


Re: [NTG-context] itemize problems

2021-09-07 Thread Sylvain Hubert via ntg-context
Thanks, but this doesn't seem to work on my laptop:

\starttext
\startitemize[A,text][left=,right=,stopper=]
\item 1
\item 2
\stopitemize
\stoptext

%output: (A) 1 (B) 2

On 07/09/2021, fv leung via ntg-context  wrote:
> I add
>
> left=,right=,
>
> in the second option group.
>
> 在 2021年9月7日週二 07:02,Sylvain Hubert via ntg-context  寫道:
>
>> A few more information:
>>
>> For the 1st problem:
>>
>> It seems that \setupitemize accepts two option groups, to which
>> n,packed and margin belong accordingly. However,
>> \setupitemize[n][margin=2em] does not seem to work.
>>
>> For the 2nd problem:
>>
>> \setupitemize[columns,one], although doing nothing in theory, seems to
>> fix the problem.
>>
>> For the 4th problem:
>>
>> I've found that we can do \setupitemize[A,text] which makes it like
>>
>> (A.) 0 (B.) 1 (C.) 2 (D.) 3
>>
>> The problem now is, how can we remove the parentheses around the item
>> labels?
>>
>> On 07/09/2021, Sylvain Hubert  wrote:
>> > Dear List,
>> >
>> > Here's a collection of four problems about item groups that I've just
>> > encountered.
>> >
>> > 1. 'n' and 'packed' not playing well with other options.
>> >
>> > This works:
>> >
>> > \defineitemgroup[myitems][itemize][margin=2em,before=before]
>> > \setupmyitems[n,packed]
>> >
>> > \starttext
>> > text
>> > \startmyitems
>> > \item 1
>> > \item 2
>> > \stopmyitems
>> > \stoptext
>> >
>> > This does not:
>> >
>> >
>> > \defineitemgroup[myitems][itemize][margin=2em,before=before,n,packed]
>> >
>> > This does not either:
>> >
>> > \defineitemgroup[myitems][itemize]
>> > \setupmyitems[n,packed,margin=2em,before=before]
>> >
>> > Is there a rule for this glitch which makes it worth memorizing, or is
>> > this just a bug?
>> >
>> > 2. 'before' not working in nested item groups.
>> >
>> > \starttext
>> > \startitemize[before=before1]
>> > \item 1
>> > \startitemize[before=before2]
>> > \item 2
>> > \stopitemize
>> > \stopitemize
>> > \stoptext
>> >
>> > Both before1 and before2 should appear, but only before1 is shown.
>> >
>> > 3. How to wrap the line under the bulletin or number?
>> >
>> > To be more precise, the current wrapping behavior of, say, "\item 0 1
>> > 2 3 4 5 6 7 8 9" is:
>> >
>> > * 0 1 2 3 4 5 6 7
>> >   8 9
>> >
>> > How can we remove the indentation of the second line and make it like
>> >
>> > * 0 1 2 3 4 5 6 7
>> > 8 9
>> >
>> > 4. How to put the items on the same line?
>> >
>> > That is, for "\item 0 \item 1 \item 2", I would like it to be like
>> >
>> > * 0   * 1   * 2
>> >
>> > instead of
>> >
>> > * 0
>> > * 1
>> > * 2
>> >
>> > My context version: 2021.03.05 19:11, texlive.
>> >
>> > Any help with any of the problems above would be greatly appreciated.
>> >
>> > Best,
>> > Sylvain
>> >
>>
>> ___
>> 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
>>
>> ___
>>
>>
>
___
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
___