ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* another font loading error
@ 2016-08-22 15:01 Mohammad Hossein Bateni
  2016-08-22 15:45 ` Wolfgang Schuster
  0 siblings, 1 reply; 3+ messages in thread
From: Mohammad Hossein Bateni @ 2016-08-22 15:01 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

Hello,

After the upgrade to latest beta (from 08.08 21:28), I cannot load many of
my Persian fonts (one uploaded here <http://mhbateni.com/context/bug-03/>
for testing).  It works on "current" without any issues but not on "beta".
Find an MWE as well as the error message below.  (I did test on a fresh
standalone version as well.)


\starttext
\definedfont[HMXNiloofar*arabic]
Salam
\stoptext


...ext/tex/texmf-context/tex/context/base/mkiv/font-ots.lua:3764: attempt
to index field '?' (a nil value)
stack traceback:
...ext/tex/texmf-context/tex/context/base/mkiv/font-ots.lua:3764: in
function 'action'
...ext/tex/texmf-context/tex/context/base/mkiv/font-con.lua:1407: in
function 'initializefeatures'
...ext/tex/texmf-context/tex/context/base/mkiv/font-otl.lua:263: in
function 'setfeatures'
...ext/tex/texmf-context/tex/context/base/mkiv/font-otl.lua:557: in
function 'otftotfm'
...ext/tex/texmf-context/tex/context/base/mkiv/font-otl.lua:566: in
function <...ext/tex/texmf-context/tex/context/base/mkiv/font-otl.lua:565>
(...tail calls...)
...ext/tex/texmf-context/tex/context/base/mkiv/font-def.lua:316: in
function 'loadfont'
...ext/tex/texmf-context/tex/context/base/mkiv/font-ctx.lua:492: in
function 'loadfont'
...ext/tex/texmf-context/tex/context/base/mkiv/font-def.lua:418: in
function 'read'
...ext/tex/texmf-context/tex/context/base/mkiv/font-ctx.lua:1175: in
function <...ext/tex/texmf-context/tex/context/base/mkiv/font-ctx.lua:1062>

1     \starttext
2 >>  \definedfont[HMXNiloofar*arabic]
3     Salam
4     \stoptext
5


Thanks!
—MHB

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: another font loading error
  2016-08-22 15:01 another font loading error Mohammad Hossein Bateni
@ 2016-08-22 15:45 ` Wolfgang Schuster
  2016-08-23  3:16   ` Mohammad Hossein Bateni
  0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Schuster @ 2016-08-22 15:45 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

> Mohammad Hossein Bateni <mailto:bateni@gmail.com>
> 22. August 2016 um 17:01
> Hello,
>
> After the upgrade to latest beta (from 08.08 21:28), I cannot load 
> many of my Persian fonts (one uploaded here 
> <http://mhbateni.com/context/bug-03/> for testing).  It works on 
> "current" without any issues but not on "beta".  Find an MWE as well 
> as the error message below.  (I did test on a fresh standalone version 
> as well.)
>
>
> \starttext
> \definedfont[HMXNiloofar*arabic]
> Salam
> \stoptext

When I change the value from the "hasspacekerns" variable (after 
deleting hm-xniloofar.tmc) in hm-xniloofar.tma from true to false the 
font is loaded without errors.


hm-xniloofar.tma (line 7147 ff):

  ["properties"]={
   ["hascolor"]=false,
   ["hasitalics"]=false,
   ["hasspacekerns"]=true,
  },


Wolfgang

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: another font loading error
  2016-08-22 15:45 ` Wolfgang Schuster
@ 2016-08-23  3:16   ` Mohammad Hossein Bateni
  0 siblings, 0 replies; 3+ messages in thread
From: Mohammad Hossein Bateni @ 2016-08-23  3:16 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

Wolfgang,

thanks for looking into it!

does this mean there is some bug in CONTEXT/LuaTeX font loading or
something wrong with the font?  i looked at the history on bitbucket mirror
and the problem seems to have started when we moved from 2016-08-11 14:00:00
 to 2016-08-15 22:45:00.

the offending lines in tex/context/base/mkiv/font-ots.lua (line 3762) has

kerns={
 [1705]={
  [2]={ 0, 0, -290, 0 },
 },
 [1707]={
  [2]={ 0, 0, -290, 0 },
 },
 [1711]={
  [2]={ 0, 0, -290, 0 },
 },
 [64400]={
  [2]={ 0, 0, -290, 0 },
 },
 [64404]={
  [2]={ 0, 0, -290, 0 },
 },
 [64469]={
  [2]={ 0, 0, -290, 0 },
 },
 [65243]={
  [2]={ 0, 0, -290, 0 },
 },
 [983071]={
  [2]={ 0, 0, -290, 0 },
 },
}

and with k, v = 1705, { 0, 0, -290, 0 }, we want to dereference v[1][3],
which leads to an error.  prior to this change, the code was looking up
v[3] (which would result in nil but no further dereferencing to cause an
error).  i checked that this part of the table was the same with the
previous version (from 08-08).

—MHB

On Mon, Aug 22, 2016 at 11:45 AM, Wolfgang Schuster <
schuster.wolfgang@gmail.com> wrote:

> Mohammad Hossein Bateni <bateni@gmail.com>
> 22. August 2016 um 17:01
> Hello,
>
> After the upgrade to latest beta (from 08.08 21:28), I cannot load many of
> my Persian fonts (one uploaded here <http://mhbateni.com/context/bug-03/>
> for testing).  It works on "current" without any issues but not on "beta".
> Find an MWE as well as the error message below.  (I did test on a fresh
> standalone version as well.)
>
>
> \starttext
> \definedfont[HMXNiloofar*arabic]
> Salam
> \stoptext
>
>
> When I change the value from the "hasspacekerns" variable (after deleting
> hm-xniloofar.tmc) in hm-xniloofar.tma from true to false the font is loaded
> without errors.
>
>
> hm-xniloofar.tma (line 7147 ff):
>
>  ["properties"]={
>   ["hascolor"]=false,
>   ["hasitalics"]=false,
>   ["hasspacekerns"]=true,
>  },
>
>
> 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://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
> ____________________________________________________________
> _______________________
>

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-08-23  3:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-22 15:01 another font loading error Mohammad Hossein Bateni
2016-08-22 15:45 ` Wolfgang Schuster
2016-08-23  3:16   ` Mohammad Hossein Bateni

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).