Re: [NTG-context] Space after Round bracket before Punctuation
Thank you Hans, this was very helpful. I found that the following worked (apart from in two or three cases): \startluacode fonts.handlers.otf.addfeature { name = "iebpkerns", type = "kern", data = { [")"] = { [","] = -80, ["."] = -80, [":"] = -80, [";"] = -80, [")"] = -80, ["]"] = -80, }, ["]"] = { [","] = -80, ["."] = -80, [":"] = -80, [";"] = -80, [")"] = -80, ["]"] = -80, }, }, } \stopluacode Best, Richard -Original Message- From: Hans Hagen To: mailing list for ConTeXt users , Richard Mahoney | Indica et Buddhica Subject: Re: [NTG-context] Space after Round bracket before Punctuation Date: Thu, 9 Jul 2020 12:21:02 +0200 Mailer: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 X-Spam-Score: 0.0 On 7/9/2020 11:59 AM, Richard Mahoney | Indica et Buddhica wrote: > I'm typesetting some proceedings which include a good number of > roundbrackets followed by punctuation. This often occurs in the body > of thetext, but also in the hand coded bibliographies, e.g.: > ) plus . , ; : > The trouble is that excessive space is often introduced between > thebracket and the punctuation. I can control the excessive space > thatsometimes occurs between ) and . by using )\periods[1], although > thisruins the protrusion if it occurs at the end of a line. > Does anyone know how I might be able to somehow "tie" ) to . , ; : > sothat the distance remains reasonable, and so that protrusion > stillworks? you first have to make an MWE that demonstrates how protrusion works here ... then we can see how we can best deal with it Anyway, often tricks for this can be found in the test suite of font manual(s) ... here is a variant ... \startluacode fonts.handlers.otf.addfeature { name = "mykerns", type = "kern", data = { [")"] = { [","] = -300, ["."] = -300, [":"] = -250, [";"] = -250, [")"] = -100, }, }, }\stopluacode \definefontfeature[default][default][mykerns=true] \setupbodyfont [dejavu,12pt] \startTEXpage[offset=10pt] whatever), whatever): whatever) ; whatever). whatever))\stopTEXpage Hans --- -- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlandstel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl - -- Richard Mahoney | Indica et Buddhica Littledene Bay Road Oxford NZT: +64 3 312 1699 M: +64 210 640 216IM: @rmahoney https://t.me/rmahoneyrmaho...@indica-et-buddhica.org https://indica-et-buddhica.org/ ___ 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] help with confusion re chapter number
On Fri, 10 Jul 2020, jbf wrote: Hi, I wonder if someone could lead me out of my current confusion. In a test example with MWE as follows, I get exactly what I want: \setuplabeltext [en] [chapter=~] \define[2]\MyChapter {\framed[frame=off,width=broad,align=middle]{#1\blank[1cm]#2}} \setuphead [chapter] [command=\MyChapter] \chapter{Chapter title} which gives me a chapter number (without the word 'Chapter') and 1cm below it the chapter title, e.g.: 1 My chapter title But when I transfer this to the actual tex file I am working with, I lose the chapter number. Admittedly, there is more complication to my setup in the 'real' example, and maybe that's where I've gone wrong, but why am I losing the chapter number? \define[2]\MyChapter {\framed[frame=off,width=broad,align=middle,number=yes]{#1\blank[1cm]#2}} \setuphead [chapter][header=empty,alternative=middle,style=bold,numbercommand=\groupedcommand{}{\blank[2cm]},after={\blank[3cm]},command=\MyChapter] What happens if you remove `numbercommand=...,`? 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] help with confusion re chapter number
Hi, I wonder if someone could lead me out of my current confusion. In a test example with MWE as follows, I get exactly what I want: \setuplabeltext [en] [chapter=~] \define[2]\MyChapter {\framed[frame=off,width=broad,align=middle]{#1\blank[1cm]#2}} \setuphead [chapter] [command=\MyChapter] \chapter{Chapter title} which gives me a chapter number (without the word 'Chapter') and 1cm below it the chapter title, e.g.: 1 My chapter title But when I transfer this to the actual tex file I am working with, I lose the chapter number. Admittedly, there is more complication to my setup in the 'real' example, and maybe that's where I've gone wrong, but why am I losing the chapter number? \define[2]\MyChapter {\framed[frame=off,width=broad,align=middle,number=yes]{#1\blank[1cm]#2}} \setuphead [chapter][header=empty,alternative=middle,style=bold,numbercommand=\groupedcommand{}{\blank[2cm]},after={\blank[3cm]},command=\MyChapter] Julian ___ 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] lmtx install fails to run
On 7/9/2020 5:25 PM, Hans van der Meer wrote: After doing just now the standard: sh install.sh context will not run. Why, because in the past it worked without a hitch. Now there is no format cont-en. Did all sorts of the ususal things like remove the current cache, context --make en, etc. I guess the error is in the missing file. An overfsight somewhere? Below the last part of the context --make en run. Mark the lang-mis.mkxl is not found line. met vriendelijke groet dr. Hans van der Meer resolvers > lua > loading file '/Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/node-bck.lua' succeeded close source > level 1, order 83, name 'node-bck.mkiv' open source > level 1, order 84, name 'pack-cut.mkiv' close source > level 1, order 84, name 'pack-cut.mkiv' runtime error : input file 'lang-mis.mkxl' is not found, quitting resolvers | formats | resolvers | formats | binary path : /Users/hansm/TeX/context-lmtx/tex/texmf-osx-64/bin resolvers | formats | format path : /Users/hansm/TeX/context-lmtx/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex resolvers | formats | luatex engine : luametatex resolvers | formats | lua startup file : /Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/luat-cod.lua resolvers | formats | context file : /Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/cont-en.mkxl resolvers | formats | run time : 0.499 seconds resolvers | formats | return value : error resolvers | formats | system | total runtime: 0.500 seconds of 0.604 seconds hm, is that file on yoru system? what if you update again? 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] lmtx install fails to run
After doing just now the standard: sh install.sh context will not run. Why, because in the past it worked without a hitch. Now there is no format cont-en. Did all sorts of the ususal things like remove the current cache, context --make en, etc. I guess the error is in the missing file. An overfsight somewhere? Below the last part of the context --make en run. Mark the lang-mis.mkxl is not found line. met vriendelijke groet dr. Hans van der Meer resolvers > lua > loading file '/Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/node-bck.lua' succeeded close source> level 1, order 83, name 'node-bck.mkiv' open source > level 1, order 84, name 'pack-cut.mkiv' close source> level 1, order 84, name 'pack-cut.mkiv' runtime error : input file 'lang-mis.mkxl' is not found, quitting resolvers | formats | resolvers | formats | binary path : /Users/hansm/TeX/context-lmtx/tex/texmf-osx-64/bin resolvers | formats | format path : /Users/hansm/TeX/context-lmtx/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex resolvers | formats | luatex engine: luametatex resolvers | formats | lua startup file : /Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/luat-cod.lua resolvers | formats | context file : /Users/hansm/TeX/context-lmtx/tex/texmf-context/tex/context/base/mkiv/cont-en.mkxl resolvers | formats | run time : 0.499 seconds resolvers | formats | return value : error resolvers | formats | system | total runtime: 0.500 seconds of 0.604 seconds ___ 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] Space after Round bracket before Punctuation
I'm typesetting some proceedings which include a good number of round brackets followed by punctuation. This often occurs in the body of the text, but also in the hand coded bibliographies, e.g.: ) plus . , ; : The trouble is that excessive space is often introduced between the bracket and the punctuation. I can control the excessive space that sometimes occurs between ) and . by using )\periods[1], although this ruins the protrusion if it occurs at the end of a line. Does anyone know how I might be able to somehow "tie" ) to . , ; : so that the distance remains reasonable, and so that protrusion still works? Best, Richard -- Richard Mahoney | Indica et Buddhica Littledene Bay Road Oxford NZT: +64 3 312 1699 M: +64 210 640 216IM: @rmahoney https://t.me/rmahoneyrmaho...@indica-et-buddhica.org https://indica-et-buddhica.org/ ___ 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] Minimum METAPOST code produces problematic PDF
The minimum is a relative one: It is page 650 in the (normative) Annex C Implementation Limits for PDF readers and writers: Additionally, conforming writers should adhere to the following constraints, and conforming readers should accommodate PDF files that obey the constraints. The minimum page size should be 3 by 3 units in default user space; the maximum should be 14,400 by 14,400 units. In versions of PDF earlier than 1.6, the size of the default user space unit was fixed at 1⁄72 inch, yielding a minimum of approximately 0.04 by 0.04 inch and a maximum of 200 by 200 inches. Beginning with PDF 1.6, the size of the unit may be set on a page-by-page basis; the default remains at 1/ 72 inch. In other words: you need to change the unit per page so the page is at least 3x3 and maximally 14400x14400. > On 9 Jul 2020, at 12:10, Hans Hagen wrote: > > On 7/9/2020 9:08 AM, Taco Hoekwater wrote: >>> On 9 Jul 2020, at 08:32, Hans Hagen wrote: >>> >>> On 7/8/2020 8:14 PM, Gerben Wierda wrote: I found out this in the PDF spec: The minimum page size should be 3 by 3 units in default user space; the >>> >>> I never noticed that ... what section/paragraph in the spec? >> It’s in the implementation limits for Acrobat, not in the normative section. > > Great. That used to be 1 bp so now it's more. As it happens, we do have a > check for this in context so we can adapt it ... but, as this 3 bp is kind of > arbitrary and because 3 bp becomes a float and thereby ends up slightly less > than the integer 3 we can best play safe and revert to the usual tex joke, so > i now set the minumum to > > \luaexpr{math.pi}\onebasepoint > > which then gives: > > /MediaBox [ 0 0 3.141539539 3.141539539 ] because after all, any rediculous > minimum will do and that way a user can still figure out that it's a value > set by context. > > 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] Space after Round bracket before Punctuation
On 7/9/2020 11:59 AM, Richard Mahoney | Indica et Buddhica wrote: I'm typesetting some proceedings which include a good number of round brackets followed by punctuation. This often occurs in the body of the text, but also in the hand coded bibliographies, e.g.: ) plus . , ; : The trouble is that excessive space is often introduced between the bracket and the punctuation. I can control the excessive space that sometimes occurs between ) and . by using )\periods[1], although this ruins the protrusion if it occurs at the end of a line. Does anyone know how I might be able to somehow "tie" ) to . , ; : so that the distance remains reasonable, and so that protrusion still works? you first have to make an MWE that demonstrates how protrusion works here ... then we can see how we can best deal with it Anyway, often tricks for this can be found in the test suite of font manual(s) ... here is a variant ... \startluacode fonts.handlers.otf.addfeature { name = "mykerns", type = "kern", data = { [")"] = { [","] = -300, ["."] = -300, [":"] = -250, [";"] = -250, [")"] = -100, }, }, } \stopluacode \definefontfeature[default][default][mykerns=true] \setupbodyfont [dejavu,12pt] \startTEXpage[offset=10pt] whatever), whatever): whatever); whatever). whatever)) \stopTEXpage 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] Minimum METAPOST code produces problematic PDF
On 7/9/2020 9:08 AM, Taco Hoekwater wrote: On 9 Jul 2020, at 08:32, Hans Hagen wrote: On 7/8/2020 8:14 PM, Gerben Wierda wrote: I found out this in the PDF spec: The minimum page size should be 3 by 3 units in default user space; the I never noticed that ... what section/paragraph in the spec? It’s in the implementation limits for Acrobat, not in the normative section. Great. That used to be 1 bp so now it's more. As it happens, we do have a check for this in context so we can adapt it ... but, as this 3 bp is kind of arbitrary and because 3 bp becomes a float and thereby ends up slightly less than the integer 3 we can best play safe and revert to the usual tex joke, so i now set the minumum to \luaexpr{math.pi}\onebasepoint which then gives: /MediaBox [ 0 0 3.141539539 3.141539539 ] because after all, any rediculous minimum will do and that way a user can still figure out that it's a value set by context. 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] re vertical space between Chapter number and title
I have found my own answer to the question I asked earlier: \setuppapersize[A4] \setuplabeltext [en] [chapter=~] \define[2]\MyChapter {\framed[frame=off,width=broad,align=middle]{#1\blank[2cm]#2}} \setuphead [chapter] [command=\MyChapter] \chapter{Chapter title} It was simply a matter of working out where to put the \blank[2cm] (or whatever vertical space was required). It replaced {#1\\#2}} Julian ___ 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] Vertical space between label and title
Hello, I know it works but ConteXt has so many commands with many keys that I thought there was a "cleaner" way. Fabrice Le mar. 7 juil. 2020 à 20:36, Henning Hraban Ramm a écrit : > > > > Am 07.07.2020 um 19:27 schrieb Fabrice Couvreur < > fabrice1.couvr...@gmail.com>: > > > > Hello, > > I want a vertical space between the label and the chapter title: is this > the right way to proceed ? > > Why not? It seems to work. What’s your problem? > > BTW I’d set \mainlanguage[fr] > > Hraban > > ___ > If your question is of interest to others as well, please add an entry to > the Wiki! > > maillist : ntg-context@ntg.nl / > http://www.ntg.nl/mailman/listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://context.aanhet.net > archive : https://bitbucket.org/phg/context-mirror/commits/ > wiki : http://contextgarden.net > > ___ > ___ 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 ___