Re: [NTG-context] Latest betas break tikz matrix
On 23-2-2011 5:38, Mathieu Boespflug wrote: Hi Aditya, Could be due to the change in catcode of&. Try adding \donknuthmode. It doesn't make any difference if I put the \donknuthmode just before \starttikzpicture. But If I put it before the \usemodule[tikz], then I get another error: Package pgfbasematrix: Error! Single ampersand used with wrong catcode. ! Missing number, treated as zero. that's a strange error ... if pgf knows that the catcode is 'wrong' it could deal with it i guess 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] Configuration files
On 25-2-2011 5:18, Eythan Weg wrote: Where can I find information about the contents of following files? context.cnf not used in mkiv, standard setup for mkii contextcnf.lua standard setup for mkiv texmf.cnf used by mkii texmfcnf.lua used by mkiv, most variables concern the minimals, some are presets for luatex (might change), some control mkiv (in principle one can set quite a lot of flags there, but if one does it can best be done in a local variant in e.g. texmf-local which will be read before the main one) Also I used to have cont-sys.tex in ~/texmf/tex. What is the analogous file for mkiv? cont-sys.mkiv but while in mkii one will use that for tuning some behaviour (esp related to map files and metapost) in mkiv there is no reason or using this file general (at least not currently) but you can put local stuff in it; however, if you do so and report problems to the list, make sure that the origin is not in that file 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] \halign
On 25-2-2011 5:16, Eythan Weg wrote: Wolfgang Schuster Thu, 24 Feb 2011 22:20:01 +0100 Am 24.02.2011 um 17:56 schrieb Eythan Weg: > > Hi, > > I have just installed beta. > > The line: > > \starttext >\halign{&\hfil#\hfil\quad\cr This& That\cr1&2\cr} > \stoptext > > is not typeset and the& are left in place. What could be the problem? Since a while ^, _ and& can be used in text mode like any other character. You can disable this with \donknuthmode at the begin of your document or use the \aligntab where you would normally use& but the best thing is to use one of contexts build in table environment. Wolfgang Thank you. I think that \halign, being a primitive of tex, should be respected. If a user wants to use it, it should be usable unconditionally. in context a more abstract coding is advertised; if you want to use halign in for instance a macro definition, you can surround it by \unprotect macro def \protect anyhow, when using halign directly in your document, don't expect too much from spacing - 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] \halign
On Fri, Feb 25, 2011 at 11:16:06AM -0500, Eythan Weg wrote: > > Wolfgang Schuster > Thu, 24 Feb 2011 22:20:01 +0100 > >Am 24.02.2011 um 17:56 schrieb Eythan Weg: > >> >> Hi, >> >> I have just installed beta. >> >> The line: >> >> \starttext >> \halign{&\hfil#\hfil\quad\cr This& That\cr1&2\cr} >> \stoptext >> >> is not typeset and the & are left in place. What could be the problem? > >Since a while ^, _ and & can be used in text mode like any other character. > >You can disable this with \donknuthmode at the begin of your document or >use the \aligntab where you would normally use & but the best thing is >to use one of contexts build in table environment. > >Wolfgang > > Thank you. I think that \halign, being a primitive of tex, should be > respected. If a user wants to use it, it should be usable > unconditionally. I've no idea from where you came with this impression, is is usually the other way around; people are advised not to use low level TeX code where context has higher level interfaces, else you are on your own and should be aware of the implications/side effects. I, for one, grateful that I know longer need to escape regular characters in my documents just to keep supporting some obscure TeX feature. Regards, Khaled -- Khaled Hosny Egyptian Arab ___ 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 ___
[NTG-context] Configuration files
Hi, Where can I find information about the contents of following files? context.cnf contextcnf.lua texmf.cnf texmfcnf.lua Also I used to have cont-sys.tex in ~/texmf/tex. What is the analogous file for mkiv? Thank you. Eythan ___ 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] \halign
Wolfgang Schuster Thu, 24 Feb 2011 22:20:01 +0100 Am 24.02.2011 um 17:56 schrieb Eythan Weg: > > Hi, > > I have just installed beta. > > The line: > > \starttext > \halign{&\hfil#\hfil\quad\cr This& That\cr1&2\cr} > \stoptext > > is not typeset and the & are left in place. What could be the problem? Since a while ^, _ and & can be used in text mode like any other character. You can disable this with \donknuthmode at the begin of your document or use the \aligntab where you would normally use & but the best thing is to use one of contexts build in table environment. Wolfgang Thank you. I think that \halign, being a primitive of tex, should be respected. If a user wants to use it, it should be usable unconditionally. Eythan ___ 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] Hyphenation patterns and adjusted kerning:?ConTeXt vs. LuaTeX
On Fri, Feb 25, 2011 at 04:45:31PM +0100, Ulrike Fischer wrote: > > Ah, yes, the transcript of my first example clearly shows fontspec > > operating in node mode. > > > Please excuse my naive asking: Is there any way to continue using > > fontspec's setmainfont command (it is convenient for someone > > unexperienced like me) and at the same force luaotfload into > > using base mode? > > The following seems to work: > > \documentclass{article} > \usepackage[ngerman]{babel} > \usepackage{fontspec} > \setmainfont[RawFeature={mode=base},FeatureFile=bonum.fea]{TeX Gyre Bonum} Better "Renderer=Basic". -- Khaled Hosny Egyptian Arab ___ 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] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
On Fri, Feb 25, 2011 at 03:41:10PM +0100, Ulrike Fischer wrote: > So I think it isn't true that the manual of luaotfload claims "By > default mode=base is used". It used to be like that but we changed it a while ago, looks like I didn't update the manual. Regards, Khaled -- Khaled Hosny Egyptian Arab ___ 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 ___
[NTG-context] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Am Fri, 25 Feb 2011 16:45:31 +0100 schrieb Ulrike Fischer: >> Please excuse my naive asking: Is there any way to continue using >> fontspec's setmainfont command (it is convenient for someone >> unexperienced like me) and at the same force luaotfload into >> using base mode? >> > > The following seems to work: > > \documentclass{article} > \usepackage[ngerman]{babel} > \usepackage{fontspec} > \setmainfont[RawFeature={mode=base},FeatureFile=bonum.fea]{TeX Gyre > Bonum} > \begin{document} > fh aufhalten > \end{document} Oh joy! Thank you all, once again, for your help. It is much appreciated. (The downside: Now that I can, I have no choice but to actually fix all the terrible kerning mistakes in TeX Gyre Bonum. Hours and hours of work. Sigh...) - Till ___ 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] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Am Fri, 25 Feb 2011 16:45:31 +0100 schrieb Ulrike Fischer: >> Ah, yes, the transcript of my first example clearly shows fontspec operating >> in node mode. Yes, but I could also reproduce the problem without fontspec (only with luaotfload). >> Please excuse my naive asking: Is there any way to continue using >> fontspec's setmainfont command (it is convenient for someone >> unexperienced like me) and at the same force luaotfload into >> using base mode? > > The following seems to work: > > \documentclass{article} > \usepackage[ngerman]{babel} > \usepackage{fontspec} > \setmainfont[RawFeature={mode=base},FeatureFile=bonum.fea]{TeX Gyre > Bonum} > \begin{document} > fh aufhalten > \end{document} And after a look in the fontspec code: \setmainfont[Renderer=Basic,FeatureFile=bonum.fea]{TeX Gyre Bonum} -- Ulrike Fischer ___ 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] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Am Fri, 25 Feb 2011 16:37:26 +0100 schrieb Heilmann, Till A.: > Am Fri, 25 Feb 2011 14:41:10 +0100 schrieb Ulrike Fischer: > >>> In base mode kerning and and hyphenation >>> happen in the traditional tex way, so there is not much extra trickery >>> taking place. >> >> Well, as you mention "base mode": This reminded me that I had to >> force base mode to get my reencoding to work in latex. So I tried in >> context + latex/luaotfload (with german hyphenation patterns): >> >> [...] >> >> And bingo: with mode=base it works in both formats, with mode=node >> the kern disappears. Without mode declaration the kern disappears in >> latex. > > Ah, yes, the transcript of my first example clearly shows fontspec operating > in node mode. > Please excuse my naive asking: Is there any way to continue using > fontspec's setmainfont command (it is convenient for someone > unexperienced like me) and at the same force luaotfload into > using base mode? The following seems to work: \documentclass{article} \usepackage[ngerman]{babel} \usepackage{fontspec} \setmainfont[RawFeature={mode=base},FeatureFile=bonum.fea]{TeX Gyre Bonum} \begin{document} fh aufhalten \end{document} -- Ulrike Fischer ___ 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 ___
[NTG-context] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Am Fri, 25 Feb 2011 14:41:10 +0100 schrieb Ulrike Fischer: >> In base mode kerning and and hyphenation >> happen in the traditional tex way, so there is not much extra trickery >> taking place. > > Well, as you mention "base mode": This reminded me that I had to > force base mode to get my reencoding to work in latex. So I tried in > context + latex/luaotfload (with german hyphenation patterns): > > [...] > > And bingo: with mode=base it works in both formats, with mode=node > the kern disappears. Without mode declaration the kern disappears in > latex. Ah, yes, the transcript of my first example clearly shows fontspec operating in node mode. Please excuse my naive asking: Is there any way to continue using fontspec's setmainfont command (it is convenient for someone unexperienced like me) and at the same force luaotfload into using base mode? Thanks, - Till ___ 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] post_linebreak_filter in context
Hello Hans, > > first put the function in some namespace, like: > > moduledata.mystuff = { } > moduledata.mystuff.show_hyph = show_hyph > > then register it in the finalizer group (which is the post_linebreak stuff) > > nodes.tasks.appendaction("finalizers","after","moduledata.mystuff.show_hyph") Works perfectly. > (before and after are subgroups that can be used by users if needed; of > course one never know to what extent it will influence other processes, so > "shipouts","after" might be a better choice) Ok. In this case it works for me but I'l remember that. Thanks! Patrick ___ 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] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Am Fri, 25 Feb 2011 14:35:10 +0100 schrieb Hans Hagen: >> As a new LuaTeX user, I came across the following problem: Using >> Lua(La)TeX, customized kerning of letter pairs (via the >> FeatureFile capability of fontspec) is ignored when it coincides >> with a possible hyphenation of a word (e.g. between 'f' and 'h' >> in German words like 'aufhalten'; see first minimal example >> below). >> 1. Lua(La)TeX > I cannot test that (I only have the context minimals installed) but I > don't know anything about latex internals so it would be a wild guess. > Maybe babel is interfering? No, the problem exists also if you only load the german patterns. > In base mode kerning and and hyphenation > happen in the traditional tex way, so there is not much extra trickery > taking place. Well, as you mention "base mode": This reminded me that I had to force base mode to get my reencoding to work in latex. So I tried in context + latex/luaotfload (with german hyphenation patterns): \font\test="name:TeX Gyre Bonum:mode=base:featurefile=bonum.fea;+kern" and \font\test="name:TeX Gyre Bonum:mode=node:featurefile=bonum.fea;+kern" And bingo: with mode=base it works in both formats, with mode=node the kern disappears. Without mode declaration the kern disappears in latex. So I think it isn't true that the manual of luaotfload claims "By default mode=base is used". -- Ulrike Fischer ___ 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] Float option “top” affects page break (on following pages)
On 24-2-2011 2:15, Andreas Harder wrote: Hi all, consider the following example. \starttext \showgrid Try to comment the \tex{placefigure} command, there will be 40 lines on the second page. If you uncomment it again there are 41 lines! \placefigure[top,nonumber]{}{\externalfigure[dummy]} \page \dorecurse{30}{line \recurselevel\par} \blank[medium,small] \dostepwiserecurse{31}{50}{1}{line \recurselevel\par} \stoptext It's really a problem if compiling a component file which ends up with another page breaking than the corresponding product file. I hope there will be soon a fix for that … is there already one? Mostly a matter of border cases I guess. Btw, you show a grid but don't turn grid snapping on. No fixes to be expected in mkii, but in mkiv the lot will be redone at some point. - 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] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
On 25-2-2011 1:18, Heilmann, Till A. wrote: Maybe the ConTeXt community can be of assistance to the LuaTeX bunch ... As a new LuaTeX user, I came across the following problem: Using Lua(La)TeX, customized kerning of letter pairs (via the FeatureFile capability of fontspec) is ignored when it coincides with a possible hyphenation of a word (e.g. between 'f' and 'h' in German words like 'aufhalten'; see first minimal example below). Ulrike Fischer was so kind to point out two things (http://tug.org/pipermail/luatex/2011-February/002569.html): First, the problem seems to be the break points between the adjusted kerning pairs. Second, ConTeXt seems to handle this case correctly (see second minimal example below; feature file bonum.fea from first example required). I am no expert in neither LuaTeX nor context, but Ulrike suggested I post here and ask if the (typographically correct) ConTeXt behavior or solution can be reproduced with Lua(La)TeX. Thanks, - Till 1. Lua(La)TeX \begin{filecontents*}{bonum.fea} languagesystem DFLT dflt; languagesystem latn dflt; feature kern { pos f h 100; } kern; \end{filecontents*} \documentclass{article} \usepackage[ngerman]{babel} \usepackage{fontspec} \setmainfont[FeatureFile=bonum.fea]{TeX Gyre Bonum} \begin{document} fh aufhalten \end{document} I cannot test that (I only have the context minimals installed) but I don't know anything about latex internals so it would be a wild guess. Maybe babel is interfering? In base mode kerning and and hyphenation happen in the traditional tex way, so there is not much extra trickery taking place. 2. ConTeXt \mainlanguage [de] \definefontfeature[test][featurefile=bonum,kern=yes] \definefont[test][name:texgyrebonum*test] \starttext \test fh aufhalten \stoptext Indeed I see a kern. 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 ___
[NTG-context] Letters in the first level head instead of numbers
Hello, maybe already questioned in the past, but I cannot find the answer: How to change the numbering style for a particular head (e.g. section) from numbers (1, 2...) to letters (A, B...) - which option and value (http://wiki.contextgarden.net/Reference/en/setuphead)? Thank you in advance. Kind regards, Lukas -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] Bezová 1658 147 14 Praha 4 Tel: +420 244 062 238 Fax: +420 244 461 038 ___ 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] btex and DeclareGraphicsRule question
On 24-2-2011 10:12, Rebecca Searls wrote: Why does stmt, label(btex Au dessus etex, (0,0)); fail when using stmt, \DeclareGraphicsRule{*}{mps}{*}{} but works with stmt, \DeclareGraphicsRule{*}{eps}{*}{} looks like latex I am running texlive/2010. Here is the error msg I get when using mps. /usr/local/texlive/2010/bin/i386-linux/mpost xtest.mp This is MetaPost, version 1.211 (TeX Live 2010) (kpathsea version 6.0.0) (./xtest.mpfatal: Command failed: etex --parse-first-line --interaction=nonstopmode mpIYqrrH.tex; see mpxerr.log xtest.mp xtest.mpx ! Unable to make mpx file. l.15 label(btex Au dessus etex, (0,0)); Transcript written on xtest.log. probably a configuration error at the latex 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] how to make chapter starts from odd page always?
On 24-2-2011 3:32, Jeong Dalyoung wrote: \setuphead[chapter][page=odd] - 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] post_linebreak_filter in context
On 25-2-2011 12:28, Patrick Gundlach wrote: Hi, how do I install a custom post_linebreak_filter in ConTeXt? I have this LaTeX file: \documentclass[12pt,a4paper]{scrartcl} \usepackage[english]{babel} \usepackage{blindtext} \usepackage{fontspec} \directlua{ show_hyph = function(head) while head do if head.id == 0 or head.id == 1 then % hlist, vlist show_hyph(head.list) % should be head.head in a newer luatex than 0.64 elseif head.id == 7 then % disc local n = node.new("whatsit","pdf_literal") n.mode = 0 n.data = "q 0.3 w 0 2 m 0 7 l S Q" n.next = head.next n.prev = head head.next = n head = n end head = head.next end return true end luatexbase.add_to_callback("post_linebreak_filter",show_hyph,"show_hyph") } \begin{document} \begin{minipage}{5cm} \blindtext \end{minipage} \end{document} which registers a function "show_hyph" as the post_linebreak_filter (the rest is not really interesting). How would I do this in ConTeXt? first put the function in some namespace, like: moduledata.mystuff = { } moduledata.mystuff.show_hyph = show_hyph then register it in the finalizer group (which is the post_linebreak stuff) nodes.tasks.appendaction("finalizers","after","moduledata.mystuff.show_hyph") (before and after are subgroups that can be used by users if needed; of course one never know to what extent it will influence other processes, so "shipouts","after" might be a better choice) - 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] reencode fonts with fonts.trigger
On 23-2-2011 6:05, Ulrike Fischer wrote: But I wished they were some documentation about the general structure of the font loading and processing and all this fields (fonts.manipulators, fonts.triggers, tfmdata.postprocessors, ...). There will be some documentation once it is stable enough. I also need to split off some code that is context specific in order to avoid confusion. 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] \placefigure and \em (again)
On 25-2-2011 9:44, Procházka Lukáš Ing. - Pontex s. r. o. wrote: ... Thanks for the answers. I'm familiar with using \dontleavehmode when needing to keep a figure midaligned; I had no idea that this would be a similar situation (and solution). {\em xxx ..} the first x triggers the start of a paragraph but it happens inside a group so it has side effects \dontleavehmode{\em xxx ..} here the paragraph is started outside the group - 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 ___
[NTG-context] Hyphenation patterns and adjusted kerning: ConTeXt vs. LuaTeX
Maybe the ConTeXt community can be of assistance to the LuaTeX bunch ... As a new LuaTeX user, I came across the following problem: Using Lua(La)TeX, customized kerning of letter pairs (via the FeatureFile capability of fontspec) is ignored when it coincides with a possible hyphenation of a word (e.g. between 'f' and 'h' in German words like 'aufhalten'; see first minimal example below). Ulrike Fischer was so kind to point out two things (http://tug.org/pipermail/luatex/2011-February/002569.html): First, the problem seems to be the break points between the adjusted kerning pairs. Second, ConTeXt seems to handle this case correctly (see second minimal example below; feature file bonum.fea from first example required). I am no expert in neither LuaTeX nor context, but Ulrike suggested I post here and ask if the (typographically correct) ConTeXt behavior or solution can be reproduced with Lua(La)TeX. Thanks, - Till 1. Lua(La)TeX \begin{filecontents*}{bonum.fea} languagesystem DFLT dflt; languagesystem latn dflt; feature kern { pos f h 100; } kern; \end{filecontents*} \documentclass{article} \usepackage[ngerman]{babel} \usepackage{fontspec} \setmainfont[FeatureFile=bonum.fea]{TeX Gyre Bonum} \begin{document} fh aufhalten \end{document} 2. ConTeXt \mainlanguage [de] \definefontfeature[test][featurefile=bonum,kern=yes] \definefont[test][name:texgyrebonum*test] \starttext \test fh aufhalten \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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] [t-vim] Line numbers
On 23-2-2011 5:54, Marco wrote: On 2011-02-23 Aditya Mahajan wrote: [...] I do not think that either of these options is worth the trouble. No, definitely not. I am not sure what you want. Do you want [...] context --purgeall This will probably be difficult to implement, since the complete directory tree has to be scanned to find xyz-externalfilter-abc-X.___ remains. However you can register to-be-cleaned-up temp files with luatex.registertempfile(name) (namespace might change at some point) 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] inmargin problem in mkiv with luatex when specified with stack
Am 25.02.2011 um 05:20 schrieb Dinh Tran: > Hello, > > Running the following context code doesn't seem to work with "context > --luatex". Works with "context --xetex" however. It works in a (currently private) beta but stacking isn’t perfect yet. BTW: The --luatex switch isn’t necessary to run MkIV. 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 ___
[NTG-context] post_linebreak_filter in context
Hi, how do I install a custom post_linebreak_filter in ConTeXt? I have this LaTeX file: \documentclass[12pt,a4paper]{scrartcl} \usepackage[english]{babel} \usepackage{blindtext} \usepackage{fontspec} \directlua{ show_hyph = function(head) while head do if head.id == 0 or head.id == 1 then % hlist, vlist show_hyph(head.list) % should be head.head in a newer luatex than 0.64 elseif head.id == 7 then % disc local n = node.new("whatsit","pdf_literal") n.mode = 0 n.data = "q 0.3 w 0 2 m 0 7 l S Q" n.next = head.next n.prev = head head.next = n head = n end head = head.next end return true end luatexbase.add_to_callback("post_linebreak_filter",show_hyph,"show_hyph") } \begin{document} \begin{minipage}{5cm} \blindtext \end{minipage} \end{document} which registers a function "show_hyph" as the post_linebreak_filter (the rest is not really interesting). How would I do this in ConTeXt? (also asked on tex.se: http://tex.stackexchange.com/questions/11960/how-to-register-a-callback-in-context) Thanks Patrick ___ 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] \placefigure and \em (again)
Hello, of course I do not have the solution for the underlaying problem. I found out, that you can put a \strut in front of the problematic text and then it comes out ok. Another point is, that placing the whole text-part i.e. all 4 paragraphs in your example between \bgroup \egroup results in more problems. In this case the tufte-text is also not flowing around the picture. Kind regards Willi On 25 Feb 2011, at 08:56, Procházka Lukáš Ing. - Pontex s. r. o. wrote: > Hello, > > sorry for repeating this topic, maybe it's not too attractive. > > Please, have a look to the following problem. > > I wonder why the behaviour described bellow occurs and how to typeset a > paragraph starting with some text enclosed into {\em ...} group inside the > "free" area formed (affected) by \placefigure. > > --- > > \starttext > \placefigure >[left,none] >{} >{ \startMPcode >draw (0,0)--(6cm,6cm); > \stopMPcode >} > > This is a normal text -- it flows around the picture on the left side of the > page as expected. > > {\em This empathized text starting a new paragraph} should not scratch the > picture left. > > When some text contains {\em an empathized text inside the paragraph}, text > flows normally as expected. > > \input tufte > \stoptext > > --- > > Thank you in advance. > > Best regards > > Lukas > > > -- > Ing. Lukáš Procházka [mailto:l...@pontex.cz] > Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] > Bezová 1658 > 147 14 Praha 4 > > Tel: +420 244 062 238 > Fax: +420 244 461 > 038___ > 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] \placefigure and \em (again)
... Thanks for the answers. I'm familiar with using \dontleavehmode when needing to keep a figure midaligned; I had no idea that this would be a similar situation (and solution). Best regards, Lukas On Fri, 25 Feb 2011 09:37:40 +0100, Wolfgang Schuster wrote: Am 25.02.2011 um 09:16 schrieb Henning Hraban Ramm: You can add a \strut in front of {\em - that’s a usual workaround for problems with non-letters starting a paragraph. The usual workaround is \dontleavehmode. Wolfgang -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] Bezová 1658 147 14 Praha 4 Tel: +420 244 062 238 Fax: +420 244 461 038 ___ 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] \placefigure and \em (again)
Am 25.02.2011 um 09:16 schrieb Henning Hraban Ramm: > You can add a \strut in front of {\em - that’s a usual workaround for > problems with non-letters starting a paragraph. The usual workaround is \dontleavehmode. 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] \placefigure and \em (again)
Am 25.02.2011 um 08:56 schrieb Procházka Lukáš Ing. - Pontex s. r. o.: > Hello, > > sorry for repeating this topic, maybe it's not too attractive. > > Please, have a look to the following problem. > > I wonder why the behaviour described bellow occurs and how to typeset a > paragraph starting with some text enclosed into {\em ...} group inside the > "free" area formed (affected) by \placefigure. > > --- > > \starttext > \placefigure >[left,none] >{} >{ \startMPcode >draw (0,0)--(6cm,6cm); > \stopMPcode >} > > This is a normal text -- it flows around the picture on the left side of the > page as expected. > > {\em This empathized text starting a new paragraph} should not scratch the > picture left. \dontleavehmode{\em …} 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] \placefigure and \em (again)
Am 2011-02-25 um 08:56 schrieb Procházka Lukáš Ing. - Pontex s. r. o.: --- \starttext \placefigure [left,none] {} { \startMPcode draw (0,0)--(6cm,6cm); \stopMPcode } This is a normal text -- it flows around the picture on the left side of the page as expected. {\em This empathized text starting a new paragraph} should not scratch the picture left. When some text contains {\em an empathized text inside the paragraph}, text flows normally as expected. \input tufte \stoptext --- You can add a \strut in front of {\em - that’s a usual workaround for problems with non-letters starting a paragraph. Greetlings from Lake Constance! Hraban --- http://www.fiee.net/texnique/ http://wiki.contextgarden.net https://www.cacert.org (I'm an assurer) ___ 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 ___