Re: [NTG-context] bug in \externalfigure
'context --make' gives an error: ! LuaTeX error .../context/tex/texmf-context/tex/context/base/back-pdf.lua:86: attempt to index global 'nodepool' (a nil value) stack traceback: .../context/tex/texmf-context/tex/context/base/back-pdf.lua:86: in function 'code' .../context/tex/texmf-context/tex/context/base/util-lua.lua:84: in function 'loadedluacode' .../context/tex/texmf-context/tex/context/base/luat-env.lua:104: in function 'luafilechunk' .../context/tex/texmf-context/tex/context/base/luat-cod.lua:45: in function 'registercode' [string "\directlua "]:1: in main chunk. system > tex > error on line 35 in file /usr/local/context/tex/texmf-context/tex/context/base/back-pdf.mkiv: LuaTeX error ... 25 \registerctxluafile{lpdf-wid}{1.001} 26 \registerctxluafile{lpdf-fld}{1.001} 27 \registerctxluafile{lpdf-mov}{1.001} 28 \registerctxluafile{lpdf-u3d}{1.001} 29 \registerctxluafile{lpdf-swf}{1.001} 30 \registerctxluafile{lpdf-tag}{1.001} 31 \registerctxluafile{lpdf-fmt}{1.001} 32 \registerctxluafile{lpdf-epd}{1.001} 33 \registerctxluafile{lpdf-epa}{1.001} 34 35 >> \registerctxluafile{back-pdf}{1.001} % some code will move to lpdf-* 36 37 \unprotect 38 39 %D We will minimize the number of calls to \PDF\ specific primitives 40 %D and delegate all management and injection of code to the backend. 41 %D 42 %D Here we initialize some internal quantities. We also protect them. 43 44 \pdfoutput 1 \let\pdfoutput \undefined \newcount\pdfoutput \pdfoutput 1 45 \pdfhorigin 1 true in \let\pdfhorigin\undefined \newdimen\pdfhorigin \pdfhorigin 1 true in \registerctxluafile ...ua.registercode("#1","#2")} l.35 \registerctxluafile{back-pdf}{1.001} % some code will move to lpdf-* ? Jannik Am 02.08.2013 um 21:58 schrieb Hans Hagen : > function nodepool.pdfsetmatrix(rx,sx,sy,ry,tx,ty) >local t = copy_node(pdfsetmatrix) >if type(rx) == "string" then >t.data = rx >else >t.data = formatters["%s %s %s %s"](rx or 1,sx or 0,sy or 0,ry or 1) -- > todo: tx ty >end >return t > 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
On 8/2/2013 9:49 PM, Jannik Voges wrote: I added the function in back-pdf.lua, but that doesn't fix the problem. Jannik Am 02.08.2013 um 21:35 schrieb Hans Hagen : On 8/2/2013 9:05 PM, Jannik Voges wrote: No problem. Pdf is attached. ok, i see the problem ... will try to fix it (cannot upload from where i am now) you can try this in back-pdf.lua: function nodepool.pdfsetmatrix(rx,sx,sy,ry,tx,ty) local t = copy_node(pdfsetmatrix) if type(rx) == "string" then setfield(t,"data",rx) else setfield(t,"data",formatters["%s %s %s %s"](rx or 1,sx or 0,sy or 0,ry or 1)) -- todo: tx ty end return t end function nodepool.pdfsetmatrix(rx,sx,sy,ry,tx,ty) local t = copy_node(pdfsetmatrix) if type(rx) == "string" then t.data = rx else t.data = formatters["%s %s %s %s"](rx or 1,sx or 0,sy or 0,ry or 1) -- todo: tx ty end return t end and remake the format - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
I added the function in back-pdf.lua, but that doesn't fix the problem. Jannik Am 02.08.2013 um 21:35 schrieb Hans Hagen : > On 8/2/2013 9:05 PM, Jannik Voges wrote: >> No problem. Pdf is attached. > > ok, i see the problem ... will try to fix it (cannot upload from where i am > now) > > you can try this in back-pdf.lua: > > function nodepool.pdfsetmatrix(rx,sx,sy,ry,tx,ty) >local t = copy_node(pdfsetmatrix) >if type(rx) == "string" then >setfield(t,"data",rx) >else >setfield(t,"data",formatters["%s %s %s %s"](rx or 1,sx or 0,sy or 0,ry > or 1)) -- todo: tx ty >end >return t > end > > > Hans > > - > Hans Hagen | PRAGMA ADE > Ridderstraat 27 | 8061 GH Hasselt | The Netherlands >tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com > | 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://tex.aanhet.net > archive : http://foundry.supelec.fr/projects/contextrev/ > 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
On 8/2/2013 9:05 PM, Jannik Voges wrote: No problem. Pdf is attached. ok, i see the problem ... will try to fix it (cannot upload from where i am now) you can try this in back-pdf.lua: function nodepool.pdfsetmatrix(rx,sx,sy,ry,tx,ty) local t = copy_node(pdfsetmatrix) if type(rx) == "string" then setfield(t,"data",rx) else setfield(t,"data",formatters["%s %s %s %s"](rx or 1,sx or 0,sy or 0,ry or 1)) -- todo: tx ty end return t end Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
No problem. Pdf is attached. Am 02.08.2013 um 20:55 schrieb Hans Hagen : > On 8/2/2013 8:36 PM, Jannik Voges wrote: > >> yes its a tricky bug. When you view the pdf with Preview under Mac OS X >> (10.8.4) you will see, that the second graphic and sentence isn't displayed. >> When you use evince (linux) the pdf is displayed correctly. I attache a >> zip-file with the pdf-file of the minimal example and a screenshot of the >> second page, when you view it with Apple's Preview (Preview.png) and evince >> (Evince.png). Peter Münster reported, that he can confirm the problem with >> acrobat reader (I have not installed Acrobat), so I think, there is a >> problem with the generated pdf. > > can you try with \nopdfcompression (that way we can look into the file) > > > - > Hans Hagen | PRAGMA ADE > Ridderstraat 27 | 8061 GH Hasselt | The Netherlands >tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com > | 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://tex.aanhet.net > archive : http://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > ___ Untitled.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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
On 8/2/2013 8:36 PM, Jannik Voges wrote: yes its a tricky bug. When you view the pdf with Preview under Mac OS X (10.8.4) you will see, that the second graphic and sentence isn't displayed. When you use evince (linux) the pdf is displayed correctly. I attache a zip-file with the pdf-file of the minimal example and a screenshot of the second page, when you view it with Apple's Preview (Preview.png) and evince (Evince.png). Peter Münster reported, that he can confirm the problem with acrobat reader (I have not installed Acrobat), so I think, there is a problem with the generated pdf. can you try with \nopdfcompression (that way we can look into the file) - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
· > On 8/2/2013 2:28 PM, Philipp Gesang wrote: > >· > > > >>On 2013–08–02 Philipp Gesang wrote: > >> > >>> https://phi-gamma.net/pdf/copypasta.pdf > >>> https://phi-gamma.net/files/copypasta.txt > >>> > >>>I definitely get from this > >>>one. > >> > >>Indeed. When I copy from your file I get those private Unicode > >>slots. When I run the example code from your OP, I get the correct > >>characters. I don't know what's the difference between those two > >>files. > > > >The PDF is what Context produces here with that code. > > > >>The LuaTeX version and ConTeXt version is the same. > >> > >>Creator:ConTeXt - 2013.08.01 01:31 > >>Producer: LuaTeX-0.76.0 > > > >There appears to be a difference between node and base mode > >depending on how the font is defined: > > > > \pdfcompresslevel0 > > > > \setupbodyfont [iwona] > > > > \definefontfeature [proto][onum=yes,smcp=yes,script=dflt,lang=dflt] > > \definefontfeature [withbase] [proto] [mode=base] > > \definefontfeature [withnode] [proto] [mode=node] > > > > \definefont [iwonab] [file:Iwona-Regular.otf*withbase] > > \definefont [iwonan] [file:Iwona-Regular.otf*withnode] > > > > \starttext > > \feature[<] > > base mode\par > > {\feature[!][withbase]0123456789abcdefghijklmnopqrstuvwxyz\par} > > {\iwonab 0123456789abcdefghijklmnopqrstuvwxyz} > > > > node mode\par > > {\feature[!][withnode]0123456789abcdefghijklmnopqrstuvwxyz\par} > > {\iwonan 0123456789abcdefghijklmnopqrstuvwxyz} > > \stoptext \endinput > > > >This gets me (through pdftotext): > > > > base mode > > > > 0123456789abcdefghijklmnopqrstuvwxyz > > node mode > > > > > > > >So base mode with \definefont works while node mode or the font > >from the typescript doesn’t. > > For such tests you need to compare all cases: > > nopdfcompression > > \setupbodyfont [iwona] > > \definefontfeature [withbaseone] [proto] [mode=base] > \definefontfeature [withnodeone] [proto] [mode=node] > \definefontfeature [withbasetwo] [proto] > [mode=base,onum=yes,smcp=yes,script=dflt,lang=dflt] > \definefontfeature [withnodetwo] [proto] > [mode=node,onum=yes,smcp=yes,script=dflt,lang=dflt] > > \definefont [iwonabone] [file:Iwona-Regular.otf*withbaseone] > \definefont [iwonanone] [file:Iwona-Regular.otf*withnodeone] > > \definefont [iwonabtwo] [file:Iwona-Regular.otf*withbasetwo] > \definefont [iwonantwo] [file:Iwona-Regular.otf*withnodetwo] > > \starttext > > test 1, both modes: > > {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > % test 2, base only: > > % {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par > % {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > % test 3, node only: > > % {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par > % {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > \stoptext > > i.e. get rid of potential interferences > > attached is what i get Hi all, I removed the entire tree (Hans suggested this in a private message) and started over with a clean install of the minimals. Now it works as expected, both with Context and Luatex-Fonts. Might have been caused by a leftover file that didn’t update. Thanks for your assistance and sorry for the noise! Best, Philipp pgp5GMHdJbGaK.pgp Description: PGP signature ___ 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
> Here’s a link to the diff between your PDF and my output: > > http://pastie.org/private/zwnesrug7wpy4ket6ppl1g I don't know where in ConTeXt's code the difference comes from, but in the PDF it is quite clear: Hans' file has a number of CMap entries that map glyph IDs to lowercase latin letters, which yours doesn't. See lines 153, 154, and similar ones. Arthur ___ 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
· > On 8/2/2013 2:28 PM, Philipp Gesang wrote: > >· > > > >>On 2013–08–02 Philipp Gesang wrote: > >> > >>> https://phi-gamma.net/pdf/copypasta.pdf > >>> https://phi-gamma.net/files/copypasta.txt > >>> > >>>I definitely get from this > >>>one. > >> > >>Indeed. When I copy from your file I get those private Unicode > >>slots. When I run the example code from your OP, I get the correct > >>characters. I don't know what's the difference between those two > >>files. > > > >The PDF is what Context produces here with that code. > > > >>The LuaTeX version and ConTeXt version is the same. > >> > >>Creator:ConTeXt - 2013.08.01 01:31 > >>Producer: LuaTeX-0.76.0 > > > >There appears to be a difference between node and base mode > >depending on how the font is defined: > > > > \pdfcompresslevel0 > > > > \setupbodyfont [iwona] > > > > \definefontfeature [proto][onum=yes,smcp=yes,script=dflt,lang=dflt] > > \definefontfeature [withbase] [proto] [mode=base] > > \definefontfeature [withnode] [proto] [mode=node] > > > > \definefont [iwonab] [file:Iwona-Regular.otf*withbase] > > \definefont [iwonan] [file:Iwona-Regular.otf*withnode] > > > > \starttext > > \feature[<] > > base mode\par > > {\feature[!][withbase]0123456789abcdefghijklmnopqrstuvwxyz\par} > > {\iwonab 0123456789abcdefghijklmnopqrstuvwxyz} > > > > node mode\par > > {\feature[!][withnode]0123456789abcdefghijklmnopqrstuvwxyz\par} > > {\iwonan 0123456789abcdefghijklmnopqrstuvwxyz} > > \stoptext \endinput > > > >This gets me (through pdftotext): > > > > base mode > > > > 0123456789abcdefghijklmnopqrstuvwxyz > > node mode > > > > > > > >So base mode with \definefont works while node mode or the font > >from the typescript doesn’t. > > For such tests you need to compare all cases: > > nopdfcompression > > \setupbodyfont [iwona] > > \definefontfeature [withbaseone] [proto] [mode=base] > \definefontfeature [withnodeone] [proto] [mode=node] > \definefontfeature [withbasetwo] [proto] > [mode=base,onum=yes,smcp=yes,script=dflt,lang=dflt] > \definefontfeature [withnodetwo] [proto] > [mode=node,onum=yes,smcp=yes,script=dflt,lang=dflt] > > \definefont [iwonabone] [file:Iwona-Regular.otf*withbaseone] > \definefont [iwonanone] [file:Iwona-Regular.otf*withnodeone] > > \definefont [iwonabtwo] [file:Iwona-Regular.otf*withbasetwo] > \definefont [iwonantwo] [file:Iwona-Regular.otf*withnodetwo] > > \starttext > > test 1, both modes: > > {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > % test 2, base only: > > % {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par > % {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > % test 3, node only: > > % {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par > % {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par > > \stoptext > > i.e. get rid of potential interferences > > attached is what i get Your PDF is flawless, but on my machine node mode produces the wrong output. (Also I run the luatex beta-0.76.0-2013040516 that comes with the minimals.) PDF: https://phi-gamma.net/pdf/copypasta-hh.pdf Here’s a link to the diff between your PDF and my output: http://pastie.org/private/zwnesrug7wpy4ket6ppl1g This bug is quite elusive; can you think of anything that this behavior might be a side-effect of? Philipp pgpuyg2SsYwGc.pgp Description: PGP signature ___ 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
On 8/2/2013 2:28 PM, Philipp Gesang wrote: · On 2013–08–02 Philipp Gesang wrote: https://phi-gamma.net/pdf/copypasta.pdf https://phi-gamma.net/files/copypasta.txt I definitely get from this one. Indeed. When I copy from your file I get those private Unicode slots. When I run the example code from your OP, I get the correct characters. I don't know what's the difference between those two files. The PDF is what Context produces here with that code. The LuaTeX version and ConTeXt version is the same. Creator:ConTeXt - 2013.08.01 01:31 Producer: LuaTeX-0.76.0 There appears to be a difference between node and base mode depending on how the font is defined: \pdfcompresslevel0 \setupbodyfont [iwona] \definefontfeature [proto][onum=yes,smcp=yes,script=dflt,lang=dflt] \definefontfeature [withbase] [proto] [mode=base] \definefontfeature [withnode] [proto] [mode=node] \definefont [iwonab] [file:Iwona-Regular.otf*withbase] \definefont [iwonan] [file:Iwona-Regular.otf*withnode] \starttext \feature[<] base mode\par {\feature[!][withbase]0123456789abcdefghijklmnopqrstuvwxyz\par} {\iwonab 0123456789abcdefghijklmnopqrstuvwxyz} node mode\par {\feature[!][withnode]0123456789abcdefghijklmnopqrstuvwxyz\par} {\iwonan 0123456789abcdefghijklmnopqrstuvwxyz} \stoptext \endinput This gets me (through pdftotext): base mode 0123456789abcdefghijklmnopqrstuvwxyz node mode So base mode with \definefont works while node mode or the font from the typescript doesn’t. For such tests you need to compare all cases: nopdfcompression \setupbodyfont [iwona] \definefontfeature [withbaseone] [proto] [mode=base] \definefontfeature [withnodeone] [proto] [mode=node] \definefontfeature [withbasetwo] [proto] [mode=base,onum=yes,smcp=yes,script=dflt,lang=dflt] \definefontfeature [withnodetwo] [proto] [mode=node,onum=yes,smcp=yes,script=dflt,lang=dflt] \definefont [iwonabone] [file:Iwona-Regular.otf*withbaseone] \definefont [iwonanone] [file:Iwona-Regular.otf*withnodeone] \definefont [iwonabtwo] [file:Iwona-Regular.otf*withbasetwo] \definefont [iwonantwo] [file:Iwona-Regular.otf*withnodetwo] \starttext test 1, both modes: {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par % test 2, base only: % {\iwonabone 0123456789abcdefghijklmnopqrstuvwxyz}\par % {\iwonabtwo 0123456789abcdefghijklmnopqrstuvwxyz}\par % test 3, node only: % {\iwonanone 0123456789abcdefghijklmnopqrstuvwxyz}\par % {\iwonantwo 0123456789abcdefghijklmnopqrstuvwxyz}\par \stoptext i.e. get rid of potential interferences attached is what i get -- - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl - oeps.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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] Appendix Numbering and TOC value
Thanks, Wolfgang. That was just what I needed. I appreciate the help. -Lance From: Wolfgang Schuster > I have a document with an appendix included: > > \setuplabeltext[appendix=APPENDIX~] > \starttext > \placecontent > \chapter{One} > \startappendices > \chapter{In Appendix} > \stopappendices > \stoptext > > I would like to have the table of contents show: > > Appendix A In Appendix > > But I get: > > A In Appendix > > How do I get the table of contents to show the heading ?Appendix? before A? You have to enable the label in the TOC with \setuplist[chapter][label=yes,width=7em]. 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
· > On 2013–08–02 Philipp Gesang wrote: > > > https://phi-gamma.net/pdf/copypasta.pdf > > https://phi-gamma.net/files/copypasta.txt > > > > I definitely get from this > > one. > > Indeed. When I copy from your file I get those private Unicode > slots. When I run the example code from your OP, I get the correct > characters. I don't know what's the difference between those two > files. The PDF is what Context produces here with that code. >The LuaTeX version and ConTeXt version is the same. > > Creator:ConTeXt - 2013.08.01 01:31 > Producer: LuaTeX-0.76.0 There appears to be a difference between node and base mode depending on how the font is defined: \pdfcompresslevel0 \setupbodyfont [iwona] \definefontfeature [proto][onum=yes,smcp=yes,script=dflt,lang=dflt] \definefontfeature [withbase] [proto] [mode=base] \definefontfeature [withnode] [proto] [mode=node] \definefont [iwonab] [file:Iwona-Regular.otf*withbase] \definefont [iwonan] [file:Iwona-Regular.otf*withnode] \starttext \feature[<] base mode\par {\feature[!][withbase]0123456789abcdefghijklmnopqrstuvwxyz\par} {\iwonab 0123456789abcdefghijklmnopqrstuvwxyz} node mode\par {\feature[!][withnode]0123456789abcdefghijklmnopqrstuvwxyz\par} {\iwonan 0123456789abcdefghijklmnopqrstuvwxyz} \stoptext \endinput This gets me (through pdftotext): base mode 0123456789abcdefghijklmnopqrstuvwxyz node mode So base mode with \definefont works while node mode or the font from the typescript doesn’t. Philipp pgpawqMokIqVP.pgp Description: PGP signature ___ 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
On 2013–08–02 Philipp Gesang wrote: > https://phi-gamma.net/pdf/copypasta.pdf > https://phi-gamma.net/files/copypasta.txt > > I definitely get from this > one. Indeed. When I copy from your file I get those private Unicode slots. When I run the example code from your OP, I get the correct characters. I don't know what's the difference between those two files. The LuaTeX version and ConTeXt version is the same. Creator:ConTeXt - 2013.08.01 01:31 Producer: LuaTeX-0.76.0 Marco signature.asc Description: Digital signature ___ 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 ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
· > On 8/2/2013 12:12 AM, Philipp Gesang wrote: > >· > > > >>On 2013–08–01 Philipp Gesang wrote: > >> > >>>· > >>> > I tested your example: no problem here on Mac OS X 10.8.4, with > either TeXShop, Adobe Redaer or Preview, with the latest beta > (ConTeXt ver: 2013.08.01 01:31 MKIV beta fmt: 2013.8.1 int: > english/english). > >>> > >>>x64 linux here, but it’s the same with the windows version in > >>>wine32. I get the bad output with okular (poppler), acroread, and > >>>mupdf, but strangely not with zathura (mupdf-based). > >> > >>Just to add to the list: > >> > >>x64 linux here, and it works with the following poppler based > >>viewers (zathura-poppler, xpdf, evince) I’m on a different machine now: the problem affects linux x86 and pdftotext as well. Also, in xpdf I get smallcaps copied as uppercase instead of lowercase. > i'm a bit puzzled > > >For those who want to test the git version, the commits are: > > > > last good: a61813ccdd4b7bcc81932317e1360fda6c79962d > > first bad: 6b2f7c5fd7a3e465f4e2662b1e5bd2c9d5cce8f8 > > > >Don’t forget to delete the cache. > > > >I suspect I found the troublesome changes. The problem vanishes > >if I revert this modification to font-map.lua: > > > > -local separator = S("_.") > > -local other = C((1 - separator)^1) > > -local ligsplitter = Ct(other * (separator * other)^0) > > +local ligseparator = P("_") > > +local varseparator = P(".") > > +local namesplitter = Ct(C((1 - ligseparator - varseparator)^1) * > > (ligseparator * C((1 - ligseparator - varseparator)^1))^0) > > > >and then further down: > > > > -local split = lpegmatch(ligsplitter,name) > > <...> > > +local split = lpegmatch(namesplitter,name) > > > >For convenience I repeat the link to the changeset: > > what do you revert from ... the + things are already in the file I’m quoting from the changeset, so the “-” lines indicate the good version. > > > > http://repo.or.cz/w/context.git/commitdiff/6b2f7c5fd7a3e465f4e2662b1e5bd2c9d5cce8f8 > > btw, this bit of code is evolving (was recently adapt to some border > case fonts that use their own rules) > > anyhow, on my win8 system the beta works with sumatra, okular and > acrobat (indeed one might need to wipe the cache, but i can > increment the version number) Weird. Here’s a PDF of the code I posted compiled with version “2013.08.01 01:31” and how pdftotext renders it: https://phi-gamma.net/pdf/copypasta.pdf https://phi-gamma.net/files/copypasta.txt I definitely get from this one. The characters are mapped from the private use area: <...> 30 beginbfchar <0409> <0416> <0418> <0423> <042A> <0435> <...> Can someone reproduce it at all? Philipp pgp6shzwsVCjZ.pgp Description: PGP signature ___ 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 ___
Re: [NTG-context] bug in \externalfigure
On 8/1/2013 5:19 PM, Jannik Voges wrote: You are right. I was a little bit confused, because I didn't know, that you have to add 'location=default' to get the sample files, so I thought, that might also be buggy. 'test' is a test-file (pdf, jpeg, ...) in the current directory (I have not mentioned that). In my second Mail I included the source files with 'test.pdf'. You can see the bug there or when you compile the example below. This time, the sample files are loaded correctly and you will see, that the second graphic and sentence are missing. \setupexternalfigures[location=default] \starttext \externalfigure[cow.pdf] \page This text will appear. \externalfigure[cow.pdf][width=10cm] This text will not appear. \stoptext i can't repeat your problem here .. two figures and two texts show up Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] copy&paste from pdf bug (smallcaps, text figures)
On 8/2/2013 12:12 AM, Philipp Gesang wrote: · On 2013–08–01 Philipp Gesang wrote: · I tested your example: no problem here on Mac OS X 10.8.4, with either TeXShop, Adobe Redaer or Preview, with the latest beta (ConTeXt ver: 2013.08.01 01:31 MKIV beta fmt: 2013.8.1 int: english/english). x64 linux here, but it’s the same with the windows version in wine32. I get the bad output with okular (poppler), acroread, and mupdf, but strangely not with zathura (mupdf-based). Just to add to the list: x64 linux here, and it works with the following poppler based viewers (zathura-poppler, xpdf, evince) i'm a bit puzzled For those who want to test the git version, the commits are: last good: a61813ccdd4b7bcc81932317e1360fda6c79962d first bad: 6b2f7c5fd7a3e465f4e2662b1e5bd2c9d5cce8f8 Don’t forget to delete the cache. I suspect I found the troublesome changes. The problem vanishes if I revert this modification to font-map.lua: -local separator = S("_.") -local other = C((1 - separator)^1) -local ligsplitter = Ct(other * (separator * other)^0) +local ligseparator = P("_") +local varseparator = P(".") +local namesplitter = Ct(C((1 - ligseparator - varseparator)^1) * (ligseparator * C((1 - ligseparator - varseparator)^1))^0) and then further down: -local split = lpegmatch(ligsplitter,name) <...> +local split = lpegmatch(namesplitter,name) For convenience I repeat the link to the changeset: what do you revert from ... the + things are already in the file http://repo.or.cz/w/context.git/commitdiff/6b2f7c5fd7a3e465f4e2662b1e5bd2c9d5cce8f8 btw, this bit of code is evolving (was recently adapt to some border case fonts that use their own rules) anyhow, on my win8 system the beta works with sumatra, okular and acrobat (indeed one might need to wipe the cache, but i can increment the version number) Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \externalfigure
On Thu, Aug 01 2013, Jannik Voges wrote: > Okay, a reader dependent bug/error. I used Preview (OS X 10.8.4). The second > figure (\externalfigure[cow.pdf][width=10cm]) and the following sentence > didn't appear. The same happens when you use height instead of width. Perhaps you could add this issue to the tracker: http://tracker.luatex.org/ -- Peter ___ 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 ___
Re: [NTG-context] Appendix Numbering and TOC value
Am 02.08.2013 um 01:28 schrieb "Lance Larsen" : > I have a document with an appendix included: > > \setuplabeltext[appendix=APPENDIX~] > \starttext > \placecontent > \chapter{One} > \startappendices > \chapter{In Appendix} > \stopappendices > \stoptext > > I would like to have the table of contents show: > > Appendix A In Appendix > > But I get: > > A In Appendix > > How do I get the table of contents to show the heading ‘Appendix’ before A? You have to enable the label in the TOC with \setuplist[chapter][label=yes,width=7em]. 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 ___