Re: [NTG-context] metafun/label: utf8 and spaces
On 6/28/07, Patrick Gundlach wrote: > Hi, > > is there any way to get utf-8 labels and without the 'strange' space > glyph? > > -- > > \startMPenvironment[+] > \enableregime[utf] > \stopMPenvironment > > > \starttext > foobar baz äöß % <-- OK > > \startuniqueMPgraphic{bla} > label("foobar baz äöß",(3cm,3cm)); % <-- broken > draw btex foobar baz äöß etex % <--- OK > \stopuniqueMPgraphic > > \useMPgraphic{bla} > > \stoptext > -- Why not this one? (Much faster, less problems, etc.) \enableregime[utf-8] \starttext \startuniqueMPgraphic{bla} label(\sometxt{foobar baz äöß},(3cm,3cm)); \stopuniqueMPgraphic \useMPgraphic{bla} \stoptext Metapost strings are something I wouldn't use anyway, although Aditya's idea is also a nice one (a dirty way would be to redefine label to use textext instead - I don't mean it too seriously of course). Mojca (http://dl.contextgarden.net/myway/sometxt.pdf) ___ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] columns
Quoting Patrick Gundlach <[EMAIL PROTECTED]>: > > [...] > >>> in \setupcolumns, what is ntop= >> >> From the source: the minimum number op balanced top lines >> >> Consider >> \starttext >> \startcolumns[n=2,ntop=15,balance=yes] >> \dorecurse{20}{This is a test line to check for balancing. } >> \stopcolumns >> \page >> \startcolumns[n=2,ntop=5,balance=yes] >> \dorecurse{20}{This is a test line to check for balancing. } >> \stopcolumns >> \stoptext > > This seems to be a binary switch, right? no difference in your example > between ntop=15 and ntop=13. Yes. The way I understand this is: if the number of lines in the column after balancing are greater than ntop, do column balancing (if enabled) otherwise not. For example, \showgrid \starttext \dostepwiserecurse{5}{15}{1}{ \section{\recurselevel} \startcolumns[n=2,ntop=\recurselevel,balance=yes] \dorecurse{20}{This is a test line to check for balancing. } \stopcolumns \page} \stoptext 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://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] frames and hyphenation
Well, it nearly always helps to put a problem to this newsgroup. It helps you concentrate better! The solution was simply, though not obvious at first. It should not haven been "before=\nohyphens" but "top=\nohyphens". On Jun 29, 2007, at 19:25, Hans van der Meer wrote: I encountered some strange thing with framedtext's in trying to define one where hyphenation is suppressed. The definition is: \defineframedtext[myblock][frame=off,style=\tt,width=0.8 \makeupwidth,before=\nohyphens] But then \startmyblock text \stopmyblock does not stop hyphenation. While \startmyblock\nohyphens text \stopmyblock stops it. Since I would like to have the myblock's all having suppressed hyphenation I am at a loss how to do it. Could it be that the \nohyphens in the "before" is overriden by something? It looks like, because setting lefthyphenmin and righthyphenmin zero at that point did not work either. By the way it is a bit difficult to give an exact example, because hyphenation so much depends on ones linesize and font dimensions. Hans van der Meer ___ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] frames and hyphenation
Quoting Hans van der Meer <[EMAIL PROTECTED]>: > I encountered some strange thing with framedtext's in trying to > define one where hyphenation is suppressed. The definition is: > \defineframedtext[myblock][frame=off,style=\tt,width=0.8 > \makeupwidth,before=\nohyphens] > But then \startmyblock text \stopmyblock does not stop hyphenation. > While \startmyblock\nohyphens text \stopmyblock stops it. > Since I would like to have the myblock's all having suppressed > hyphenation I am at a loss how to do it. Could it be that the > \nohyphens in the "before" is overriden by something? It looks like, > because setting lefthyphenmin and righthyphenmin zero at that point > did not work either. > By the way it is a bit difficult to give an exact example, because > hyphenation so much depends on ones linesize and font dimensions. http://wiki.contextgarden.net/Frames 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://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] columns/blank=
Hi, what is the rationale behind \setupblank[\@@klblank]% \ifdim\ctxparskip>\zeropoint\relax \setupwhitespace[\@@klblank]% \fi in page-mul.tex (columns)? It seems to me that blank=line inside a startcolumn does not work if ctxparskip = 0pt, which is the default. So when I'd like to have setupwhitespace[line] to get paragraphs separated by blank lines inside a column, I have to do this some other way?!? 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] columns
[...] >> in \setupcolumns, what is ntop= > > From the source: the minimum number op balanced top lines > > Consider > \starttext > \startcolumns[n=2,ntop=15,balance=yes] > \dorecurse{20}{This is a test line to check for balancing. } > \stopcolumns > \page > \startcolumns[n=2,ntop=5,balance=yes] > \dorecurse{20}{This is a test line to check for balancing. } > \stopcolumns > \stoptext This seems to be a binary switch, right? no difference in your example between ntop=15 and ntop=13. 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] frames and hyphenation
I encountered some strange thing with framedtext's in trying to define one where hyphenation is suppressed. The definition is: \defineframedtext[myblock][frame=off,style=\tt,width=0.8 \makeupwidth,before=\nohyphens] But then \startmyblock text \stopmyblock does not stop hyphenation. While \startmyblock\nohyphens text \stopmyblock stops it. Since I would like to have the myblock's all having suppressed hyphenation I am at a loss how to do it. Could it be that the \nohyphens in the "before" is overriden by something? It looks like, because setting lefthyphenmin and righthyphenmin zero at that point did not work either. By the way it is a bit difficult to give an exact example, because hyphenation so much depends on ones linesize and font dimensions. Hans van der Meer ___ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] columns
Quoting Patrick Gundlach <[EMAIL PROTECTED]>: > Hi, > > in \setupcolumns, what is ntop= From the source: the minimum number op balanced top lines Consider \starttext \startcolumns[n=2,ntop=15,balance=yes] \dorecurse{20}{This is a test line to check for balancing. } \stopcolumns \page \startcolumns[n=2,ntop=5,balance=yes] \dorecurse{20}{This is a test line to check for balancing. } \stopcolumns \stoptext > and height=? I've > played with these parameters but couldn't see any effect. I could not get any visible effect from height=... > > Is it possible that align=yes/no is incorrect? See Dont't know. 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://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] columns
Hi, in \setupcolumns, what is ntop= and height=? I've played with these parameters but couldn't see any effect. Is it possible that align=yes/no is incorrect? See http://source.contextgarden.net/tex/context/base/page-mul.tex?search=%40%40klalign (search for @@klalign) 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] inmargin
I was thinking that things placed in the margin (\inmargin,\inright, \inleft) would not take up vertical space, but it seems to do just that inside an itemize. Example: \starttext \textwidth=4cm \hairline %(1) \startitemize[n,joinedup] \item abc \item cde \stopitemize \hairline %(2) % This seems to me the logical place for the remark. \startitemize[n,joinedup] \inright{pqr} % < squeezing spaces does not help \item abc \item cde \stopitemize \hairline %(3) \startitemize[n,joinedup] % But it has to be placed here to get the result wanted. \item abc \inright{pqr} \item cde \stopitemize \hairline \stoptext I wanted a remark in the right margin logically applying to the itemize as a whole. Placing it as in (2) looked the right way, but then the next item is placed lower on the page. That becomes a problem when a nested itemize is put there resulting in an empty line at the first itemmarker. Placing the \inright on the first item of the inner itemize seems an illogical place to me. It is, of course, not really problem because trial (3) shows how to avoid this. Still the question remains if there is some misbehaviour here in either the code for \inright or for \itemize? Therefore I am pointing this out just in case it might reveal a more or less subtle bug too more wiser ConTeXt-brains then mine. Hans van der Meer ___ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] Labels in figures with wrong bounding box
In article <[EMAIL PROTECTED]>, nicola <[EMAIL PROTECTED]> wrote: > Hi, > I am typesetting a document with XeConTeXt, containing many MetaPost > figures. All the labels in the figures are typeset using \sometxt{} and > sometxt(). For some reasons, in the final document some of them appear > horribly stretched or shrinked as if their bounding box has not been > computed correctly (even after typesetting the document n times). I have > absolutely no clue why that happens, but I imagine it is some strange > interaction in the environment file, because if I typeset any of the > problematic figures by itself in a different document with a minimal > environment everything is fine. My environment file is quite long and I > cannot find a short example showing the problem. > The deformed labels seem to be always among those written by \sometxt > (but not all of them are wrong!), while those written using sometxt() > seem always ok. What may it depend upon? Ok, I solved the problem by getting rid of all \sometxt commands and replacing them by "low-level" sometxt(). Mojca's My Way about sometxt says "If you want to prevent clashes, use higher numbers in [\TeXtext's] arguments". I use numbers beyond 1000. I definitely do not have 1000 labels and, in fact, the correct labels are put in the correct places. But it seems that the two commands do not like each other anyway. Is it really not advisable to use them in the same document? Nicola ___ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___