[NTG-context] BUG: colour spilling in btxrendering

2024-02-01 Thread Alexandre Christe
Dear list,

It seems with one of the latest lmtx this old reported issue 
(https://www.mail-archive.com/ntg-context@ntg.nl/msg84988.html) is back.

MWE:

\setupinteraction[state=start,color=red,style=]
\setupbtx[aps:cite][alternative=entry]
\usebtxdefinitions[aps]

\startbuffer [bib]
@ARTICLE{67533,
 author={De Doncker, R.W.A.A. and Divan, D.M. and Kheraluwala, M.H.},
 journal={IEEE Transactions on Industry Applications},
 title={A three-phase soft-switched high-power-density DC/DC converter for 
high-power applications},
 year={1991},
 volume={27},
 number={1},
 pages={63-73},
 keywords={DC-DC power converters;Resonance;Switching 
frequency;Inverters;Filters;Snubbers;Circuit topology;Thyristors;Switching 
converters;Industry Applications Society},
 doi={10.1109/28.67533}}

}
\stopbuffer
\usebtxdataset [bib.buffer]

\starttext

\cite[alternative=entry][67533]

\startnointerference
 \placelistofpublications
\stopnointerference

\stoptext

A. Christe
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Bug? Text following columns at end of page goes into footer not next page

2023-09-30 Thread Bruce Horrocks
Two column text that ends near the foot of a page can push the next line into 
the footer rather than starting a new page.

MWE for ConTeXt  ver: 2023.09.26 18:19 LMTX :-

\setuppapersize [A4]
\showframe

\starttext
Knuth in knolumns
\dorecurse{30}{\crlf}

\startcolumns
  \input knuth
\stopcolumns

This line goes into the footer rather than the next page.
\stoptext

—
Bruce Horrocks
Hampshire, UK

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___

[NTG-context] Bug(?) in https://wiki.contextgarden.net/Tabulate#Spanning_Multiple_Pages

2023-09-11 Thread Jim
Hi,

In https://wiki.contextgarden.net/Tabulate#Spanning_Multiple_Pages the wiki
has "internal error: convert failed".

Removing \color[red] from \setuptabulate in that example gives a working
example (at least in a separate file on my machine).  I tried changing the
title specification to
title={\color[red]{Fenchurch St. Paul}},
as well as
title={{\color[red]{Fenchurch St. Paul}}},
but both of these reward me with a runaway context process.

Can someone point out the correct way to do what the wiki intended?

Thanks.
Jim

P.S. Bonus question: should an incorrect use of color really cause an
(apparent) infinite loop, or is that a second issue which deserves to be on
some to-do list?

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug or feature? \numexpression and hashes

2023-09-04 Thread Jairo A. del Rio
Hi, list. The following fails with a "Missing number, treated as zero"
error prompt:

\starttext
\expandedrepeat2{\expandedrepeat2{\the\numexpression#I+#P\relax\ }}
\stoptext

OTOH, \numexpr works seamlessly. Tested on ConTeXt 2023.09.03 19:03. Thanks
in advance.

Best regards,

Jairo
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___

[NTG-context] Bug between \definealternativestyle and makeup?

2023-08-27 Thread Alex Leray

Hi,

I found that using \definealternativestyle in conjunction with Makeup 
insert a page before my Makeup page.


Any idea?

Thanks

* * *

\definecharacterkerning [mykerning] [factor=0.15]
\definealternativestyle[mystyle][{\setcharacterkerning[mykerning]}]. %%% 
BUG!!!


\definemakeup [title] [doublesided=empty, pagestate=start]
\starttext
\starttitlemakeup
Title
\stoptitlemakeup
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in context

2023-05-14 Thread Hans Hagen via ntg-context

On 5/13/2023 2:04 PM, Lutz Haseloff via ntg-context wrote:

Hi Hans, hi all,

I mainly use ConTeXt in a server environment. So I am a friend of the 
console.

I found a small problem there.
When I invoke context with parameter --ansi,
the logfile remains empty.
I tried Linux aarch64 and Windows64.
sure, as it makes no sense to write ansi sequences to the log so then 
that channel is turned off


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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in context

2023-05-13 Thread Marco Patzer via ntg-context
On Sat, 13 May 2023 14:04:49 +0200
Lutz Haseloff via ntg-context  wrote:

> When I invoke context with parameter --ansi, the logfile remains
> empty.

I can confirm:

  https://www.mail-archive.com/ntg-context@ntg.nl/msg90303.html

Marco
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in context

2023-05-13 Thread Lutz Haseloff via ntg-context
Hi Hans, hi all,

I mainly use ConTeXt in a server environment. So I am a friend of the console.
I found a small problem there.
When I invoke context with parameter --ansi,
the logfile remains empty.
I tried Linux aarch64 and Windows64.

Greetings Lutz___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-23 Thread Alan Braslau via ntg-context
On Wed, 22 Mar 2023 08:50:10 +0100
Hans Hagen via ntg-context  wrote:

> I might have missed a link.

https://github.com/notofonts/notofonts.github.io

-- 
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-22 Thread Hans Hagen via ntg-context

On 3/22/2023 11:10 AM, Hans Hagen via ntg-context wrote:

http://liyanrui.github.io/share/fonts/fonts-noto-cjk.zip 


Ok. I'll check it.

next upload:

>mtxrun --script font --list --file NotoSerifCJK-Regular.ttc
familyname   weight   stylewidthvariant   fontname 
 filename   subfont   fontweight


notoserifcjkhk   normal   normal   normal   normal 
notoserifcjkhkregular   NotoSerifCJK-Regular.ttc 5   conflict: 
regular


-
  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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-22 Thread Hans Hagen via ntg-context

On 3/22/2023 9:58 AM, Li Yanrui (李延瑞) via ntg-context wrote:



Hans Hagen via ntg-context > 于2023年3月22日周三 15:51写道:


On 3/22/2023 7:15 AM, Li Yanrui (李延瑞) via ntg-context wrote:
 > Hi Hans,
 >
 > I have already installed some Chinese TTC fonts, e.g.
 > NotoSerifCJK-Regular.ttc. But when I use mtxrun command to search
them,
 > I get an error.
 >
 > $ mtxrun --script font --list --file NotoSerifCJK-Regular.ttc
 > lua error : function call:
 >
...e/garfileo/opt/context/tex/texmf-linux-64/bin/mtxrun.lua:10012: bad
 > argument #9 to 'format' (number expected, got string)
Where can i find that font? There was a time when one could download a
zip with all noto fonts but last time i checked that option was gone
and
one ends up with downloading single ones which is a waste of time but I
might have missed a link.


These fonts that I use are provided in ubuntu desktop. If you have an 
ubuntu system, you can get all of them by


$ sudo apt install fonts-noto-cjk # or more fonts in the 
fonts-noto-cjk-extra package.


The package includes the following fonts:

NotoSerifCJK-Regular.ttc
NotoSerifCJK-Bold.ttc
NotoSansCJK-Bold.ttc
NotoSansCJK-Regular.ttc

I have  uploaded the four of them into github. The download link is

http://liyanrui.github.io/share/fonts/fonts-noto-cjk.zip 


Ok. I'll check it.

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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-22 Thread 李延瑞
Hans Hagen via ntg-context  于2023年3月22日周三 15:51写道:

> On 3/22/2023 7:15 AM, Li Yanrui (李延瑞) via ntg-context wrote:
> > Hi Hans,
> >
> > I have already installed some Chinese TTC fonts, e.g.
> > NotoSerifCJK-Regular.ttc. But when I use mtxrun command to search them,
> > I get an error.
> >
> > $ mtxrun --script font --list --file NotoSerifCJK-Regular.ttc
> > lua error : function call:
> > ...e/garfileo/opt/context/tex/texmf-linux-64/bin/mtxrun.lua:10012: bad
> > argument #9 to 'format' (number expected, got string)
> Where can i find that font? There was a time when one could download a
> zip with all noto fonts but last time i checked that option was gone and
> one ends up with downloading single ones which is a waste of time but I
> might have missed a link.
>

These fonts that I use are provided in ubuntu desktop. If you have an
ubuntu system, you can get all of them by

$ sudo apt install fonts-noto-cjk # or more fonts in the
fonts-noto-cjk-extra package.

The package includes the following fonts:

NotoSerifCJK-Regular.ttc
NotoSerifCJK-Bold.ttc
NotoSansCJK-Bold.ttc
NotoSansCJK-Regular.ttc

I have  uploaded the four of them into github. The download link is

http://liyanrui.github.io/share/fonts/fonts-noto-cjk.zip

---
Best regards,

Li Yanrui
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-22 Thread Hans Hagen via ntg-context

On 3/22/2023 7:15 AM, Li Yanrui (李延瑞) via ntg-context wrote:

Hi Hans,

I have already installed some Chinese TTC fonts, e.g. 
NotoSerifCJK-Regular.ttc. But when I use mtxrun command to search them, 
I get an error.


$ mtxrun --script font --list --file NotoSerifCJK-Regular.ttc
lua error : function call: 
...e/garfileo/opt/context/tex/texmf-linux-64/bin/mtxrun.lua:10012: bad 
argument #9 to 'format' (number expected, got string)
Where can i find that font? There was a time when one could download a 
zip with all noto fonts but last time i checked that option was gone and 
one ends up with downloading single ones which is a waste of time but I 
might have missed a link.


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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in searching TTC fonts for the script of mtxrun

2023-03-22 Thread 李延瑞
Hi Hans,

I have already installed some Chinese TTC fonts, e.g.
NotoSerifCJK-Regular.ttc. But when I use mtxrun command to search them, I
get an error.

$ mtxrun --script font --list --file NotoSerifCJK-Regular.ttc
lua error : function call:
...e/garfileo/opt/context/tex/texmf-linux-64/bin/mtxrun.lua:10012: bad
argument #9 to 'format' (number expected, got string)

-- 
Best regards,

Li Yanrui
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in tabulate

2023-03-21 Thread Hans Hagen via ntg-context

On 3/21/2023 7:20 AM, Li Yanrui (李延瑞) via ntg-context wrote:

Hi,

Please see the following example:

\startTEXpage[offset=5mm]
\starttabulate[|c|c|c|]
\VL 1 \VL 2 \VL 3\VL\NR
\stoptabulate
\blank
\starttabulate[|c|c|c|]
\NC 1 \NC 2 \NC 3\NR
\stoptabulate
\stopTEXpage

In its result, there is a rule in the left side of the second tabulate. 
The result is attached. My lmtx version is 2023.03.20 17:07.

in tabl-tbl.mkxl you can patch this

\def\tabl_tabulate_vrule_reset_step % undefined or relax
  {\gletcsname\??tabulatevrule0\endcsname\undefined
   \gletcsname\??tabulatevrule\the\fastloopindex\endcsname\undefined}

after that remake the format,

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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in tabulate

2023-03-21 Thread 李延瑞
Hi,

Please see the following example:

\startTEXpage[offset=5mm]
\starttabulate[|c|c|c|]
\VL 1 \VL 2 \VL 3\VL\NR
\stoptabulate
\blank
\starttabulate[|c|c|c|]
\NC 1 \NC 2 \NC 3\NR
\stoptabulate
\stopTEXpage

In its result, there is a rule in the left side of the second tabulate. The
result is attached. My lmtx version is 2023.03.20 17:07.

-- 
Best regards,

Li Yanrui


foo.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in columns

2023-03-15 Thread 李延瑞
Hi,

There are some footnotes in my text. When I use
\startcolumns...\stopcolumns, the locations of  footnotes are not right.
Please see the followging sample:

\starttext
If there is a footnote here\footnote{It's a footnote!}.
\startcolumns[n=2]
\input knuth
\column
\input knuth
\stopcolumns
The result is not right.
\stoptext


The result is attached. My lmtx version is 2023.03.10 12:18.
 foo.pdf


-- 
Best regards,

Li Yanrui
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in maths environment: thematrix

2023-03-12 Thread Otared Kavian via ntg-context


> On 12 Mar 2023, at 18:04, Hans Hagen via ntg-context  
> wrote:
>> […]
> i have a fix but there will be no uploads till texlive has been frozen / 
> packages
> 
> Hans

Thanks Hans ! There is no problem for waiting…

Best regards : Otared___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in maths environment: thematrix

2023-03-12 Thread Hans Hagen via ntg-context

On 3/9/2023 2:45 PM, Otared Kavian via ntg-context wrote:


Hi Hans,

I noticed that in some situations the command \thematrix does not show all its 
arguments correctly: some parts are omitted in the typeset formula. In some 
occasions adding some groupings solves the issue, but not always. I noticed 
this bug two weeks ago, but could not produce a minimal example until now…

Please see below, in particular the output for the matrices M_1, M_2 and M_3…

Best regards: Otared

% begin bug-thematrix.tex
\starttext
\startformula
M_{1}(t)
:= \thematrix{{\rm e}^s ; {\rm e}^t}, \qquad
B_{1}(t) := \thematrix{1 , {\rm e}^t},
\stopformula

\startformula
M_{2}(t)
:= \thematrix{{{\rm e}^s} , {{\rm e}^t}}, \qquad
B_{2}(t) := \thematrix{0 ; {{\rm e}^t}},
\stopformula


\startformula
M_{3}(t)
= \thematrix{{\rm e}^s, {\rm e}^t ; 0 , {\rm e}^t}.
\stopformula


\startformula
M_{4}(t)
= \thematrix{1, {{\rm e}^t} + 1 ; 0 , {{\rm e}^t}}.
\stopformula

\stoptext
% end bug-thematrix.tex
i have a fix but there will be no uploads till texlive has been frozen / 
packages


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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in maths environment: thematrix

2023-03-09 Thread Otared Kavian via ntg-context

Hi Hans,

I noticed that in some situations the command \thematrix does not show all its 
arguments correctly: some parts are omitted in the typeset formula. In some 
occasions adding some groupings solves the issue, but not always. I noticed 
this bug two weeks ago, but could not produce a minimal example until now…

Please see below, in particular the output for the matrices M_1, M_2 and M_3…

Best regards: Otared

% begin bug-thematrix.tex
\starttext
\startformula
M_{1}(t)
:= \thematrix{{\rm e}^s ; {\rm e}^t}, \qquad
B_{1}(t) := \thematrix{1 , {\rm e}^t},
\stopformula

\startformula
M_{2}(t)
:= \thematrix{{{\rm e}^s} , {{\rm e}^t}}, \qquad
B_{2}(t) := \thematrix{0 ; {{\rm e}^t}},
\stopformula


\startformula
M_{3}(t)
= \thematrix{{\rm e}^s, {\rm e}^t ; 0 , {\rm e}^t}.
\stopformula


\startformula
M_{4}(t)
= \thematrix{1, {{\rm e}^t} + 1 ; 0 , {{\rm e}^t}}.
\stopformula

\stoptext
% end bug-thematrix.tex
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug with \startnarrow?

2023-03-03 Thread Denis Maier via ntg-context
> -Ursprüngliche Nachricht-
> Von: peter.hopcr...@icloud.com 
> Gesendet: Donnerstag, 23. Februar 2023 21:15
> An: mailing list for ConTeXt users 
> Cc: Maier, Denis Christian (UB) 
> Betreff: Re: [NTG-context] Bug with \startnarrow?
> 
> It's the documentation that has the bug. With \startnarrow, you need two
> sets of square brackets, 1 for the \setupnarrower data and 1 for the
> \startnarrower data. Like this:
> 
> \starttext
> Some text before
> \startnarrow[left=5cm,right=1cm,before={\blank[2*line]},after={\blank[halfli
> ne]}][left, right] narrower text \stopnarrow some text after \stoptext

Thanks, good to know. I'll update the documentation.

Best,
Denis
> 
> > On 23/02/2023, at 11:14 PM, Denis Maier via ntg-context  cont...@ntg.nl> wrote:
> >
> > Hi,
> >  While doing some more tests with my example from yesterday (tables in
> \startnarrow), I’ve realized that the example from the wiki doesn’t seem to
> quite work as expected:
> >  %%
> > \starttext
> > Some text before
> > \startnarrow[left=2cm,right=1cm,before={\blank[2*line]},after={\blank[
> > halfline]}]
> > narrower text
> > \stopnarrow
> > some text after
> > \stoptext
> > %%
> >  Already here, the extra margins on both sides seem to be equal. Changing
> the size of the left extra margin has no effect at all.
> >  %%
> > \starttext
> > \startnarrow[left=10cm,right=2cm]
> > \input ward
> > \stopnarrow
> >  but:
> >  \setupnarrower[left=5cm, right=2cm]
> > \startnarrower[left,right]
> > \input ward
> > \stopnarrower
> > \stoptext
> > %%
> >  Is this a bug or intended behaviour ?
> >  Best,
> > Denis
> >
> 
> __
> > _ If your question is of interest to others as well,
> > please add an entry to the Wiki!
> >
> > maillist : ntg-context@ntg.nl /
> > https://www.ntg.nl/mailman/listinfo/ntg-context
> > webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> > archive  : https://bitbucket.org/phg/context-mirror/commits/
> > wiki : https://contextgarden.net
> >
> 
> __
> > _
> 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug with \startnarrow?

2023-02-23 Thread peter.hopcroft--- via ntg-context
It's the documentation that has the bug. With \startnarrow, you need two sets 
of square brackets, 1 for the \setupnarrower data and 1 for the \startnarrower 
data. Like this:

\starttext
Some text before
\startnarrow[left=5cm,right=1cm,before={\blank[2*line]},after={\blank[halfline]}][left,
 right]
narrower text
\stopnarrow
some text after
\stoptext

> On 23/02/2023, at 11:14 PM, Denis Maier via ntg-context  
> wrote:
> 
> Hi,
>  While doing some more tests with my example from yesterday (tables in 
> \startnarrow), I’ve realized that the example from the wiki doesn’t seem to 
> quite work as expected:
>  %%
> \starttext
> Some text before
> \startnarrow[left=2cm,right=1cm,before={\blank[2*line]},after={\blank[halfline]}]
> narrower text
> \stopnarrow
> some text after
> \stoptext
> %%
>  Already here, the extra margins on both sides seem to be equal. Changing the 
> size of the left extra margin has no effect at all.
>  %%
> \starttext
> \startnarrow[left=10cm,right=2cm]
> \input ward
> \stopnarrow
>  but:
>  \setupnarrower[left=5cm, right=2cm]
> \startnarrower[left,right]
> \input ward
> \stopnarrower
> \stoptext
> %%
>  Is this a bug or intended behaviour ?
>  Best,
> Denis
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / 
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
> ___


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug with \startnarrow?

2023-02-23 Thread Denis Maier via ntg-context
Hi,

While doing some more tests with my example from yesterday (tables in 
\startnarrow), I've realized that the example from the wiki doesn't seem to 
quite work as expected:

%%
\starttext
Some text before
\startnarrow[left=2cm,right=1cm,before={\blank[2*line]},after={\blank[halfline]}]
narrower text
\stopnarrow
some text after
\stoptext
%%

Already here, the extra margins on both sides seem to be equal. Changing the 
size of the left extra margin has no effect at all.

%%
\starttext
\startnarrow[left=10cm,right=2cm]
\input ward
\stopnarrow

but:

\setupnarrower[left=5cm, right=2cm]
\startnarrower[left,right]
\input ward
\stopnarrower
\stoptext
%%

Is this a bug or intended behaviour ?

Best,
Denis
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-15 Thread Pablo Rodriguez via ntg-context
On 2/4/23 07:49, Hugo Landau via ntg-context wrote:
> On this page of the wiki there is an example for wrapping long words,
> like long hexadecimal strings:
> 
> https://wiki.contextgarden.net/Wrapping
> 
> This example is buggy because it deletes one character at the point that
> it is wrapped.

Hugo,

I have just updated the wiki with another way of line breaking SHA sums:

  https://wiki.contextgarden.net/Wrapping#Line_breaking_with_SHA512_sums

It avoids the issue you encountered and it is an easy workaround.

Just in case it might help,

Pablo
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-06 Thread Hans Hagen via ntg-context

On 2/5/2023 4:52 PM, Pablo Rodriguez via ntg-context wrote:

On 2/5/23 13:13, Hans Hagen via ntg-context wrote:

On 2/5/2023 12:32 PM, Pablo Rodriguez via ntg-context wrote:

[...]
Are we missing something or is this a bug?

what do you expect as result? (maybe try \righthyphenmin=1)


Line breaks are removing characters.

In the sample below, output from

   \hsize\zeropoint
   \sha{a1b2c3d4}

reads:

   a
  _
  _
  _
  _
   3d4

I’m afraid \righthyphenmin=-1 prevents hyphenation (it seems to do it
everywhere).

This

   \unexpanded\def\sha#1%
 {\begingroup
  \sethyphenationfeatures[sha]%
  \showglyphs
  \righthyphenmin1
  #1%
  \endgroup}

gives

a·
·
·
·
·
·
4


-
  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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-05 Thread Pablo Rodriguez via ntg-context
On 2/5/23 13:13, Hans Hagen via ntg-context wrote:
> On 2/5/2023 12:32 PM, Pablo Rodriguez via ntg-context wrote:
>> [...]
>> Are we missing something or is this a bug?
> what do you expect as result? (maybe try \righthyphenmin=1)

Line breaks are removing characters.

In the sample below, output from

  \hsize\zeropoint
  \sha{a1b2c3d4}

reads:

  a
 _
 _
 _
 _
  3d4

I’m afraid \righthyphenmin=-1 prevents hyphenation (it seems to do it
everywhere).

Sorry, but I don’t get what is wrong here.

Many thanks for your help,

Pablo


  \startluacode
  function document.addfunnyhyphen(tfmdata)
  local underscore = utf.byte("_")
  local char   = tfmdata.characters[underscore]
  if not char then return end
  tfmdata.characters[0xFE000]   = {
  width= 0,
  height   = 0,
  depth= 0,
  commands = {
  { "right", -char.width },
  { "down", char.depth },
  { "slot", 1, underscore },
  }
  }
  end


  utilities.sequencers.appendaction("aftercopyingcharacters",
  "after","document.addfunnyhyphen")

  local shared = {
  start  = 1,
  length = 1,
  before = utf.char(0xFE000),
  after  = nil,
  left   = false,
  right  = false,
  }

  local all = table.setmetatableindex({ }, function(t,k)
  return shared
  end)

  languages.hyphenators.traditional.installmethod("sha",
  function(dictionary,word,n)
  return all
  end
  )
  \stopluacode

  \definehyphenationfeatures
   [sha]
   [characters=all,
alternative=sha,
righthyphenchar="FE000]

  \unexpanded\def\sha#1%
   {\begingroup\tt
\righthyphenmin=-1
\sethyphenationfeatures[sha]%
\setuphyphenation[method=traditional]%
#1%
\endgroup}

  \starttext
  \startTEXpage[width=6em, offset=.25em]
  \hsize\zeropoint
  \sha{a1b2c3d4}

  extraordinary linguistics

  \righthyphenmin=-1
  extraordinary linguistics
  \stopTEXpage
  \stoptext

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-05 Thread Hans Hagen via ntg-context

On 2/5/2023 12:32 PM, Pablo Rodriguez via ntg-context wrote:

On 2/4/23 10:37, Pablo Rodriguez via ntg-context wrote:

On 2/4/23 07:49, Hugo Landau via ntg-context wrote:

On this page of the wiki there is an example for wrapping long words,
like long hexadecimal strings:

https://wiki.contextgarden.net/Wrapping

This example is buggy because it deletes one character at the point that
it is wrapped.

Anyone have a solution?


Many thanks for your report, Hugo.

I use this code from time to time and I totally overlooked this.

Have you checked all options that the sample contains?


Hans,

I have just checked that these line breakings loose a character in all
options.

The next sample displays the issue clearly:


   \startluacode

 --local shared = {
 --start  = 1,
 --length = 1,
 --left   = false,
 --right  = false,
 --}

local shared = {
start  = 1,
length = 1,
before = utf.char(0xB7),
after  = nil,
left   = false,
right  = false,
}

-- languages.hyphenators.traditional.installmethod("sha",
-- function(dictionary,word,n)
-- local t = { }
-- for i=1,#word do
-- t[i] = shared
-- end
-- return t
-- end
-- )

-- or more efficient when used often:

-- local all = { }
-- for i=1,512 do
-- all[i] = shared
-- end
-- languages.hyphenators.traditional.installmethod("sha",
-- function(dictionary,word,n)
-- return all
-- end
-- )

-- or more obscure:

-- local all = table.setmetatableindex({ }, function(t,k)
-- t[k] = shared
-- return shared
-- end)
--
-- languages.hyphenators.traditional.installmethod("sha",
-- function(dictionary,word,n)
-- return all
-- end
-- )

-- or just (lua is fast enough anyway)

local all = table.setmetatableindex({ }, function(t,k)
return shared
end)

languages.hyphenators.traditional.installmethod("sha",
function(dictionary,word,n)
return all
end
)
   \stopluacode

   \definehyphenationfeatures
  [sha]
  [characters=all,
   alternative=sha]

\unexpanded\def\sha#1%
  {\begingroup
   \sethyphenationfeatures[sha]%
   #1%
   \endgroup}

\setuphyphenation[method=traditional]
%
%  \unexpanded\def\sha#1%
% {\begingroup
%  \sethyphenationfeatures[sha]%
%  \setuphyphenation[method=traditional]%
%  #1%
%  \endgroup}

   \starttext
   \hyphenatedword{\sha{8b2f3c087046c3943ace0dc4f958ef2138e58a51b40e%
   ef6fab6fa1aeb845cc257a410ab1b914bc399b4293f%
   31c76fc2c73e5be5ea4d329f9e6820984688efec2}}
   \stoptext

Are we missing something or is this a bug?

what do you expect as result? (maybe try \righthyphenmin=1)


-
  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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-05 Thread Floris van Manen via ntg-context



On 05/02/2023 12:32, Pablo Rodriguez via ntg-context wrote:

Are we missing something or is this a bug?


If you add a \tt at the beginning, the lines have different length.
not sure why, but there is a reason to it...

\startTEXpage[offset=3em]
\tt
\setupalign[tolerant,stretch]

\dorecurse {10} {%
 some sha
 \sha{8b2f3c087046c3943ace0dc4f958ef2138e58a51b40e%
ef6fab6fa1aeb845cc257a410ab1b914bc399b4293f%
31c76fc2c73e5be5ea4d329f9e6820984688efec2} and
}

\stopTEXpage

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-05 Thread Pablo Rodriguez via ntg-context
On 2/4/23 10:37, Pablo Rodriguez via ntg-context wrote:
> On 2/4/23 07:49, Hugo Landau via ntg-context wrote:
>> On this page of the wiki there is an example for wrapping long words,
>> like long hexadecimal strings:
>>
>> https://wiki.contextgarden.net/Wrapping
>>
>> This example is buggy because it deletes one character at the point that
>> it is wrapped.
>>
>> Anyone have a solution?
> 
> Many thanks for your report, Hugo.
> 
> I use this code from time to time and I totally overlooked this.
> 
> Have you checked all options that the sample contains?

Hans,

I have just checked that these line breakings loose a character in all
options.

The next sample displays the issue clearly:


  \startluacode

--local shared = {
--start  = 1,
--length = 1,
--left   = false,
--right  = false,
--}

   local shared = {
   start  = 1,
   length = 1,
   before = utf.char(0xB7),
   after  = nil,
   left   = false,
   right  = false,
   }

   -- languages.hyphenators.traditional.installmethod("sha",
   -- function(dictionary,word,n)
   -- local t = { }
   -- for i=1,#word do
   -- t[i] = shared
   -- end
   -- return t
   -- end
   -- )

   -- or more efficient when used often:

   -- local all = { }
   -- for i=1,512 do
   -- all[i] = shared
   -- end
   -- languages.hyphenators.traditional.installmethod("sha",
   -- function(dictionary,word,n)
   -- return all
   -- end
   -- )

   -- or more obscure:

   -- local all = table.setmetatableindex({ }, function(t,k)
   -- t[k] = shared
   -- return shared
   -- end)
   --
   -- languages.hyphenators.traditional.installmethod("sha",
   -- function(dictionary,word,n)
   -- return all
   -- end
   -- )

   -- or just (lua is fast enough anyway)

   local all = table.setmetatableindex({ }, function(t,k)
   return shared
   end)

   languages.hyphenators.traditional.installmethod("sha",
   function(dictionary,word,n)
   return all
   end
   )
  \stopluacode

  \definehyphenationfeatures
 [sha]
 [characters=all,
  alternative=sha]

   \unexpanded\def\sha#1%
 {\begingroup
  \sethyphenationfeatures[sha]%
  #1%
  \endgroup}

   \setuphyphenation[method=traditional]
%
%  \unexpanded\def\sha#1%
% {\begingroup
%  \sethyphenationfeatures[sha]%
%  \setuphyphenation[method=traditional]%
%  #1%
%  \endgroup}

  \starttext
  \hyphenatedword{\sha{8b2f3c087046c3943ace0dc4f958ef2138e58a51b40e%
  ef6fab6fa1aeb845cc257a410ab1b914bc399b4293f%
  31c76fc2c73e5be5ea4d329f9e6820984688efec2}}
  \stoptext

Are we missing something or is this a bug?

Many thanks for your help,

Pablo
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-04 Thread Pablo Rodriguez via ntg-context
On 2/4/23 07:49, Hugo Landau via ntg-context wrote:
> On this page of the wiki there is an example for wrapping long words,
> like long hexadecimal strings:
> 
> https://wiki.contextgarden.net/Wrapping
> 
> This example is buggy because it deletes one character at the point that
> it is wrapped.
> 
> Anyone have a solution?

Many thanks for your report, Hugo.

I use this code from time to time and I totally overlooked this.

Have you checked all options that the sample contains?

Many thanks for your help,

Pablo

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in verbatim wrapping examples on wiki

2023-02-03 Thread Hugo Landau via ntg-context
On this page of the wiki there is an example for wrapping long words,
like long hexadecimal strings:

https://wiki.contextgarden.net/Wrapping

This example is buggy because it deletes one character at the point that
it is wrapped.

In the example given, running context turns '257a410' into '257410'.

The DNA example below it exhibits the same problem.

Anyone have a solution?
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] bug $\vec{}$

2023-01-20 Thread Alexandre Christe via ntg-context
It does! Thanks Mikael.

Le ven. 20 janv. 2023 à 16:52, Mikael Sundqvist via ntg-context <
ntg-context@ntg.nl> a écrit :

> I think there is a change going on, try with
>
> \definemathtopaccent[top:stretch][vec]["20D7]
>
> for the moment. Does it look OK?
>
> /Mikael
>
> On Fri, Jan 20, 2023 at 2:45 PM Alexandre Christe via ntg-context
>  wrote:
> >
> > I confirm the behavior.
> >
> > Also possibly linked is that the spacing around $\overrightarrow{k}$
> seems pretty weird, so atm there is no fallback solution.
> >
> >
> >
> > Le ven. 20 janv. 2023 à 14:37, Alan Braslau via ntg-context <
> ntg-context@ntg.nl> a écrit :
> >>
> >> MWE:
> >>
> >> \starttext
> >>
> >> $\vec{k}$
> >>
> >> \stoptext
> >>
> >> places the arrow *before* the symbol "k", latest download.
> >>
> >> Alan
> >>
> ___
> >> If your question is of interest to others as well, please add an entry
> to the Wiki!
> >>
> >> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> >> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> >> archive  : https://bitbucket.org/phg/context-mirror/commits/
> >> wiki : https://contextgarden.net
> >>
> ___
> >
> >
> ___
> > If your question is of interest to others as well, please add an entry
> to the Wiki!
> >
> > maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> > webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> > archive  : https://bitbucket.org/phg/context-mirror/commits/
> > wiki : https://contextgarden.net
> >
> ___
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] bug $\vec{}$

2023-01-20 Thread Mikael Sundqvist via ntg-context
I think there is a change going on, try with

\definemathtopaccent[top:stretch][vec]["20D7]

for the moment. Does it look OK?

/Mikael

On Fri, Jan 20, 2023 at 2:45 PM Alexandre Christe via ntg-context
 wrote:
>
> I confirm the behavior.
>
> Also possibly linked is that the spacing around $\overrightarrow{k}$ seems 
> pretty weird, so atm there is no fallback solution.
>
>
>
> Le ven. 20 janv. 2023 à 14:37, Alan Braslau via ntg-context 
>  a écrit :
>>
>> MWE:
>>
>> \starttext
>>
>> $\vec{k}$
>>
>> \stoptext
>>
>> places the arrow *before* the symbol "k", latest download.
>>
>> Alan
>> ___
>> If your question is of interest to others as well, please add an entry to 
>> the Wiki!
>>
>> maillist : ntg-context@ntg.nl / 
>> https://www.ntg.nl/mailman/listinfo/ntg-context
>> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
>> archive  : https://bitbucket.org/phg/context-mirror/commits/
>> wiki : https://contextgarden.net
>> ___
>
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
>
> maillist : ntg-context@ntg.nl / 
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
> ___
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] bug $\vec{}$

2023-01-20 Thread Jacob Kauffmann via ntg-context
Not sure if this is related in any way, but \overset behaves weirdly with the 
equal sign:

\startformula
\overset{weird}{=}
\stopformula

(workaround/solution is \overset{weird}{\mathop{=}}, or \mathop{=}^{weird})



signature.asc
Description: Message signed with OpenPGP
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] bug $\vec{}$

2023-01-20 Thread Alexandre Christe via ntg-context
I confirm the behavior.

Also possibly linked is that the spacing around $\overrightarrow{k}$ seems
pretty weird, so atm there is no fallback solution.



Le ven. 20 janv. 2023 à 14:37, Alan Braslau via ntg-context <
ntg-context@ntg.nl> a écrit :

> MWE:
>
> \starttext
>
> $\vec{k}$
>
> \stoptext
>
> places the arrow *before* the symbol "k", latest download.
>
> Alan
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] bug $\vec{}$

2023-01-20 Thread Alan Braslau via ntg-context
MWE:

\starttext

$\vec{k}$

\stoptext

places the arrow *before* the symbol "k", latest download.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in math alignment

2022-11-03 Thread Otared Kavian via ntg-context
Hi Mikael,

Thanks for your reply.
Indeed with your hint the issue disappears. 
I’ll change my definition…

Best regards: Otared

> On 2 Nov 2022, at 21:44, Mikael Sundqvist via ntg-context 
>  wrote:
> […]
> I think in this case it is better to use a mathsimplealign instead of a 
> matrix.
> 
> \definemathsimplealign[pdeproblem][
> left={\startmathfenced[cases]},
> right=\stopmathfenced,
> align={1:right,2:left,3:left},
> strut=yes,
> ]
> 
> \definemathsimplealign[collected][
> left={\startmathfenced[sesac]},
> right=\stopmathfenced,
> align={1:right,2:left,3:left},
> strut=yes,
> ]
> 
> \starttext
> 
> \placeformula
> \startformula
> \startpdeproblem
> \NC - \Delta u \NC = 0 \NC \qquad\text{in } \Omega \NR
> \NC \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC
> \qquad\text{on } \partial\Omega \NR
> \stoppdeproblem
> \stopformula
> 
> \placeformula
> \startformula
> \startcollected
> \NC - \Delta u \NC = 0 \NC \qquad\text{in } \Omega \NR
> \NC \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC
> \qquad\text{on } \partial\Omega \NR
> \stopcollected
> \stopformula
> 
> \stoptext
> 
> Best, Mikael
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / 
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
> ___

Otared Kavian
e-mail: ota...@gmail.com
Phone: +33 6 88 26 70 95



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in math alignment

2022-11-02 Thread Mikael Sundqvist via ntg-context
Hi,

On Wed, Nov 2, 2022 at 9:19 PM Otared Kavian via ntg-context
 wrote:
>
> Dear Jeong,
>
> Thanks for testing my example, and pointing to the solution using \dm (which 
> I didn’t know…).
> I think the correct behaviour of math alignments should avoid using 
> additional commands such as \dm.
>
> We’ll see what Hans and Mikael say.
>
> Best regards: OK
>
> On 2 Nov 2022, at 12:53, Jeong Dal via ntg-context  wrote:
>
> Dear Otared,
>
>
> I think there is an issue with the size of math fonts in \frac when used in 
> math alignments, as it is is shown in the following example.
>
>
> I confirm what you said.
>
> However, if I use \dm{} instead of \displaystyle as following, then the 
> output is correct.
>
> \placeformula
> \startformula
> \startalignedcases
> \NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
> \NC \dm{\frac{\partial u}{\partial {\bi n}}}
> \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
> \stopalignedcases
> \stopformula
> or this (with\type{\displaystyle} added)
> \placeformula
> \startformula
> \startalignedcases
> \NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
> \NC \dm{\frac{\partial u}{\partial {\bi n}}}
> \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
> \stopalignedcases
> \stopformula
>
> In this example, it is OK to use \dm inside of \startformula … \stopformula.
> I am not sure that it is what Hans and Mikael want.
>
> Thanks,
>
> Best regards,
>
> Dalyoung
>
>

I think in this case it is better to use a mathsimplealign instead of a matrix.

\definemathsimplealign[pdeproblem][
left={\startmathfenced[cases]},
right=\stopmathfenced,
align={1:right,2:left,3:left},
strut=yes,
]

\definemathsimplealign[collected][
left={\startmathfenced[sesac]},
right=\stopmathfenced,
align={1:right,2:left,3:left},
strut=yes,
]

\starttext

\placeformula
\startformula
\startpdeproblem
\NC - \Delta u \NC = 0 \NC \qquad\text{in } \Omega \NR
\NC \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC
\qquad\text{on } \partial\Omega \NR
\stoppdeproblem
\stopformula

\placeformula
\startformula
\startcollected
\NC - \Delta u \NC = 0 \NC \qquad\text{in } \Omega \NR
\NC \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC
\qquad\text{on } \partial\Omega \NR
\stopcollected
\stopformula

\stoptext

Best, Mikael
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in math alignment

2022-11-02 Thread Otared Kavian via ntg-context
Dear Jeong,

Thanks for testing my example, and pointing to the solution using \dm (which I 
didn’t know…).
I think the correct behaviour of math alignments should avoid using additional 
commands such as \dm.

We’ll see what Hans and Mikael say.

Best regards: OK

> On 2 Nov 2022, at 12:53, Jeong Dal via ntg-context  wrote:
> 
> Dear Otared,
> 
>> 
>> I think there is an issue with the size of math fonts in \frac when used in 
>> math alignments, as it is is shown in the following example.
>> 
> 
> I confirm what you said.
> 
> However, if I use \dm{} instead of \displaystyle as following, then the 
> output is correct.
> 
> \placeformula
> \startformula
> \startalignedcases
> \NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
> \NC  \dm{\frac{\partial u}{\partial {\bi n}}}
>  \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
> \stopalignedcases
> \stopformula
> or this (with\type{\displaystyle} added)
> \placeformula 
> \startformula
> \startalignedcases
> \NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
> \NC  \dm{\frac{\partial u}{\partial {\bi n}}}
>  \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
> \stopalignedcases
> \stopformula
> 
> In this example, it is OK to use \dm inside of \startformula … \stopformula.
> I am not sure that it is what Hans and Mikael want.
> 
> Thanks,
> 
> 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 / 
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
> ___

Otared Kavian
e-mail: ota...@gmail.com
Phone: +33 6 88 26 70 95



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in math alignment

2022-11-02 Thread Jeong Dal via ntg-context
Dear Otared,

> 
> I think there is an issue with the size of math fonts in \frac when used in 
> math alignments, as it is is shown in the following example.
> 

I confirm what you said.

However, if I use \dm{} instead of \displaystyle as following, then the output 
is correct.

\placeformula
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \dm{\frac{\partial u}{\partial {\bi n}}}
 \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula
or this (with\type{\displaystyle} added)
\placeformula 
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \dm{\frac{\partial u}{\partial {\bi n}}}
 \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula

In this example, it is OK to use \dm inside of \startformula … \stopformula.
I am not sure that it is what Hans and Mikael want.

Thanks,

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 / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in math alignment

2022-11-02 Thread Otared Kavian via ntg-context
Hi Hans and Mikael,

I think there is an issue with the size of math fonts in \frac when used in 
math alignments, as it is is shown in the following example.


%% begin bug-mathalignment.tex
\definemathmatrix[alignedcases]
[align={1:right,2:left,3:left},
distance=3pt,
left={\left\{},
right={\right.},
style=\displaystyle]

\starttext
Consider this
\placeformula
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC \qquad\text{on 
}\, \partial\Omega. \NR
\stopalignedcases
\stopformula
or this (with\type{\displaystyle} added)
\placeformula 
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \displaystyle\frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC 
\qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula
Actually, one should have this
\startformula
\frac{\partial u}{\partial {\bi n}}  = V u + \phi  \qquad\text{on }\, 
\partial\Omega.
\stopformula
If one adds \type{\displaystyle} both to the numerator and denominator of 
\type{\frac}, the result is correct:
\placeformula 
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \frac{\displaystyle\partial u}{\displaystyle\partial {\bi n}} \NC = V u + 
\phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula

\stoptext
%% end bug-mathalignment.tex

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug (?) with \placefigure[right]

2022-08-16 Thread Wolfgang Schuster via ntg-context

Bruce Horrocks via ntg-context schrieb am 16.08.2022 um 18:11:

Things start to go awry after about 5 or 6 iterations, 12 shows it up clearly 
with three or so nearly blank (except for the subject) pages produced.

\setuppapersize [A5] [A5]
\starttext
\dorecurse{12}{
\subject{Some heading}
\placefigure[right] {} {\externalfigure[cow.pdf] [width=3cm]}
\input lorem
}
\stoptext

I actually want \placefigure[right,none] in my real doc but that also goes awry.
LMTX current version: 2022.08.05 11:44

My actual requirement is to have a set of short biographies, including a small 
'passport' photo, for each contributor to a book. So any suggestions on how to 
wrap text around the photo that avoids this issue would be welcome.


\setuppapersize [A5] [A5]

\starttext

\dorecurse{12}
  {\subject{Some heading}
   \starthanging[right]{\externalfigure[cow.pdf][width=3cm]}
   \samplefile{lorem}
   \stophanging}

\stoptext

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug (?) with \placefigure[right]

2022-08-16 Thread Bruce Horrocks via ntg-context
Things start to go awry after about 5 or 6 iterations, 12 shows it up clearly 
with three or so nearly blank (except for the subject) pages produced.

\setuppapersize [A5] [A5]
\starttext
\dorecurse{12}{
\subject{Some heading}
\placefigure[right] {} {\externalfigure[cow.pdf] [width=3cm]}
\input lorem
}
\stoptext

I actually want \placefigure[right,none] in my real doc but that also goes awry.
LMTX current version: 2022.08.05 11:44

My actual requirement is to have a set of short biographies, including a small 
'passport' photo, for each contributor to a book. So any suggestions on how to 
wrap text around the photo that avoids this issue would be welcome.
—
Bruce Horrocks
Hampshire, UK

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in startalign

2022-07-21 Thread Stefan Haller via ntg-context
Hi!

I (presumably) found a bug in the recent math changes of the latest
upload. If a cell of the startalign environment is empty, something
internally to the macro seems to be breaking.

Minimal example:

\starttext

\startformula
  \startalign
\NC   \NC a \NR
\NC b \NC c \NR
  \stopalign
\stopformula

\stoptext

Error: 
> tex error > tex error on line 5 in file ./test.tex: Missing number, treated 
> as zero
> 
> \23C>1
> 
> \math_next_in_eqalign \math_left_of_eqalign \mathbeginclass \csname 
> \??mathendclass \the \numexpr \c_math_eqalign_column -\plusone \relax 
> \endcsname
> \startforceddisplaymath \everycr \emptytoks
> 
> a
> 

Filling the empty cell with e.g. "d" makes it work. Using "\strut" or
"\quad" or similar also leads to the same error.

Best regards,
Stefan Haller
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in placeformula

2022-07-13 Thread Otared Kavian via ntg-context
Hi Mikael,

Thank you for your reply. For the time being I am not in a hurry to solve the 
issue with placeformula (when the numbers are on the right, there is no 
problem…).

Best regards: Otared

> On 12 Jul 2022, at 23:08, Mikael Sundqvist via ntg-context 
>  wrote:
> […]
> 
> Thanks for reporting! We must have missed this one while testing. It
> should be fixed.
> 
> If you for the moment can live without splitting, then this seems to
> give you the formula number where expected:
> 
> \placeformula
> \startformula[location=left,split=no,numberlocation=overlay]
> a^2 + b^2 = c^2.
> \stopformula
> 
> (or put the keys in \setupformula)
> 
> I hope it helps.
> 
> /Mikael


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in placeformula

2022-07-12 Thread Mikael Sundqvist via ntg-context
On Tue, Jul 12, 2022 at 6:34 PM Otared Kavian via ntg-context
 wrote:
>
> Dear Hans, dear Mikael,
>
> In my experiments with the new math engine, I noticed that there is an issue 
> with \placeformula when one sets the location of the numbers on the left: the 
> number is one line above the formula. Here is a minimal example:
>
> % begin bug-placeformula-left.tex
> \setupformulas[location=left]
>
> \starttext
>
> \placeformula
> \startformula
> a^2 + b^2 = c^2.
> \stopformula
>
> \stoptext
> % end bug-placeformula-left.tex
>
> Moreover, in some environments (such as enumerations) the bug destroys 
> completely the flow of text but I could not set up a minimal example to send 
> you.
>
> Best regards: Otared

Thanks for reporting! We must have missed this one while testing. It
should be fixed.

If you for the moment can live without splitting, then this seems to
give you the formula number where expected:

\placeformula
\startformula[location=left,split=no,numberlocation=overlay]
a^2 + b^2 = c^2.
\stopformula

(or put the keys in \setupformula)

I hope it helps.

/Mikael
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Bug in placeformula

2022-07-12 Thread Otared Kavian via ntg-context
Dear Hans, dear Mikael,

In my experiments with the new math engine, I noticed that there is an issue 
with \placeformula when one sets the location of the numbers on the left: the 
number is one line above the formula. Here is a minimal example:

% begin bug-placeformula-left.tex
\setupformulas[location=left]

\starttext

\placeformula
\startformula
a^2 + b^2 = c^2.
\stopformula

\stoptext
% end bug-placeformula-left.tex

Moreover, in some environments (such as enumerations) the bug destroys 
completely the flow of text but I could not set up a minimal example to send 
you.

Best regards: Otared


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Bug in counter

2022-07-04 Thread Wolfgang Schuster via ntg-context

Johann Birnick via ntg-context schrieb am 04.07.2022 um 18:29:

Hey there,

please consider:


\starttext
 
\defineenumeration[definition][text=Definition, alternative=serried]

\setupnumber[definition][way=bysection, numbersection=yes]


\setupenumeration
  [definition]
  [way=bysection,
   prefix=yes,
   prefixsegments=section]

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] Bug in counter

2022-07-04 Thread Johann Birnick via ntg-context
Hey there,

please consider:


\starttext

\defineenumeration[definition][text=Definition, alternative=serried]
\setupnumber[definition][way=bysection, numbersection=yes]

\section{My section 1}
\startdefinition
My fist definition
\stopdefinition

\section{My section 2}
\startdefinition
My second definition
\stopdefinition

\stoptext


It should number my definitions 1.1 and 2.1, but it doesn't. The prefix is
missing.

Any ideas?

Thank you and best regards,
Johann


test.pdf
Description: Adobe PDF document
___
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] [Bug] Two-column text: Larger top spacing in inline images

2022-06-27 Thread Max Chernoff via ntg-context

Not a bug, although it may be unexpected. It's a grid snapping thing. Try:

\def\example{%
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
\startMPcode draw fullcircle scaled 1cm; \stopMPcode\
Lorem ipsum. Lorem ipsum. Lorem ipsum.}

\starttext
\example
\startcolumns[grid=off]
\example
\stopcolumns
\stoptext

-- Max
___
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] [Bug] Two-column text: Larger top spacing in inline images

2022-06-26 Thread Marcin Ciura via ntg-context
Dear Hans and ConTeXt developers,

When you compile the following code with ConTeXt ver: 2021.10.28 10:19, you
will see that:
* in 1-column text the top spacing of the circle is normal,
* in 2-column text, the top spacing of the circle is too large.
Here is the link to the output PDF:
https://live.contextgarden.net/cgi-bin/result.cgi?id=7K5tLW

\def\example{%
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
Lorem ipsum. Lorem ipsum. Lorem ipsum.
\startMPcode draw fullcircle scaled 1cm; \stopMPcode\
Lorem ipsum. Lorem ipsum. Lorem ipsum.}

\starttext
\example
\startcolumns
\example
\stopcolumns
\stoptext

Best regards,
Marcin Ciura
___
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] Bug in alignment with LMTX version 2022.01.15 17:32

2022-01-18 Thread Otared Kavian via ntg-context
Hi Hans and Aditya,

Thanks for the clarification. Since for some documents I still use mkiv, I 
ended up using a definition which depends on whether one is using mkiv or lmtx, 
as in the example below. I wonder if there is a better solution.

Best regards: Otared
% begin bug-aligned-solved.tex
\doifmode{mkiv}{\definemathmatrix[alignedcases]
[align={right,left,left},
distance=3pt,
left={\left\{},
right={\right.},
style=\displaystyle]}

\doifmode{mkiv}{\definemathmatrix[matrix]
[align={right,left,left}]}

\doifmode{lmtx}{\definemathmatrix[alignedcases]
[align={1:right,2:left,3:left},
distance=3pt,
left={\left\{},
right={\right.},
style=\displaystyle]}

\doifmode{lmtx}{\definemathmatrix[matrix]
[align={1:right,2:left,3:left}]}

\starttext

\doifelsemode{lmtx}{We are using LMTX}{We are using mkiv}

\placeformula[eq:1]
\startformula
\startalignedcases
\NC  \partial_{t} u  \NC = \Delta u + \epsilon^{-2}f(u) \NC\qquad\text{in }\, 
\Omega\times (0,+\infty) \NR
\NC {\partial\phi(u) \over \partial{\bi n}} \NC = 0 \NC\qquad\text{on }\,  
\partial \Omega\times (0,+\infty)\NR
\NC u(x,0) \NC = u_{0}(x)\NC\qquad\text{in }\, \Omega.\NR
\stopalignedcases
\stopformula

\startformula
 \startmatrix
\NC ABC\NC ABC\NC ABC\NR
\NC AA \NC AA \NC AA \NR
  \stopmatrix
\stopformula
% end bug-aligned-solved.tex

> On 17 Jan 2022, at 23:53, Hans Hagen via ntg-context  
> wrote:
> 
> On 1/17/2022 11:35 PM, Aditya Mahajan via ntg-context wrote:
>> On Mon, 17 Jan 2022, Aditya Mahajan via ntg-context wrote:
>>> I confirm that this is a bug, which was not there in the version from mid 
>>> Dec.
>> Not a bug, but new interface. You need:
>> \definemathmatrix[matrix]
>>  [align={1:right,2:left,3:left}]
>> It is also possible to say: align={all:middle}. Combination of the two don't 
>> seem to work.
> basically we increment each element but a number sets the column so one can 
> go to a specific column; empty (whatever non number will start again at zero)
> 
> 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
> ___

___
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] Bug in alignment with LMTX version 2022.01.15 17:32

2022-01-17 Thread Hans Hagen via ntg-context

On 1/17/2022 11:35 PM, Aditya Mahajan via ntg-context wrote:

On Mon, 17 Jan 2022, Aditya Mahajan via ntg-context wrote:


I confirm that this is a bug, which was not there in the version from mid Dec.


Not a bug, but new interface. You need:

\definemathmatrix[matrix]
  [align={1:right,2:left,3:left}]

It is also possible to say: align={all:middle}. Combination of the two don't 
seem to work.
basically we increment each element but a number sets the column so one 
can go to a specific column; empty (whatever non number will start again 
at zero)


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] Bug in alignment with LMTX version 2022.01.15 17:32

2022-01-17 Thread Aditya Mahajan via ntg-context
On Mon, 17 Jan 2022, Aditya Mahajan via ntg-context wrote:

> I confirm that this is a bug, which was not there in the version from mid 
> Dec. 

Not a bug, but new interface. You need:

\definemathmatrix[matrix]
 [align={1:right,2:left,3:left}]

It is also possible to say: align={all:middle}. Combination of the two don't 
seem to work.

Aditya
___
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] Bug in alignment with LMTX version 2022.01.15 17:32

2022-01-17 Thread Aditya Mahajan via ntg-context
On Mon, 17 Jan 2022, Otared Kavian via ntg-context wrote:

> Hi Hans and Mikael,
> 
> While investigating the latest version regarding the math environment, I 
> found that the alignments are not correct.
> Here is an example:
> 
> % begin bug-alignment.tex
> \definemathmatrix[alignedcases]
>   [align={right,left,left},
>   distance=3pt,
>   left={\left\{},
>   right={\right.},
>   style=\displaystyle]
> \starttext
> 
> \placeformula[eq:1]
> \startformula
> \startalignedcases
> \NC  \partial_{t} u  \NC = \Delta u + \epsilon^{-2}f(u) \NC\qquad\text{in }\, 
> \Omega\times (0,+\infty) \NR
> \NC {\partial\phi(u) \over \partial{\bi n}} \NC = 0 \NC\qquad\text{on }\,  
> \partial \Omega\times (0,+\infty)\NR
> \NC u(x,0) \NC = u_{0}(x)\NC\qquad\text{in }\, \Omega.\NR
> \stopalignedcases
> \stopformula
> 
> \stoptext
> % end bug-alignment.tex

I confirm that this is a bug, which was not there in the version from mid Dec. 
It appears that the align key does not have any effect. Here's a simpler 
example:

\definemathmatrix[matrix]
[align={right,left,left}]
\starttext

\startformula
  \startmatrix
 \NC ABC\NC ABC\NC ABC\NR
 \NC AA \NC AA \NC AA \NR
   \stopmatrix
\stopformula

\stoptext



Aditya
___
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] Bug in alignment with LMTX version 2022.01.15 17:32

2022-01-17 Thread Otared Kavian via ntg-context
Hi Hans and Mikael,

While investigating the latest version regarding the math environment, I found 
that the alignments are not correct.
Here is an example:

% begin bug-alignment.tex
\definemathmatrix[alignedcases]
[align={right,left,left},
distance=3pt,
left={\left\{},
right={\right.},
style=\displaystyle]
\starttext

\placeformula[eq:1]
\startformula
\startalignedcases
\NC  \partial_{t} u  \NC = \Delta u + \epsilon^{-2}f(u) \NC\qquad\text{in }\, 
\Omega\times (0,+\infty) \NR
\NC {\partial\phi(u) \over \partial{\bi n}} \NC = 0 \NC\qquad\text{on }\,  
\partial \Omega\times (0,+\infty)\NR
\NC u(x,0) \NC = u_{0}(x)\NC\qquad\text{in }\, \Omega.\NR
\stopalignedcases
\stopformula

\stoptext
% end bug-alignment.tex

Best regards: Otared
___
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] Bug in mp-xbox.mpxl (circleit)

2021-12-24 Thread Hans Hagen via ntg-context

On 12/22/2021 2:33 PM, Jacob Kauffmann via ntg-context wrote:

Hi list,

I realized that circleit throws an error.
It works fine if I replace boxes_generic_declare by boxes_declare in line 244 
in mp-xbox.mpxl


we need two replacements, also in 313

thanks,

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
___


[NTG-context] Bug in mp-xbox.mpxl (circleit)

2021-12-22 Thread Jacob Kauffmann via ntg-context
Hi list,

I realized that circleit throws an error.
It works fine if I replace boxes_generic_declare by boxes_declare in line 244 
in mp-xbox.mpxl

rboxit is probably affected as well, but I did not test that.

MWE:
\startMPinclusions
input boxes;
\stopMPinclusions

\startMPpage
circleit.a(textext("$X$"));
drawboxed(a);
\startMPpage

The error (truncated) message:
metapost> initializing instance 'metafun:1' using format 'metafun' and 
method 'default'
metapost> loading 'metafun' as 'metafun.mpxl' using method 'default'
metapost> initializing number mode 'scaled'
metapost> trace > This is MPLIB for LuaMetaTeX, version 3.11, running 
in scaled mode.
metapost> trace >
metapost> trace > loading metafun for lmtx, including the plain 1.004 
base definitions
metapost> trace >
metafun > log >
metafun > log > error: Isolated expression
metafun > log >
metapost> trace >  boxes_generic_declare
metapost> trace >  (
metapost> trace >  circleit -> (TEXT3)-> 
begingroup.boxes_begin("boxes_the_circle","boxes_size_circle",(SUFFIX2),(TEXT3));boxes_generic_declare(pair)_n.n,_n.s,_n.e,_n.w;(SUFFIX2)e-(SUFFIX2)c=(SUFFIX2)c-(SUFFIX2)w=((SUFFIX2)dx,0)+0.5*(lrcorner.boxes_pic(SUFFIX2)-llcorner.boxes_pic(SUFFIX2));(SUFFIX2)n-(SUFFIX2)c=(SUFFIX2)c-(SUFFIX2)s=(0,(SUFFIX2)dy)+0.5*(ulcorner.boxes_pic(SUFFIX2)-llcorner.boxes_pic(SUFFIX2));boxes_end(boxes_clear_circle,(SUFFIX2));endgroup
metafun > log >
metafun > log > I couldn't find an '=' or ':=' after the expression 
that is shown above this
error message, so I guess I'll just ignore it and carry on.
metafun > log >
metapost> trace >  circleit.a(textext("$X$")); drawboxed(a); ;
metapost> trace >

Cheers,
Jacob


signature.asc
Description: Message signed with OpenPGP
___
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] Bug in lmt_arrow

2021-11-21 Thread Aditya Mahajan via ntg-context
On Sat, 20 Nov 2021, Hans Hagen wrote:
> On 11/20/2021 6:53 AM, Aditya Mahajan via ntg-context wrote:
> > On Mon, 15 Nov 2021, Hans Hagen wrote:
> > 
> > > On 11/15/2021 4:07 AM, Aditya Mahajan wrote:
> > > > On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:
> > > > 
> > > > > On Sun, 14 Nov 2021, Hans Hagen wrote:
> > > > > 
> > > > 
> > > > Spoke too soon. Now straight lines don't work:
> > > 
> > > new attempt (submitted to build)
> > 
> > The following still fails with ver 2021.11.19
> > 
> >  \starttext
> > 
> >  \startMPcode
> >newpath p;
> >ahfactor := 5;
> >p := origin .. (3cm,0);
> >draw lmt_arrow
> > [
> >   path = p,
> >   location = "percentage",
> >   percentage = 50,
> >   alternative = "curved",
> > ]
> > withpen pencircle scaled 1bp;
> >  \stopMPcode
> >  \stoptext
> > 
> > I get an error:
> > 
> > metafun > log >
> > metafun > log > error: This can't happen (division by zero)
> > metafun > log >
> bah, cycling between two failing tests ... new bin will be made on the farm in
> a moment

Thanks! Works perfectly now.

Aditya
___
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] Bug in lmt_arrow

2021-11-20 Thread Hans Hagen via ntg-context

On 11/20/2021 6:53 AM, Aditya Mahajan via ntg-context wrote:

On Mon, 15 Nov 2021, Hans Hagen wrote:


On 11/15/2021 4:07 AM, Aditya Mahajan wrote:

On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:


On Sun, 14 Nov 2021, Hans Hagen wrote:



Spoke too soon. Now straight lines don't work:


new attempt (submitted to build)


The following still fails with ver 2021.11.19

 \starttext

 \startMPcode
   newpath p;
   ahfactor := 5;
   p := origin .. (3cm,0);
   draw lmt_arrow
[
  path = p,
  location = "percentage",
  percentage = 50,
  alternative = "curved",
]
withpen pencircle scaled 1bp;
 \stopMPcode
 \stoptext

I get an error:

metafun > log >
metafun > log > error: This can't happen (division by zero)
metafun > log >
bah, cycling between two failing tests ... new bin will be made on the 
farm in a moment


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] Bug in lmt_arrow

2021-11-19 Thread Aditya Mahajan via ntg-context
On Mon, 15 Nov 2021, Hans Hagen wrote:

> On 11/15/2021 4:07 AM, Aditya Mahajan wrote:
> > On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:
> > 
> > > On Sun, 14 Nov 2021, Hans Hagen wrote:
> > > 
> > 
> > Spoke too soon. Now straight lines don't work:
> 
> new attempt (submitted to build)

The following still fails with ver 2021.11.19 

\starttext

\startMPcode
  newpath p;
  ahfactor := 5;
  p := origin .. (3cm,0);
  draw lmt_arrow
   [
 path = p, 
 location = "percentage",
 percentage = 50,
 alternative = "curved", 
   ]
   withpen pencircle scaled 1bp;
\stopMPcode
\stoptext

I get an error:

metafun > log >
metafun > log > error: This can't happen (division by zero)
metafun > log >

Thanks,
Aditya
___
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] Bug in lmt_arrow

2021-11-15 Thread Hans Hagen via ntg-context

On 11/15/2021 4:07 AM, Aditya Mahajan wrote:

On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:


On Sun, 14 Nov 2021, Hans Hagen wrote:


On 11/14/2021 4:33 AM, Aditya Mahajan via ntg-context wrote:

Hi,

There is a bug in lmt_arrow. If given a "non-cycle" path, lmt_arrow
completes the cycle.

  \starttext

  \startMPcode
newpath p;
ahfactor := 5;
p := origin .. (1cm, 1cm) .. (2cm, 0);
draw lmt_arrow
 [
   path = p,
   location = "percentage",
   percentage = 50,
   alternative = "curved",
 ]
 withpen pencircle scaled 1bp;
  \stopMPcode
  \stoptext

With 2021.11.11, I get the attached file. Note that lmt_arrow has drawn the
"cycle" version of the path, even though p does not have a cycle.

I have looked at the code and cannot figure out why this is happening.


it happens in the 'direct' variant (metapost.registerdirect) where a boolean
is passed as signal and that boolean then is also picked up by the (shared)
path injector as (old school) signal that a path is closed while it should
instead consutl the closed field in a path table (sounds more complex than it
is)

so in the end it is a nasty side effect of the fast inject code path (shared
function with different stack values; i'll probably have to ditch a "low level
backward compatibility feature no one uses anyway" some day)

i uploaded a fix that you can test when the bins are compiled at

https://build.contextgarden.net/#/waterfall?tags=c.luametatex

new bins then in:

https://dl.contextgarden.net/build/luametatex/

(fyi: in the mp code you see that the path p is 'get' from the lua end where
it got passed to by parameter)


Thanks! Works perfectly here.


Spoke too soon. Now straight lines don't work:


new attempt (submitted to build)


-
  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] Bug in lmt_arrow

2021-11-14 Thread Aditya Mahajan via ntg-context
On Sun, 14 Nov 2021, Aditya Mahajan via ntg-context wrote:

> On Sun, 14 Nov 2021, Hans Hagen wrote:
> 
> > On 11/14/2021 4:33 AM, Aditya Mahajan via ntg-context wrote:
> > > Hi,
> > > 
> > > There is a bug in lmt_arrow. If given a "non-cycle" path, lmt_arrow
> > > completes the cycle.
> > > 
> > >  \starttext
> > > 
> > >  \startMPcode
> > >newpath p;
> > >ahfactor := 5;
> > >p := origin .. (1cm, 1cm) .. (2cm, 0);
> > >draw lmt_arrow
> > > [
> > >   path = p,
> > >   location = "percentage",
> > >   percentage = 50,
> > >   alternative = "curved",
> > > ]
> > > withpen pencircle scaled 1bp;
> > >  \stopMPcode
> > >  \stoptext
> > > 
> > > With 2021.11.11, I get the attached file. Note that lmt_arrow has drawn 
> > > the
> > > "cycle" version of the path, even though p does not have a cycle.
> > > 
> > > I have looked at the code and cannot figure out why this is happening.
> > 
> > it happens in the 'direct' variant (metapost.registerdirect) where a boolean
> > is passed as signal and that boolean then is also picked up by the (shared)
> > path injector as (old school) signal that a path is closed while it should
> > instead consutl the closed field in a path table (sounds more complex than 
> > it
> > is)
> > 
> > so in the end it is a nasty side effect of the fast inject code path (shared
> > function with different stack values; i'll probably have to ditch a "low 
> > level
> > backward compatibility feature no one uses anyway" some day)
> > 
> > i uploaded a fix that you can test when the bins are compiled at
> > 
> > https://build.contextgarden.net/#/waterfall?tags=c.luametatex
> > 
> > new bins then in:
> > 
> > https://dl.contextgarden.net/build/luametatex/
> > 
> > (fyi: in the mp code you see that the path p is 'get' from the lua end where
> > it got passed to by parameter)
> 
> Thanks! Works perfectly here.

Spoke too soon. Now straight lines don't work:

\starttext

\startMPcode
  newpath p;
  ahfactor := 5;
  p := origin .. (3cm,0);
  draw lmt_arrow
   [
 path = p, 
 location = "percentage",
 percentage = 50,
 alternative = "curved", 
   ]
   withpen pencircle scaled 1bp;
\stopMPcode
\stoptext


gives

metapost> trace > This is MPLIB for LuaMetaTeX, version 3.11, running 
in scaled mode.
metapost> trace > 
metapost> trace > loading metafun for lmtx, including the plain 1.004 
base definitions
metapost> trace > 
metafun > log >
metafun > log > error: This can't happen (division by zero)
metafun > log >
metapost> trace >  arrowhead ->  -> 
begingroup.save.q,e,r;pair.e;e=point.length(EXPR2)of(EXPR2);path.q;q=gobble((EXPR2)shifted-e.cutafter.makepath(pencircle.scaled(2ahlength)))cuttings;if.ahvariant>0:path.r;r=gobble((EXPR2)shifted-e.cutafter.makepath(pencircle.scaled((1-ahdimple)*2ahlength)))cuttings;fi(q.rotated(ahangle/2)(ahangle/2)if.ahvariant=1:--point0of.r--elseif.ahvariant=2:...point0of.r...else:--fi.cycle)shifted.e.endgroup
metapost> trace >  endgroup
metapost> trace >  pushparameters "arrow" ; save a ; string a 
; a := getparameter "alternative" ; save l ; string l ; l := getparameter 
"location" ; save k ; string k ; k := getparameter "kind" ; save p ; path p ; p 
:= getparameter "path" ; interim ahvariant := if a = "dimpled" : 1 elseif a = 
"curved" : 2 else : 0 fi ; interim ahdimple := getparameter "dimple" ; interim 
ahscale := getparameter "scale" ; interim ahangle := getparameter "angle" ; 
interim ahlength := getparameter "length" ; if not getparameter "headonly" : 
draw p ; fi ; if hasparameter "pen" : if hasoption "pen" "auto" : ahlength := ( 
getparameter "penscale" ) * boundingradius ( currentpen ) ; else : ahlength := 
( getparameter "penscale" ) * boundingradius ( getparameterpen "pen" ) ; fi ; 
fi ; if k = "draw" : draw elseif k = "both" : filldraw else : fill fi if l = 
"middle" : midarrowhead p ; elseif l = "percentage" : arrowheadonpath ( p , ( 
getparameter "percentage" ) / 100 ) ; elseif l = "both" : arrowhead p ; if k = 
"draw" : draw elseif k = "both" : filldraw else : fill fi arrowhead reverse p ; 
else : arrowhead p ; fi ; popparameters ;
metapost> trace >  image -> (TEXT3)-> 
begingroup.save.currentpicture;picture.currentpicture;currentpicture:=nullpicture;(TEXT3);currentpicture.if.str(SUFFIX2)<>"":shifted(mfun_labxf(SUFFIX2)*lrcorner.p+mfun_labyf(SUFFIX2)*ulcorner.p+(1-mfun_labxf(SUFFIX2)-mfun_labyf(SUFFIX2))*llcorner.p)fi.endgroup
metapost> trace >  lmt_do_arrow -> -> 

Re: [NTG-context] Bug in lmt_arrow

2021-11-14 Thread Aditya Mahajan via ntg-context
On Sun, 14 Nov 2021, Hans Hagen wrote:

> On 11/14/2021 4:33 AM, Aditya Mahajan via ntg-context wrote:
> > Hi,
> > 
> > There is a bug in lmt_arrow. If given a "non-cycle" path, lmt_arrow
> > completes the cycle.
> > 
> >  \starttext
> > 
> >  \startMPcode
> >newpath p;
> >ahfactor := 5;
> >p := origin .. (1cm, 1cm) .. (2cm, 0);
> >draw lmt_arrow
> > [
> >   path = p,
> >   location = "percentage",
> >   percentage = 50,
> >   alternative = "curved",
> > ]
> > withpen pencircle scaled 1bp;
> >  \stopMPcode
> >  \stoptext
> > 
> > With 2021.11.11, I get the attached file. Note that lmt_arrow has drawn the
> > "cycle" version of the path, even though p does not have a cycle.
> > 
> > I have looked at the code and cannot figure out why this is happening.
> 
> it happens in the 'direct' variant (metapost.registerdirect) where a boolean
> is passed as signal and that boolean then is also picked up by the (shared)
> path injector as (old school) signal that a path is closed while it should
> instead consutl the closed field in a path table (sounds more complex than it
> is)
> 
> so in the end it is a nasty side effect of the fast inject code path (shared
> function with different stack values; i'll probably have to ditch a "low level
> backward compatibility feature no one uses anyway" some day)
> 
> i uploaded a fix that you can test when the bins are compiled at
> 
>   https://build.contextgarden.net/#/waterfall?tags=c.luametatex
> 
> new bins then in:
> 
>   https://dl.contextgarden.net/build/luametatex/
> 
> (fyi: in the mp code you see that the path p is 'get' from the lua end where
> it got passed to by parameter)

Thanks! Works perfectly here.

> (interesting that it didn't show up sooner, maybe most users have closed paths
> and/or most lmt_ features used closed paths)

I was reusing two year old code and took me a while to figure out why the 
output was suddenly wrong. 

Aditya
___
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] Bug in lmt_arrow

2021-11-14 Thread Hans Hagen via ntg-context

On 11/14/2021 4:33 AM, Aditya Mahajan via ntg-context wrote:

Hi,

There is a bug in lmt_arrow. If given a "non-cycle" path, lmt_arrow completes 
the cycle.

 \starttext

 \startMPcode
   newpath p;
   ahfactor := 5;
   p := origin .. (1cm, 1cm) .. (2cm, 0);
   draw lmt_arrow
[
  path = p,
  location = "percentage",
  percentage = 50,
  alternative = "curved",
]
withpen pencircle scaled 1bp;
 \stopMPcode
 \stoptext

With 2021.11.11, I get the attached file. Note that lmt_arrow has drawn the 
"cycle" version of the path, even though p does not have a cycle.

I have looked at the code and cannot figure out why this is happening.


it happens in the 'direct' variant (metapost.registerdirect) where a 
boolean is passed as signal and that boolean then is also picked up by 
the (shared) path injector as (old school) signal that a path is closed 
while it should instead consutl the closed field in a path table (sounds 
more complex than it is)


so in the end it is a nasty side effect of the fast inject code path 
(shared function with different stack values; i'll probably have to 
ditch a "low level backward compatibility feature no one uses anyway" 
some day)


i uploaded a fix that you can test when the bins are compiled at

https://build.contextgarden.net/#/waterfall?tags=c.luametatex

new bins then in:

https://dl.contextgarden.net/build/luametatex/

(fyi: in the mp code you see that the path p is 'get' from the lua end 
where it got passed to by parameter)


(interesting that it didn't show up sooner, maybe most users have closed 
paths and/or most lmt_ features used closed paths)


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
___


[NTG-context] Bug in lmt_arrow

2021-11-13 Thread Aditya Mahajan via ntg-context
Hi,

There is a bug in lmt_arrow. If given a "non-cycle" path, lmt_arrow completes 
the cycle. 

\starttext

\startMPcode
  newpath p;
  ahfactor := 5;
  p := origin .. (1cm, 1cm) .. (2cm, 0);
  draw lmt_arrow
   [
 path = p, 
 location = "percentage",
 percentage = 50,
 alternative = "curved", 
   ]
   withpen pencircle scaled 1bp;
\stopMPcode
\stoptext

With 2021.11.11, I get the attached file. Note that lmt_arrow has drawn the 
"cycle" version of the path, even though p does not have a cycle.

I have looked at the code and cannot figure out why this is happening.

Thanks,
Aditya

test.pdf
Description: Adobe PDF document
___
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] Bug with mathalignment and columns

2021-08-23 Thread Jack Hill via ntg-context

Hi,

When a mathalignment is started at the end of a multi-column page ConTeXt 
places it at the start of the previous second column instead of placing it on a 
new page. Here's my code to test:

\starttext \startcolumns[n=4]
\startluacode
lorum = "Lorum ipsum dolor sit amet. "
for i = 1, 98, 1 do
context(lorum)
end
\stopluacode

\startformula \startmathalignment[n=1]
\NC y = ax \NR

\NC a^2 + b^2 = c^2 \NR

\NC x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \NR
\stopmathalignment \stopformula
\stopcolumns \stoptext

Adding text after the formula seems to fix the issue, but that means I can't 
finish the page with a formula.
It seems that it always places the formula at the top of the second column, 
regardless of how many columns there are.
It also does this even if there are still empty columns (try changing 98 to 100 
in the for loop).

Jack
___
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] Bug in Luatex file handling?

2021-06-15 Thread Hans Hagen

On 6/15/2021 2:38 PM, Hans van der Meer wrote:
This I cannot explain. Opening a file directly from its full name in a 
string succeeds. But doing the same from a parameter transferred from 
ConteXt to Lua succeeds if the file is in one directory deeper but fails 
if the file is two directories deeper.

I suspect there is something not ok in LuaTeX.
The lines with  and  directly come from print statements 
inserted in the Lua code.


dr. Hans van der Meer

Open file in directory 1 and 2 levels deep - direct call succeeds
..io.open("events/hga-0372-345-62.xml","r")=>file (0x7fff97415f88)
..io.open("events/transcripten/hga-0372-345-62.xml","r")=>file 
(0x7fff97416020)


Idem but now from parameter filename transferred from ConTeXt into Lua:
Open file one level deeper succeeds (printed filename comes from the call):
 >>io.open(filename,"r") 
filename=events/hga-0372-1764-63.xml=>file (0x7fff974160b8)

Open file two levels deeper fails:
 >>io.open(filename,"r") 
filename=events/transcripten/hga-0372-1764-63.xml=>nil


Caller:
\def\FileExist#1{\cldcontext{hvdm.existfile([===[#1]===])}}
Lua code:
hvdm.existfile = function (filename)
-- The test code was inserted here --
local file = io.open(filename, "r")
if file then
file:close()
end
return file ~= nil and "true" or "false"
end


does lfs.isfile(name) work?

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


[NTG-context] Bug in Luatex file handling?

2021-06-15 Thread Hans van der Meer
This I cannot explain. Opening a file directly from its full name in a string 
succeeds. But doing the same from a parameter transferred from ConteXt to Lua 
succeeds if the file is in one directory deeper but fails if the file is two 
directories deeper.
I suspect there is something not ok in LuaTeX.
The lines with  and  directly come from print statements inserted in 
the Lua code.

dr. Hans van der Meer

Open file in directory 1 and 2 levels deep - direct call succeeds
..io.open("events/hga-0372-345-62.xml","r")=>file (0x7fff97415f88)
..io.open("events/transcripten/hga-0372-345-62.xml","r")=>file 
(0x7fff97416020)

Idem but now from parameter filename transferred from ConTeXt into Lua:
Open file one level deeper succeeds (printed filename comes from the call):
>>io.open(filename,"r") filename=events/hga-0372-1764-63.xml=>file 
>>(0x7fff974160b8)
Open file two levels deeper fails:
>>io.open(filename,"r") 
>>filename=events/transcripten/hga-0372-1764-63.xml=>nil

Caller:
\def\FileExist#1{\cldcontext{hvdm.existfile([===[#1]===])}}
Lua code:
hvdm.existfile = function (filename)
-- The test code was inserted here --
local file = io.open(filename, "r")
if file then
file:close()
end
return file ~= nil and "true" or "false"
end

___
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] Bug with OpenBSD 6.9 amd64?

2021-05-07 Thread Damien Thiriet
Hi Hans,


I tried to download once more, and it succeded.
I just wasn't lucky yesterday and installed at a time
when server wasn't responding.

I compiled a test file, everything went smooth.
Sorry for the noise and thanks for your time.

Best regards,

Damien Thiriet
___
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] Bug with OpenBSD 6.9 amd64?

2021-05-07 Thread Damien Thiriet
Hi Hans,

I should have looked earlier at the files. Looks like
I couldn't download the proper files.
Here is the content of mtxrun.lua:




404 Not Found

Not Found
The requested URL was not found on this server.


I will try to download once more, but looks like some links are missing.


Damien Thiriet 


On Thu, May 06, 2021 at 09:58:22PM +0200, Hans Hagen wrote:
> On 5/6/2021 9:03 PM, Damien Thiriet wrote:
> > Hi,
> > 
> > 
> > I have just upgraded my LMTX install to OpenBSD 6.9.
> > Unfortunately, my first context run aborted with this error message
> > 
> > /usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
> > `newline' unexpected
> > 
> > I tried mtxrun --generate and ended with alomst the same error message,
> > as I could have expected
> > /usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
> > `newline' unexpected
> > 
> > I wiped the cache, then suppressed it, didn't change anything.
> > Which informations might be helpful to solve this problem?
> i have no clue ... maybe googling for that message helps
> 
> 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
___


[NTG-context] Bug with OpenBSD 6.9 amd64?

2021-05-06 Thread Damien Thiriet
Hi,


I have just upgraded my LMTX install to OpenBSD 6.9.
Unfortunately, my first context run aborted with this error message

/usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
`newline' unexpected

I tried mtxrun --generate and ended with alomst the same error message,
as I could have expected
/usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
`newline' unexpected

I wiped the cache, then suppressed it, didn't change anything.
Which informations might be helpful to solve this problem?

Best regards,


Damien Thiriet 
___
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] Bug with OpenBSD 6.9 amd64?

2021-05-06 Thread Hans Hagen

On 5/6/2021 9:03 PM, Damien Thiriet wrote:

Hi,


I have just upgraded my LMTX install to OpenBSD 6.9.
Unfortunately, my first context run aborted with this error message

/usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
`newline' unexpected

I tried mtxrun --generate and ended with alomst the same error message,
as I could have expected
/usr/local/context/tex/texmf-openbsd6.9-amd64/bin/mtxrun[1]: syntax error: 
`newline' unexpected

I wiped the cache, then suppressed it, didn't change anything.
Which informations might be helpful to solve this problem?

i have no clue ... maybe googling for that message helps

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] Bug in \framed and \inframed

2021-05-06 Thread Aditya Mahajan
On Thu, 6 May 2021, Johann Birnick wrote:

> There is a bug with \framed and related commands: If this is the first object 
> in
> a line, a linebreak is inserted! See the following example:
> 
> 
> \starttext
>  
> 
> This \inframed{works} fine.
> 
> \inframed{But} this not.
> 
> \stoptext

https://wiki.contextgarden.net/FAQ#Why_is_there_a_line-break_in_the_output_after_some_commands.3F

Aditya
___
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] Bug in \framed and \inframed

2021-05-06 Thread Johann Birnick
There is a bug with \framed and related commands: If this is the first object in
a line, a linebreak is inserted! See the following example:


\starttext 

This \inframed{works} fine.

\inframed{But} this not.

\stoptext


Thank you,
Johann

___
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] Bug: missing Lua API in binaries

2021-04-23 Thread luigi scarso
On Sat, Apr 24, 2021 at 1:33 AM Sylvain Hubert 
wrote:

> You're right, I just checked the symbols of luatex and they contain all
> the APIs of lua 5.3.
> So I guess the problem is specific to luametatex and the latest context.
>
> > but in any case you should compile against the luatex headers, not the
> stock lua 5.3.6.
>
> Does luatex have dedicated headers different from the ones for stock lua?
>

There are some small differences, because we had to harmonize luajit and
lua .

-- 
luigi
___
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] Bug: missing Lua API in binaries

2021-04-23 Thread Sylvain Hubert
You're right, I just checked the symbols of luatex and they contain all the
APIs of lua 5.3.
So I guess the problem is specific to luametatex and the latest context.

> but in any case you should compile against the luatex headers, not the
stock lua 5.3.6.

Does luatex have dedicated headers different from the ones for stock lua?

On Fri, 23 Apr 2021 at 23:53, luigi scarso  wrote:

>
>
> On Fri, Apr 23, 2021 at 10:08 PM Sylvain Hubert 
> wrote:
>
>> Dear Devs,
>>
>> Sorry if this is not the best place for reporting bugs.
>>
>> I'm trying to use the lpeglabel library written in C and delivered as
>> lpeglabel.so.
>>
>> $ ls
>> testlabel.lua lpeglabel.so
>> $ cat testlabel.lua
>> require("lpeglabel")
>>
>> The ConTeXt binary cannot load the library because it lacks certain Lua
>> API:
>>
>> $ context --forcecld --permitloadlib testlabel.lua
>> ...
>> fatal lua error:
>> registered function call [1542]:
>> ...tx/tex/texmf-context/tex/context/base/mkiv/l-package.lua:348: error
>> loading module 'lpeglabel' from file './lpeglabel.so':
>> ./lpeglabel.so: undefined symbol: lua_gettop
>>
>>
> hm, lua_gettop  is a global symbol in latest luatex, it's not undefined...
>
>
>>
>> nor does LuaTeX:
>> $ luatex -luaonly testlabel.lua
>> error loading module 'lpeglabel' from file './lpeglabel.so':
>> ./lpeglabel.so: undefined symbol: lua_getiuservalue
>>
>>
> lua_getiuservalue is in lua 5.4 API, luatex is lua 5.3.6 API
> but in any case you should compile against the luatex headers, not the
> stock lua 5.3.6.
> I don't know lpeglabel, but luatex has the lpeg embedded and perhaps it
> can clash with the library.
>
> --
> luigi
>
> ___
> 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] Bug: missing Lua API in binaries

2021-04-23 Thread luigi scarso
On Fri, Apr 23, 2021 at 10:08 PM Sylvain Hubert 
wrote:

> Dear Devs,
>
> Sorry if this is not the best place for reporting bugs.
>
> I'm trying to use the lpeglabel library written in C and delivered as
> lpeglabel.so.
>
> $ ls
> testlabel.lua lpeglabel.so
> $ cat testlabel.lua
> require("lpeglabel")
>
> The ConTeXt binary cannot load the library because it lacks certain Lua
> API:
>
> $ context --forcecld --permitloadlib testlabel.lua
> ...
> fatal lua error:
> registered function call [1542]:
> ...tx/tex/texmf-context/tex/context/base/mkiv/l-package.lua:348: error
> loading module 'lpeglabel' from file './lpeglabel.so':
> ./lpeglabel.so: undefined symbol: lua_gettop
>
>
hm, lua_gettop  is a global symbol in latest luatex, it's not undefined...


>
> nor does LuaTeX:
> $ luatex -luaonly testlabel.lua
> error loading module 'lpeglabel' from file './lpeglabel.so':
> ./lpeglabel.so: undefined symbol: lua_getiuservalue
>
>
lua_getiuservalue is in lua 5.4 API, luatex is lua 5.3.6 API
but in any case you should compile against the luatex headers, not the
stock lua 5.3.6.
I don't know lpeglabel, but luatex has the lpeg embedded and perhaps it can
clash with the library.

-- 
luigi
___
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] Bug: missing Lua API in binaries

2021-04-23 Thread Sylvain Hubert
Dear Devs,

Sorry if this is not the best place for reporting bugs.

I'm trying to use the lpeglabel library written in C and delivered as
lpeglabel.so.

$ ls
testlabel.lua lpeglabel.so
$ cat testlabel.lua
require("lpeglabel")

The ConTeXt binary cannot load the library because it lacks certain Lua API:

$ context --forcecld --permitloadlib testlabel.lua
...
fatal lua error:
registered function call [1542]:
...tx/tex/texmf-context/tex/context/base/mkiv/l-package.lua:348: error
loading module 'lpeglabel' from file './lpeglabel.so':
./lpeglabel.so: undefined symbol: lua_gettop
...

nor does LuaTeX:
$ luatex -luaonly testlabel.lua
error loading module 'lpeglabel' from file './lpeglabel.so':
./lpeglabel.so: undefined symbol: lua_getiuservalue

It seems that lua_gettop and others are optimized out from the `context`
binary, while lua_getiuservalue and others are missing from `luatex`.

I'm not sure if it works but I would suggest adding `__attribute__
((used))` to the `LUA_API` macro if the binaries are compiled with gcc.

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] Bug in lmt_shade[...=...,...=...]

2021-03-16 Thread Hans Hagen

On 3/16/2021 6:19 PM, Keith McKay wrote:

Hi All

  I think a bug has appeared quite recently in the command, lmt_shade. A 
MWE below followed by the error output.

indeed, fixed in next upload

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


[NTG-context] Bug in lmt_shade[...=...,...=...]

2021-03-16 Thread Keith McKay

Hi All

 I think a bug has appeared quite recently in the command, lmt_shade. A 
MWE below followed by the error output.


Best Wishes

Keith McKay

\setuppapersize[A4,landscape][A4,landscape]

\starttext

\startMPpage

StartPage;

width := PaperWidth ; height := PaperHeight ; unit := cm ;

definecolor [ name = "MyColor1", r = 0.781, g = 0.5, b = 0.5 ] ;

definecolor [ name = "MyColor3", r = 1, g = 1, b = 0.7983 ] ;

draw lmt_shade [

path = unitsquare xscaled width yscaled height,

direction = "up",

alternative = "linear",

colors = { "MyColor1", "MyColor3" },

] ;

StopPage;

\stopMPpage

\stoptext

%%%Error Log%%%

system >

system > ConTeXt ver: 2021.03.13 11:22 LMTX fmt: 2021.3.16 int: 
english/english


system >

system > 'cont-new.mkxl' loaded 

metapost > initializing instance 'metafun:1' using format 'metafun' and 
method 'default'


metapost > loading 'metafun' as 'metafun.mpxl' using method 'default'

metapost > initializing number mode 'scaled'

metafun > log >

metafun > log > error: Not a cycle

metafun > log >

metapost > log > 

metapost > log > withprescript

metapost > log >  
...asparameter"vector":center_a:=point(getparameter"vector"1)of.mfun_shade_path;center_b:=point(getparameter"vector"2)of.mfun_shade_path;fi.fill.mfun_shade_path.withprescript


metapost > log > "sh_domain="...

metapost > log > 
image->begingroup.save.currentpicture;picture.currentpicture;currentpicture:=nullpicture;(TEXT3)


metapost > log > 
;currentpicture.if.str(SUFFIX2)<>"":shifted(mfun_labxf(SUFFIX2)*lrcorner.p+mfun_labyf(SUFFIX2)*ulcorn...


metapost > log > 
lmt_do_shade->...ve="circular":draw.fullcircle.scaled(radius_a)shifted.center_a.dashed.evenly;draw.fullcircle.scaled(factor*radius_b)shifted-center_b.dashed.evenly;fi.fi.popparameters;)


metapost > log > endgroup

metapost > log >  lmt_do_shade

metapost > log >

metapost > log > <*> ...3", r = 1, g = 1, b = 0.7983 ] ; draw lmt_shade 
[ path = unitsquare xscaled width yscaled height, direction = "up", 
alternative = "linear", colors = { "MyColor1", "MyColor3" }, ]


metafun > log >

metafun > log > That contour should have ended with '.. cycle' or '& 
cycle'. So I'll not change


anything just now.

metafun > log >

metapost > log > ; StopPage; ;

metapost > log >

___
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] bug in lmtx

2021-03-10 Thread Hans Hagen

On 3/9/2021 10:36 PM, Jano Kula wrote:

Hi Thomas,

On Tue, Mar 9, 2021 at 9:44 PM Wolfgang Schuster 
> wrote:


Thomas A. Schmitz schrieb am 09.03.2021 um 21:37:
 >
 > Test \hskip1em ἀβ

Test \hskip1em\relax ἀβ


This is likely the side effect of new implementation of glues in LMTX, 
where you can switch the order (\hskip 3pt minus 1pt plus 2pt) and do 
some other tricks. And there are more differences to /The TeXbook /as we 
know it, see luametatex.pdf.
indeed, but the disappearence is somewhat strange .. sode effect of utf 
(second byte is zero) .. fixed in next upload



-
  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] bug in lmtx

2021-03-09 Thread Jano Kula
Hi Thomas,

On Tue, Mar 9, 2021 at 9:44 PM Wolfgang Schuster <
wolfgang.schuster.li...@gmail.com> wrote:

> Thomas A. Schmitz schrieb am 09.03.2021 um 21:37:
> >
> > Test \hskip1em ἀβ
>
> Test \hskip1em\relax ἀβ
>

This is likely the side effect of new implementation of glues in LMTX,
where you can switch the order (\hskip 3pt minus 1pt plus 2pt) and do some
other tricks. And there are more differences to *The TeXbook *as we know
it, see luametatex.pdf.

Jano
___
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] bug in lmtx

2021-03-09 Thread Wolfgang Schuster

Thomas A. Schmitz schrieb am 09.03.2021 um 21:37:

Hi Hans,

I've found a very interesting bug in lmtx. The following MWE gives the 
expected result in mkiv; in lmtx, one character is missing. Perhaps 
you can figure out what's happening...


All best

Thomas

\setupbodyfont [gentium, 12pt]

\starttext

Test \hskip1em ἀβ


Test \hskip1em\relax ἀβ

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] bug in lmtx

2021-03-09 Thread Thomas A. Schmitz

Hi Hans,

I've found a very interesting bug in lmtx. The following MWE gives the 
expected result in mkiv; in lmtx, one character is missing. Perhaps you 
can figure out what's happening...


All best

Thomas

\setupbodyfont [gentium, 12pt]

\starttext

Test \hskip1em ἀβ

Test \hskip1em ἁβ

\stoptext
___
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] bug in \headnumber[section] in LMTX?

2021-03-07 Thread Pablo Rodriguez
On 3/7/21 1:21 PM, Wolfgang Schuster wrote:
> Pablo Rodriguez schrieb am 07.03.2021 um 10:49:
>> Dear list,
>>
>> I have the following sample:
>>
>>\starttext
>>  \section{Section}
>>\currentheadnumber\\
>
> You need \determineheadnumber[section] before you can use
> \currentheadnumber.

Many thanks for your reply, Wolfgang.

I didn’t know that, but it makes sense now.

>>\headnumbercontent\\
>
> You can use \headnumbercontent only when you create a new section layout
> with \defineheadalternative.

So, I didn’t make any sense in my sample.

Many thanks for your help again,

Pablo
--
http://www.ousia.tk
___
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] bug in \headnumber[section] in LMTX?

2021-03-07 Thread Wolfgang Schuster

Pablo Rodriguez schrieb am 07.03.2021 um 10:49:

Dear list,

I have the following sample:

   \starttext
 \section{Section}
   \currentheadnumber\\


You need \determineheadnumber[section] before you can use 
\currentheadnumber.



   \headnumbercontent\\


You can use \headnumbercontent only when you create a new section layout 
with \defineheadalternative.



   \headnumber[section]


It's a bug.


   \stoptext

In LMTX, \headnumber[section] triggers an error message about missing
number.

BTW, \currentheadnumber outputs 0 in both MkIV and LMTX. I think this
may be a bug.

Could anyone confirm both issues?


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] bug in \headnumber[section] in LMTX?

2021-03-07 Thread Pablo Rodriguez
Dear list,

I have the following sample:

  \starttext
\section{Section}
  \currentheadnumber\\
  \headnumbercontent\\
  \headnumber[section]
  \stoptext

In LMTX, \headnumber[section] triggers an error message about missing
number.

BTW, \currentheadnumber outputs 0 in both MkIV and LMTX. I think this
may be a bug.

Could anyone confirm both issues?

Many thanks for your help,

Pablo
--
http://www.ousia.tk
___
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] Bug report: \setupbackend corrupts bibliography rendering

2021-02-28 Thread Hans Hagen

On 2/28/2021 11:42 AM, a badin wrote:

% \setupbackend[export=example.xml,css=example.css]
\usebtxdataset[default][ref.bib]

\starttext
\cite[Arrow][Arrow]
\placelistofpublications
\stoptext

my ref.bib file:
@ARTICLE{Arrow,
   author = {Andrej Arrow},
   title = {The Font Name Mess},
   journal = {MAPS},
   year = {2010},
   volume = {40},
   pages = {2-8},
   keywords = {context},
}


fixed in next upload


-
  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] Bug report: \setupbackend corrupts bibliography rendering

2021-02-28 Thread a badin
Forgot to mention that my program is LuaTeX 2.08 20210220 + ConTeXt MkIV
2021.02.23 17:47
Also I like \setupbacked for what it does (export html/xml/css), I just
wasn't aware that it makes bibliography render strangely when outputting a
pdf.

On Sun, 28 Feb 2021 at 11:42, a badin  wrote:

> Dear gardeners,
>
> I'm new to ConTeXt and would like to share a possible bug with you.
>
> If I have the \setupbackend[export=example.xml,css=example.css] entry in
> my .tex file, then my bibliography renders in a strange way (text copied
> from pdf): 1 bfldcategoryarticle: [author: Andrej Arrow] [journal: MAPS]
> [keywords: context] [pages: 2-8] [title: The Font Name Mess] [volume: 40]
> [year: 2010]
>
> If I remove or comment that entry out, then the bibliography renders OK
> (copy from pdf): 1 A. Arrow, “The Font Name Mess”, *MAPS *40, 2-8, 2010.
>
> my .tex source is:
> % \setupbackend[export=example.xml,css=example.css]
> \usebtxdataset[default][ref.bib]
>
> \starttext
> \cite[Arrow][Arrow]
> \placelistofpublications
> \stoptext
>
> my ref.bib file:
> @ARTICLE{Arrow,
>   author = {Andrej Arrow},
>   title = {The Font Name Mess},
>   journal = {MAPS},
>   year = {2010},
>   volume = {40},
>   pages = {2-8},
>   keywords = {context},
> }
>
> Hope this helps,
> best,
> Andrej
> --
> Andrej Badin
> +31 6 82 23 50 33
>


-- 
Andrej Badin
+31 6 82 23 50 33
___
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] Bug report: \setupbackend corrupts bibliography rendering

2021-02-28 Thread a badin
Dear gardeners,

I'm new to ConTeXt and would like to share a possible bug with you.

If I have the \setupbackend[export=example.xml,css=example.css] entry in my
.tex file, then my bibliography renders in a strange way (text copied from
pdf): 1 bfldcategoryarticle: [author: Andrej Arrow] [journal: MAPS]
[keywords: context] [pages: 2-8] [title: The Font Name Mess] [volume: 40]
[year: 2010]

If I remove or comment that entry out, then the bibliography renders OK
(copy from pdf): 1 A. Arrow, “The Font Name Mess”, *MAPS *40, 2-8, 2010.

my .tex source is:
% \setupbackend[export=example.xml,css=example.css]
\usebtxdataset[default][ref.bib]

\starttext
\cite[Arrow][Arrow]
\placelistofpublications
\stoptext

my ref.bib file:
@ARTICLE{Arrow,
  author = {Andrej Arrow},
  title = {The Font Name Mess},
  journal = {MAPS},
  year = {2010},
  volume = {40},
  pages = {2-8},
  keywords = {context},
}

Hope this helps,
best,
Andrej
-- 
Andrej Badin
+31 6 82 23 50 33
___
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] Bug in generating the highlight colour in the rules-mkiv document

2020-12-06 Thread Ivan Čukić
Hi all,

When compiling the rules-mkiv.tex (context/sources/general/manuals/rules)
file, the highlight lines that use mp graphics are rendered in black instead of 
the colour defined by the file. This is visible on the three test sentences on 
the top of the third page "test test me and test or grep".

The versions I've tested where this is broken are:

context from the current TexLive 2020 distribution
mtx-context | ConTeXt Process Management 1.03
mtx-context |
mtx-context | main context file: texmf-dist/tex/context/base/mkiv/
context.mkiv
mtx-context | current version: 2020.03.10 14:44
mtx-context | main context file: texmf-dist/tex/context/base/mkiv/
context.mkxl
mtx-context | current version: 2020.03.10 14:44

context installed via first-setup.sh
mtx-context | ConTeXt Process Management 1.03
mtx-context |
mtx-context | main context file: tex/texmf-context/tex/context/base/mkiv/
context.mkiv
mtx-context | current version: 2020.01.30 14:13
mtx-context | main context file: tex/texmf-context/tex/context/base/mkiv/
context.mkxl
mtx-context | current version: 2020.01.30 14:13

context from TexLive 2019 distribution
mtx-context | ConTeXt Process Management 1.02
mtx-context |
mtx-context | main context file: texmf-dist/tex/context/base/mkiv/
context.mkiv
mtx-context | current version: 2019.03.21 21:39


The latest version I found to be working:

context installed with TexLive 2018
mtx-context | ConTeXt Process Management 1.02
mtx-context |
mtx-context | main context file: texmf-dist/tex/context/base/mkiv/
context.mkiv
mtx-context | current version: 2018.04.04 00:51


Cheers,
Ivan

-- 
dr Ivan Čukić
MATF, i...@math.rs, https://cukic.co, http://poincare.math.rs/~ivan
gpg key fingerprint: 8FE4 D32F 7061 EA9C 8232  07AE 01C6 CE2B FF04 1C12

___
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] Bug (?) using \externalfigure with layers and backgrounds

2020-12-03 Thread Jairo A. del Rio
Oh, I see. Nice, thank you a lot.

Jairo :)

El jue, 3 de dic. de 2020 a la(s) 12:19, Wolfgang Schuster (
wolfgang.schuster.li...@gmail.com) escribió:

> Jairo A. del Rio schrieb am 03.12.2020 um 18:14:
> > Hi everyone. The following
> >
> > \setuppagenumbering[state=stop]
> > \definelayer[mybg]
> > [
> > repeat=yes,
> > x=0mm, y=0mm,
> > width=\paperwidth, height=\paperheight,
> > ]
> >
> \setlayer[mybg]{\externalfigure[cow][width=\paperwidth,height=\paperheight]}
> > \setupbackgrounds[page][background=mybg,state=repeat]
> > \setupindenting[yes,small]
> > \startsetups background:default
> > \setupbackgrounds[page][background=mybg,state=repeat]
> > \stopsetups
> > \startsetups background:void
> > \setupbackgrounds[page][background=]
> > \stopsetups
> > \starttext
> > \dorecurse{7}{\input knuth}
> > \page
> > \setups[background:void]
> > \dorecurse{8}{\input tufte}
> > \page
> > \setups[background:default]
> > \dorecurse{7}{\input knuth}
> > \page
> > \stoptext
> >
> > works with a local image (say, if "cow" is in the same folder as the
> > main file), but it doesn't find sample images (cow, hacker, etc.). Is
> > that a bug or an intended result? Thank you in advance.
>
> This is normal, to load figures from the tex directory use
> \setupexternalfigures[location=default].
>
> More information are on the wiki:
> https://wiki.contextgarden.net/Command/setupexternalfigure
>
> 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] Bug (?) using \externalfigure with layers and backgrounds

2020-12-03 Thread Wolfgang Schuster

Jairo A. del Rio schrieb am 03.12.2020 um 18:14:

Hi everyone. The following

\setuppagenumbering[state=stop]
\definelayer[mybg]
[
repeat=yes,
x=0mm, y=0mm,
width=\paperwidth, height=\paperheight,
]
\setlayer[mybg]{\externalfigure[cow][width=\paperwidth,height=\paperheight]}
\setupbackgrounds[page][background=mybg,state=repeat]
\setupindenting[yes,small]
\startsetups background:default
\setupbackgrounds[page][background=mybg,state=repeat]
\stopsetups
\startsetups background:void
\setupbackgrounds[page][background=]
\stopsetups
\starttext
\dorecurse{7}{\input knuth}
\page
\setups[background:void]
\dorecurse{8}{\input tufte}
\page
\setups[background:default]
\dorecurse{7}{\input knuth}
\page
\stoptext

works with a local image (say, if "cow" is in the same folder as the 
main file), but it doesn't find sample images (cow, hacker, etc.). Is 
that a bug or an intended result? Thank you in advance.


This is normal, to load figures from the tex directory use 
\setupexternalfigures[location=default].


More information are on the wiki: 
https://wiki.contextgarden.net/Command/setupexternalfigure


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] Bug (?) using \externalfigure with layers and backgrounds

2020-12-03 Thread Jairo A. del Rio
Hi everyone. The following

\setuppagenumbering[state=stop]
\definelayer[mybg]
[
repeat=yes,
x=0mm, y=0mm,
width=\paperwidth, height=\paperheight,
]
\setlayer[mybg]{\externalfigure[cow][width=\paperwidth,height=\paperheight]}
\setupbackgrounds[page][background=mybg,state=repeat]
\setupindenting[yes,small]
\startsetups background:default
\setupbackgrounds[page][background=mybg,state=repeat]
\stopsetups
\startsetups background:void
\setupbackgrounds[page][background=]
\stopsetups
\starttext
\dorecurse{7}{\input knuth}
\page
\setups[background:void]
\dorecurse{8}{\input tufte}
\page
\setups[background:default]
\dorecurse{7}{\input knuth}
\page
\stoptext

works with a local image (say, if "cow" is in the same folder as the main
file), but it doesn't find sample images (cow, hacker, etc.). Is that a bug
or an intended result? Thank you in advance.

Best regards,

Jairo
___
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] Bug in lmtx bibliography (numerals in entry?)

2020-12-01 Thread Damien Thiriet
Hello,


My bibliography files compiles fine in mkiv, but hangs in lmtx
Here is the error message:

tex error   > tex error on line 30 in file ./Nation_rev_empire.mkiv:
Use of \btxshowentryinline doesn't match its definition




 \btxflushlisttext ...tyleandcolor \c!style \c!color
\ignorespaces \publ_fast_setup \plusfour \s!list \currentbtxcategory
\removeunwantedspaces
\endgroup
 \btxflushlisttext
\ifx \currentbtxcombis \empty \else \btxrenderingparameter
\c!separator \btxflushlistcombis \fi
 \btx:list:inject:text ...al \btxinteractivetext \ifx
\currentbtxinternal \empty #1\else \goto {#1} [\s!internal
(\currentbtxinternal )]\fi \else #1
\fi

 \btx_entry_inject ...onal \c_btx_list_texts
\dostarttagged \t!listtext \s!left \currentbtxbefore
\dostoptagged \fi \btx_entry_inject_list_text
\ifconditional \c_btx_list_pages \dostarttagged
\t!listpage \empty \btx_entry_inject_pages \dostoptagged
\fi \ifconditiona...

 \currentlistentrytitle \dostarttagged
\t!listcontent \empty \btx_list_reference_inject
\btx_entry_inject
\dostoptagged

 \22>:139>:paragraph ...\relax \fi \fi \fi
\begingroup \useliststyleandcolor \c!textstyle
\c!textcolor \setstrut \begstrut
\currentlistentrytitle
\endstrut \endgroup \ifconditional
\c_lists_has_page \ifconditional
\c_lists_show_page \nobreak \currentlistfiller
\beging...

[…]

If you say, e.g., '\def\a1{...}', then you must always put '1' after
'\a',
since control sequence names are made up of letters only. The macro here
has not
been followed by the required stuff, so I'm ignoring it.

I am using a custom biblio style, but the command \btxshowentryinline is
not directly called inside.
My ConTeXt version
mtx-context | ConTeXt Process Management 1.04
mtx-context |
mtx-context | main context file:
/usr/local/context/tex/texmf-context/tex/context/base/mkiv/context.mkiv
mtx-context | current version: 2020.11.19 11:28
mtx-context | main context file:
/usr/local/context/tex/texmf-context/tex/context/base/mkiv/context.mkxl
mtx-context | current version: 2020.11.19 11:28



AFAIU, it  means my entry shouldn’t have numbers, right? If so, this may
be a bug, since entry biblio files often have a number inside

Best regards,

Damien Thiriet 

___
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] Bug in lmtx bibliography (numerals in entry?)

2020-12-01 Thread Hans Hagen

On 12/1/2020 10:02 AM, Damien Thiriet wrote:

Hello,


My bibliography files compiles fine in mkiv, but hangs in lmtx
Here is the error message:

tex error   > tex error on line 30 in file ./Nation_rev_empire.mkiv:
Use of \btxshowentryinline doesn't match its definition

I forgot the \tolerant prefix in:

\permanent\tolerant\protected\def\btxshowentryinline[#1]#*[#2]%

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] Bug in overprint? (was: how to set overprint)

2020-11-16 Thread Andres Conrado Montoya
> What editors do you use?

I checked using Acrobat X on windows, PDFStudio 12 and Master PDF Editor on
linux

-- 
Andrés Conrado Montoya
Andi Kú
andresconr...@gmail.com
http://sesentaycuatro.com
http://messier87.com
http://chiquitico.org

Los fines no justifican los medios, porque la medida verdadera de nuestro
carácter está dada por los medios que estamos dispuestos a utilizar, no por
los fines que proclamamos.


“You develop an instant global consciousness, a people orientation, an
intense dissatisfaction with the state of the world, and a compulsion to do
something about it. From out there on the moon, international politics look
so petty. You want to grab a politician by the scruff of the neck and drag
him a quarter of a million miles out and say, ‘Look at that, you son of a
bitch.’” — Apollo 14 astronaut Edgar Mitchell
___
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] Bug in overprint? (was: how to set overprint)

2020-11-16 Thread Jano Kula
Hello Andrés!

On Wed, 11 Nov 2020 at 01:25, Andres Conrado Montoya Acosta <
ela...@chiquitico.org> wrote:

> may I ask someone, who understands knockout and overprint in the printing
>> press, to check test cases in the attached file from the test suite, if
>> overprint is working or not in Mark IV, please?
>>
>> Regards,
>> Jano
>>
>>
> Hi Jano, as far as I can check with my pdf editors, it seems overprinting
> is working. The black ink is printed above the blue, with no white reserve
> below it.
>

Sorry for the delay, I had to downsample the screenshots after the original
reply didn't get through (too big) and in the end remove them completely.

Thank you for checking. Looks like a bug in Acrobat (older version
11.0.23), not ConTeXt.
What editors do you use?

After your test I was digging deeper. When I disable black plate in *Preview:
Separations* it doesn't show an overprint, the room under the letters is
white (original problem). When I remove one overprint manually in
Illustrator, Acrobat shows the remaining overprints. I've found out later,
I could use *Profile: Color Warnings*, where all overprints are visible,
but I would rather see it in separated plates.

Hope this helps someone in the future, too.
Jano
___
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] Bug in matrices/alignment (LMTX)

2020-11-14 Thread Jairo A. del Rio
Nice. When I add empty braces ((}) the example works. Just curious: is that
a bug or expected behaviour?
Thank you a lot, Wolfgang.

Cordially,

Jairo :)

El sáb., 14 de nov. de 2020 a la(s) 14:34, Wolfgang Schuster (
wolfgang.schuster.li...@gmail.com) escribió:

> Jairo A. del Rio schrieb am 14.11.2020 um 20:10:
> > Hi everyone.
> > The following example works in ConTeXt MkIV but fails in ConTeXt LMTX:
> >
> > \def\rgeq{\vcenter{\rotate[rotation=270]{$>$}}}
> >
> > \definemathmatrix[void][left=,right=,simplecommand=voidmatrix]
> >
> > \starttext
> >
> > \startformula
> > \voidmatrix{%
> > G_{1,1}, >, G_{1,2}, >, G_{1,3}, >, G_{1,4}, \ldots, G_1;
> > \rgeq , , \rgeq , , \rgeq , , \rgeq , , \rgeq;
> > G_{2,1}, >, G_{2,2}, >, G_{2,3}, >, G_{2,4}, \ldots, G_2;
> > \rgeq , , \rgeq , , \rgeq , , \rgeq , , \rgeq;
> > G_{3,1}, >, G_{3,2}, >, G_{3,3}, >, G_{3,4}, \ldots, G_3;
> > , , , , , , , , \rgeq
> > }
> > \stopformula
> >
> > \stoptext
> >
> > In LMTX only the first column of rotated symbols appear.
>
> ConTeXt LMTX stopped at the first empty cell in a row.
>
> \starttext
>
> \def\docommand#1{(#1)}
>
> \processcommalist[a,b,c]\docommand
>
> \processcommalist[a,,c]\docommand
>
> \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
___


  1   2   3   4   5   6   7   8   9   10   >