ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Mathias Schickel <msch@fa.uni-tuebingen.de>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Extensible arrows in ConTeXT
Date: Wed, 26 Jul 2017 13:31:38 +0200	[thread overview]
Message-ID: <DDC06269-5A18-4210-8437-EA229D14F311@fa.uni-tuebingen.de> (raw)
In-Reply-To: <fda638e7-7c74-bb9c-a791-d8e74f74dcd0@gmx.es>


[-- Attachment #1.1: Type: text/plain, Size: 3698 bytes --]


> Am 26.07.2017 um 08:07 schrieb Pablo Rodriguez <oinos@gmx.es>:
> 
> On 07/26/2017 07:20 AM, Mathias Schickel wrote:
>>> Am 26.07.2017 um 00:47 schrieb Hans Hagen:
>>> [...]>> you can patch this in that file and remake the format
>>> 
>>>   elseif kind == e_right then
>>>       local charlist = data[3].horiz_variants
>>>       if charlist then
>>>           local right = charlist[#charlist]
>>>           roffset = abs((right["start"] or 0) - (right["end"] or 0))
>>>       end
>> 
>> Hi Hans,
>> 
>> thank you for your quick answer! I am not sure How I can remake that
>> format. Can you tell me the command for that?
> 
> Hi Matthias,
> 
> as far as I can remember, the command is (I have used it in the past,
> but my memory is weak):
> 
>  context --make --all
> 

Hi Pablo,

thank you for advice! Unfortunately I still get the error

ext/tex/texmf-context/tex/context/base/mkiv/math-act.lua:514: attempt to get length of local 'charlist' (a nil value)
stack traceback:
	...ext/tex/texmf-context/tex/context/base/mkiv/math-act.lua:514: in function 'horizontalcode'
	...ext/tex/texmf-context/tex/context/base/mkiv/math-act.lua:541: in function <...ext/tex/texmf-context/tex/context/base/mkiv/math-act.lua:540>
	(...tail calls…)


I see two possible reasons for that:

Either the command „context --make --all“ is not the right one  (besides: How can I check if ConTeXt has remade the format?), or the code is not correctly changed. Maybe you can answer that, Hans.

From line 506 on the code of math-act.lua now is

if kind == e_left then
        local charlist = data[3].horiz_variants
        if charlist then												-- this is the line of the first error as the error code suggests
            local left = charlist[1]
            loffset = abs((left["start"] or 0) - (left["end"] or 0))
        end
    elseif kind == e_right then
       	local charlist = data[3].horiz_variants
       	if charlist then
           	local right = charlist[#charlist]
           	roffset = abs((right["start"] or 0) - (right["end"] or 0))
       	end
     elseif kind == e_horizontal then
        local charlist = data[3].horiz_variants
        if charlist then
            local left = charlist[1]
            local right = charlist[#charlist]
            loffset = abs((left ["start"] or 0) - (left ["end"] or 0))
            roffset = abs((right["start"] or 0) - (right["end"] or 0))
        end
    end
    return kind, loffset, roffset

Is that correct now?

In every case the error code mentioned another line of the same file:

math-act.lua:541: in function <...ext/tex/texmf-context/tex/context/base/mkiv/math-act.lua:540>
	(...tail calls…)

>> And can you maybe patch that in the distribution, too? (Else I fear
>> that I have to remake that format every time I will update the
>> distribution from contextgarden.)
> As far as I can tell, Hans will fix ConTeXt (he has done in the past).
> But he has provided the patch, so that you may  work until the next beta
> update.

Okay, that is very good!

> 
> Cheers,
> 
> Pablo


Best
Mathias


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


[-- Attachment #1.2: Type: text/html, Size: 7794 bytes --]

[-- Attachment #2: Type: text/plain, Size: 492 bytes --]

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

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

  reply	other threads:[~2017-07-26 11:31 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-14  9:33 Mathias Schickel
2017-07-14 15:15 ` Mathias Schickel
2017-07-14 19:25 ` Alan Braslau
2017-07-21 10:31   ` Mathias Schickel
2017-07-22 20:34     ` Alan Braslau
2017-07-25 22:01       ` Mathias Schickel
2017-07-25 22:47         ` Hans Hagen
2017-07-26  5:20           ` Mathias Schickel
2017-07-26  6:07             ` Pablo Rodriguez
2017-07-26 11:31               ` Mathias Schickel [this message]
2017-07-26 15:36                 ` Pablo Rodriguez
2017-07-27 16:02                   ` Mathias Schickel
2017-07-27 16:33                     ` Hans Hagen
2017-07-29  9:41                       ` Mathias Schickel

Reply instructions:

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

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

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

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

  git send-email \
    --in-reply-to=DDC06269-5A18-4210-8437-EA229D14F311@fa.uni-tuebingen.de \
    --to=msch@fa.uni-tuebingen.de \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

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

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