Problem with \setupinterlinespace
In this example interlines spaces look a bit strange to me \starttext \input knuth \begingroup \tfx\setupinterlinespace[reset] \starttyping function newCounter() local i = 0 return function() i = i+1 return i end end c1 = newCounter() print(c1()) --> 1 print(c1()) --> 2 c2 = newCounter() print(c2()) --> 1 print(c1()) --> 3 print(c2()) --> 2 \stoptyping \endgroup \input tufte \stoptext Can someone confirm this ? -- luigi
What about this ? \usemodule[maps] \usemodule[visual] \setupinteraction[state=start] \setuplanguage[en] \definecolumnsetspan[wide][n=2] \def\Tfx{\tfx\setupinterlinespace[line=2.5ex]} \starttext \startArticle [Year=2009, Number=xx, Period=xx, Page=1, Title={foo}, Author={Luigi Scarso}] \input knuth \blank \begingroup \Tfx \input knuth\par \starttyping function newCounter() local i = 0 return function() i = i+1 return i end end c1 = newCounter() print(c1()) --> 1 print(c1()) --> 2 c2 = newCounter() print(c2()) --> 1 print(c1()) --> 3 print(c2()) --> 2 \stoptyping \input knuth\par \endgroup \blank \input tufte \par \stopArticle \stoptext -- luigi
Hi, please look at the attachment. I want different interline spacing for big, normal and small font sizes. What is the best approach? I tried \setupinterlinespace[big] (works only after \starttext!) or \setupinterlinespace[line=3.5ex] (works also before \starttext) but this changes, as intended, interline spacing as a whole. There is also \setupbodyfontenvironment (Problem with \chapter{…} or did I something wrong?). Now I've to use \switchtobodyfont[…] instead of \tfa and so on. Is there a trick? Thank you in advance Andreas
Andreas Harder schrieb:
sorry, no direct answer to your questions. but if you add a \showstruts to your document (after \starttext), you will see two big struts on both sides of the chapter number. looks like these struts (~80pt) cause the trouble here. hth, peter
Taco Hoekwater wrote:
Oh, I see. Somehow the interlinespace setting from the typescript doesn't come through. You could do this: \setuphead [chapter] [style={\switchtobodyfont[18pt]\setupinterlinespace[line=10ex]}] but it is weird that it does not work out of the box. Best wishes, Taco
Am 15.10.2009 um 21:55 schrieb Taco Hoekwater:
Okay, thank you for your advise. Why I can't say: \setupbodyfontenvironment [minion] [14.4pt] [interlinespace=3ex] % \tfa \setupbodyfontenvironment [minion] [9.6pt] [interlinespace=4ex] % \tfx and then use style=\tfa?
Because it works if one set \setupinterlinespace[line=5ex] for the whole document … By the way, what happened with \setupinterlinespace [big]? Anyway, thanks for your reply! PS. I don't want to be too greedy, but could you also have a look at http://archive.contextgarden.net/message/20091014.122329.48e0bcc0.en.html ? Andreas
Andreas Harder wrote:
In the interest of speed, \tfa only does the bare necessities to get a larger visual font size, and consequently all changes it makes are 'local', \switchtobodyfont sets up the 'global' settings as well, and these are the ones used by grid snapping and insertions etc.
I have no idea, Hans should have a look at that.
I'll get back to you, Best wishes, Taco
Taco Hoekwater wrote:
\start \setupinterlinespace[big] \input tufte \par \stop work sok here Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Andreas Harder wrote:
small example please Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (6)
-
Aditya Mahajan
-
Andreas Harder
-
Hans Hagen
-
luigi scarso
-
Peter Rolf
-
Taco Hoekwater