Re: [NTG-context] Metapost Animation of Sine

2021-07-22 Thread Otared Kavian
are great! This is what I had in mind, a rolling sine. Is > there a way to get the same result with the Tikz module? > > \usemodule[animation] > \setupinteraction[state=start] > > \starttext > > \input tufte > > \framed{ > \startanimation[menu=yes,framerate=40]

Re: [NTG-context] Metapost Animation of Sine

2021-07-22 Thread Jeroen
Hi, both solutions are great! This is what I had in mind, a rolling sine. Is there a way to get the same result with the Tikz module? \usemodule[animation] \setupinteraction[state=start] \starttext \input tufte \framed{ \startanimation[menu=yes,framerate=40] \dorecurse{50}{\expanded

[NTG-context] How to place text before a table inside a column environment

2021-07-22 Thread Michael Guravage
][2][width=3cm, align=middle] \setupTABLE[c][each][frame=off] \stopsetups \switchtobodyfont[10pt] \starttext \doifmode{title}{\title{Rooster}} \startcolumns[n=2] \bTABLE[split=yes, setups=tablesettings] \dorecurse{75}{\bTR \bTD 25 \eTD \bTD aug, wo \eTD \bTD Lecture \eTD \eTR

Re: [NTG-context] Metapost Animation of Sine

2021-07-21 Thread Otared Kavian
] \startanimation[menu=yes,framerate=10] \dorecurse{101}{\expanded {\startframe \startMPcode numeric u, omega, mylength, tt, N ; u := 2cm ; omega := 4 ; mylength

Re: [NTG-context] Metapost Animation of Sine

2021-07-21 Thread Otared Kavian
Hi, I wonder whether something like the following is what you are looking for: % begin wave-sine.tex \usemodule[animation] \setupinteraction[state=start] \starttext \startTEXpage[offset=2pt] \startanimation[menu=yes,framerate=10] \dorecurse{100}{\expanded {\startframe

Re: [NTG-context] Metapost Animation of Sine

2021-07-21 Thread Jeroen
small animation to enlarge a circle > > > \usemodule[animation] > \setupinteraction[state=start] > \starttext > \startanimation[menu=yes,framerate=10] > \dorecurse{7}{\expanded > {\startframe > \startMPcode > path p; > numeric n, u; > u := 1cm; >

Re: [NTG-context] Layers – when do they repeat?

2021-07-21 Thread Henning Hraban Ramm
setlayerframed[leftmargin][ > frame=off, > offset=overlay, > width=\leftmarginwidth, > align={flushleft,verytolerant}, > ]{Why is this repeated on every page? It should not.}% > > \dorecurse{20}{ > \fakewords{20}{100}\par > } > > \stoptext > ___

Re: [NTG-context] Metapost Animation of Sine

2021-07-21 Thread Fabrice L
Hi, > Le 21 juill. 2021 à 10:08, Jeroen a écrit : > > I use this small animation to enlarge a circle > > > \usemodule[animation] > \setupinteraction[state=start] > \starttext > \startanimation[menu=yes,framerate=10] > \dorecurse{7}{\expanded > {\startfram

[NTG-context] Metapost Animation of Sine

2021-07-21 Thread Jeroen
I use this small animation to enlarge a circle \usemodule[animation] \setupinteraction[state=start] \starttext \startanimation[menu=yes,framerate=10] \dorecurse{7}{\expanded {\startframe \startMPcode path p; numeric n, u; u := 1cm; n:=\recurselevel*u; p := fullcircle

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Jeong Dal
Dear Hans, Wolfgang, Both of your methods are working well. Using \frame, the \dorecurse problem is solved. \starttext \startanimation[menu=yes] \dorecurse{10} { \frame{\useMPgraphic[stacking={#1}]{demo}}} \stopanimation \stoptext Thank you for your solutions. Best regards, Dalyoung

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Hans Hagen
; endfor ; \stopuseMPgraphic \unprotect \tolerant\protected\def\useMPanimation[#1]#2%    {\begingroup     \scratchtoks\emptytoks \dorecurse{10}{\etoksapp\scratchtoks{{\useMPgraphic[\c!stacking={\recurselevel}]{#2%     \expanded{\startanimation[#1]\the\scratchtoks

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Wolfgang Schuster
; \stopuseMPgraphic \setupinteraction[state=start] \usemodule[animation] \starttext \startanimation[menu=yes] % \dorecurse{10} % { {\useMPgraphic[stacking={#1}]{demo}}} {\useMPgraphic[stacking={1}]{demo}} {\useMPgraphic[stacking={2}]{demo}} {\useMPgraphic[stacking={3}]{demo}} {\useMPgraphic[stacking={4

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Jeong Dal
[state=start] \usemodule[animation] \starttext \startanimation[menu=yes] % \dorecurse{10} % { {\useMPgraphic[stacking={#1}]{demo}}} {\useMPgraphic[stacking={1}]{demo}} {\useMPgraphic[stacking={2}]{demo}} {\useMPgraphic[stacking={3}]{demo}} {\useMPgraphic[stacking={4}]{demo}} {\useMPgraphic

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Floris van Manen
\unprotect \tolerant\protected\def\useMPanimation[#1]#2%   {\begingroup    \scratchtoks\emptytoks \dorecurse{10}{\etoksapp\scratchtoks{{\useMPgraphic[\c!stacking={\recurselevel}]{#2%    \expanded{\startanimation[#1]\the\scratchtoks\stopanimation}%    \endgroup} \protect

Re: [NTG-context] weekend upload - stacking and animation

2021-07-13 Thread Hans Hagen
; \stopuseMPgraphic \setupinteraction[state=start] \usemodule[animation] \starttext \startanimation[menu=yes] % \dorecurse{10} % { {\useMPgraphic[stacking={#1}]{demo}}} {\useMPgraphic[stacking={1}]{demo}} {\useMPgraphic[stacking={2}]{demo}} {\useMPgraphic[stacking={3}]{demo}} {\useMPgraphic[stacking={4

Re: [NTG-context] Header for a book

2021-07-13 Thread Fabrice Couvreur
}] \dorecurse{10}{\input knuth} \stopsection \startsection[title={Le raisonement par récurrence}] \dorecurse{10}{\input knuth} \stopsection \startsection[title={Récurrences fortes}] \dorecurse{10}{\input knuth} \stopsection \startsection[title={Exercices corrigés

Re: [NTG-context] double-sided page number placement

2021-07-12 Thread Hans Hagen
doing something wrong here? Hi Charles, I think that "inright" is what you want: \setuppagenumbering[alternative=doublesided, location=inright] \starttext \dorecurse{20}{\input knuth } \stoptext With current latest from 2021.07.10 21:51, "location=inright&

Re: [NTG-context] double-sided page number placement

2021-07-12 Thread Charles Doherty
uppagenumbering[alternative=doublesided, > location=inright] > > \starttext > \dorecurse{20}{\input knuth } > \stoptext > > With current latest from 2021.07.10 21:51, "location=inright" behaves as > you expect using LMTX. > > Using MKIV with

[NTG-context] Header for a book

2021-07-12 Thread Fabrice Couvreur
]}] \setuppagenumbering [alternative=doublesided,location=] \starttext \startchapter [title=La récurrence] \startsection[title={Le principe de récurrence}] \dorecurse{10}{\input knuth} \stopsection \startsection[title={Le raisonement par récurrence}] \dorecurse{10}{\input knuth

Re: [NTG-context] double-sided page number placement

2021-07-11 Thread Pablo Rodriguez
re? Hi Charles, I think that "inright" is what you want: \setuppagenumbering[alternative=doublesided, location=inright] \starttext \dorecurse{20}{\input knuth } \stoptext With current latest from 2021.07.10 21:51, "location=inright" behaves as you expect using

[NTG-context] double-sided page number placement

2021-07-11 Thread Charles Doherty
Dear Hans, The following file: \setuplayout[location=doublesided] \setuppagenumbering[location=inmargin,alternative=doublesided] \starttext \dorecurse{20}{\input knuth } \stoptext using: > ConTeXt ver: 2021.04.21 11:39 LMTX fmt: 2021.7.11 int: english/english the left page of the dou

Re: [NTG-context] weekend upload

2021-07-10 Thread Hans Hagen
pencircle scaled 2mm ; endfor ; draw boundingbox currentpicture withpen pencircle scaled 1pt withstacking 0 ; currentpicture := currentpicture xsized 15mm; \stopuseMPgraphic \setupMPvariables[demo] \startTEXpage \vskip1ex \hbox{\space\dore

Re: [NTG-context] weekend upload

2021-07-09 Thread Hans Hagen
pencircle scaled 2mm ; endfor ; draw boundingbox currentpicture withpen pencircle scaled 1pt withstacking 0 ; currentpicture := currentpicture xsized 15mm; \stopuseMPgraphic \setupMPvariables[demo] \startTEXpage \vskip1ex \hbox{\space\dore

Re: [NTG-context] weekend upload

2021-07-09 Thread Aditya Mahajan
ithstacking (if odd(i) : i else : 5 fi) > withpen pencircle scaled 2mm ; > endfor ; > draw boundingbox currentpicture > withpen pencircle scaled 1pt > withstacking 0 ; > currentpicture := currentpicture xsized 15mm; > \stopuse

[NTG-context] weekend upload

2021-07-09 Thread Hans Hagen
withstacking 0 ; currentpicture := currentpicture xsized 15mm; \stopuseMPgraphic \setupMPvariables[demo] \startTEXpage \vskip1ex \hbox{\space\dorecurse{10}{\useMPgraphic{demo}{list={0,#1}}\space}} \vskip1ex \nointerlineskip \hbox{\space\dorecurse{10}{\useMPgraphic{demo}{list={0,1

Re: [NTG-context] Footer

2021-07-06 Thread Fabrice Couvreur
> > [{\pagenumber}] > > [Chapter\space\pagenumber] > > > > \starttext > > \startchapter > > [title=First chapter] > >\dorecurse{10}{\input knuth} > > \stopchapter > > \startchapter > >[title=Second chapter] >

Re: [NTG-context] Footer

2021-07-05 Thread Wolfgang Schuster
the title of the chapter, a line vertical and page number. Thanks for your help. Fabrice  \setupfootertexts     [{\getmarking[chapter]}]     [{\pagenumber}]     [{\pagenumber}]     [Chapter\space\pagenumber] \starttext \startchapter   [title=First chapter]   \dorecurse{10}{\input knuth} \s

[NTG-context] Footer

2021-07-05 Thread Fabrice Couvreur
er. Thanks for your help. Fabrice \setupfootertexts [{\getmarking[chapter]}] [{\pagenumber}] [{\pagenumber}] [Chapter\space\pagenumber] \starttext \startchapter [title=First chapter] \dorecurse{10}{\input knuth} \stopchapter \startchapter [title=Second chapter] \dorecurse{10}{\i

[NTG-context] Fwd: columnsets messed up

2021-07-02 Thread Henning Hraban Ramm
e bottom >>> - it gets worse with footnotes (looks like their space isn’t considered at >>> all) >>> - if the column set doesn’t start at the top of the page, the second column >>> does >>> Hraban >>> \definecolumnset[cgjcolset][n=2] >>> \startt

Re: [NTG-context] columnsets messed up

2021-07-02 Thread Hans Hagen
][n=2] \starttext \chapter{This is a chapter about column sets} \startcolumnset[cgjcolset] \dorecurse{20}{ \samplefile{sapolsky}\par } \stopcolumnset \stoptext Personally I'd never use columnsets for anything else than very controlled situations because that's what they were made

Re: [NTG-context] columnsets messed up

2021-07-02 Thread Henning Hraban Ramm
umn >> does >> Hraban >> \definecolumnset[cgjcolset][n=2] >> \starttext >> \chapter{This is a chapter about column sets} >> \startcolumnset[cgjcolset] >> \dorecurse{20}{ >> \samplefile{sapolsky}\par >> } >> \stopcolumnset >> \stoptext &g

Re: [NTG-context] Heading for endnotes / grouped by chapter endnotes

2021-07-02 Thread denis.maier
\startchapter    [title=Notes] > \setupheadertexts[{\it\getmarking[part]}][\setups{noteHeadingsText}] > [\setups{noteHeadingsText}][{\it\getmarking[part]}] >   \placenotes  [endnote] >   \page > \setupheadertexts[{\it\getmarking[part]}][{\it\getmarking[section]}] >    

Re: [NTG-context] columnsets messed up

2021-07-02 Thread Hans Hagen
] \dorecurse{20}{ \samplefile{sapolsky}\par } \stopcolumnset \stoptext Personally I'd never use columnsets for anything else than very controlled situations because that's what they were made for. Not to be mixed with the normal pagebuilder. So, first of all you need to operate on the grid (i

[NTG-context] columnsets messed up

2021-07-01 Thread Henning Hraban Ramm
like their space isn’t considered at all) - if the column set doesn’t start at the top of the page, the second column does Hraban \definecolumnset[cgjcolset][n=2] \starttext \chapter{This is a chapter about column sets} \startcolumnset[cgjcolset] \dorecurse{20}{ \samplefile{sapolsky}\par

[NTG-context] Layers – when do they repeat?

2021-07-01 Thread Henning Hraban Ramm
}, ]{Why is this repeated on every page? It should not.}% \dorecurse{20}{ \fakewords{20}{100}\par } \stoptext ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context

Re: [NTG-context] Heading for endnotes / grouped by chapter endnotes

2021-06-30 Thread Rik Kabel
%--% \starttext \completecontent \startpart[title=Part 1] \dorecurse{3}{   \startchapter[title=Chapter #1]     If a man wants to read good books, he must make a point of     avoiding bad ones; for life is short, and time and energy     limited.     \startfootnote   T.\,Baily Saunders

Re: [NTG-context] paragraph standing out of the normal layout comsuming the margin

2021-06-29 Thread Jan U. Hasecke
=shiftblock] \setuppagenumbering     [alternative=doublesided] \starttext \startbuffer     \dorecurse{2}{\input knuth\par}     \startuserdata[shiftblock]     \input ward     \stopuserdata     \dorecurse{2}{\input zapf\par} \stopbuffer \dorecurse{10}{\getbuffer} \stoptext I'll try

Re: [NTG-context] color conversion eats note

2021-06-27 Thread Wolfgang Schuster
rgb=no,conversion=no] %\setupcolors[state=stop,conversion=no] \setcolormodel[none] \starttext \dorecurse{20}{\convertnumber{word}{#1} }% \color[red]{not a number} \dorecurse{20}{\convertnumber{word}{#1} } \stoptext Wolfg

Re: [NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-25 Thread Jeong Dal
Dear Aditya and Hans, Thank you for your suggestion. I add > \startMPcalculation > > \stopMPcalculation and it works. \setupinteraction[state=start] \usemodule[animation] \starttext %\startanimation[menu=yes] %{ \startMPcalculation path p; \stopMPcalculation \dorecurse

Re: [NTG-context] paragraph standing out of the normal layout comsuming the margin

2021-06-25 Thread Wolfgang Schuster
\defineuserdataalternative [shiftblock] [renderingsetup=userdata:shiftblock] \defineuserdata [shiftblock] [before=\blank, after=\blank, alternative=shiftblock] \setuppagenumbering [alternative=doublesided] \starttext \startbuffer \dorecurse{2}{\input knuth\par} \startuserdata

Re: [NTG-context] Align in setup header/footer

2021-06-25 Thread Wolfgang Schuster
[part]}][] \setuppagenumbering [alternative=doublesided] \setupfootertexts [margin] [\leftaligned {A}] [\rightaligned{B}] [\leftaligned {C}] [\rightaligned{D}] \setuplayout [backspace=4cm, width=12cm] \showframe \starttext \dorecurse{4}{\dontleavehmode\page} \stoptext

[NTG-context] lmtx upload

2021-06-24 Thread Hans Hagen
). \starttext \dorecurse{100}{ \input {tar:///e:/temporary/test/foo.tar?name=test.tex}\par \input {tar:///e:/temporary/test/foo.tar.xz?name=test.tex}\par \input {tar:///e:/temporary/test/foo.tar.gz?name=test.tex}\par } \stoptext The tar files are handled by lmtx itself, the gzipped

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-24 Thread Hans Hagen
On 6/24/2021 5:42 AM, Aditya Mahajan wrote: On Wed, 23 Jun 2021, Aditya Mahajan wrote: On Thu, 24 Jun 2021, Jeong Dal wrote: Now, I am trying to do the same thing using \startuseMPgraphic, but I don’t the correct result yet. Using \startuseMPgraphic, and \dorecurse, the code is simpler

Re: [NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-24 Thread Jeong Dal
Dear Hans, Your code works fine. > \starttext > > \startMPcode >numeric maxCount; >maxCount := 10; >setglobalmacro("MyMacro",decial maxCount); >setglobalcount("MyCount",maxCount); > \stopMPcode > > > \dorecurse{\MyMa

Re: [NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-24 Thread Hans Hagen
initializations are run: \starttext \setbox\scratchbox\hbox{\startMPcode draw unitcircle; \stopMPcode} \dorecurse{\udCount} {\useMPgraphic{foldUD}{num=\recurselevel}} {\useMPgraphic{dotLines}{num=\recurselevel}} \stoptext A run with no sideeffects in the content stream

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-23 Thread Aditya Mahajan
On Wed, 23 Jun 2021, Aditya Mahajan wrote: > On Thu, 24 Jun 2021, Jeong Dal wrote: > > > Now, I am trying to do the same thing using \startuseMPgraphic, but I don’t > > the correct result yet. > > Using \startuseMPgraphic, and \dorecurse, the code is simpler.

Re: [NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-23 Thread Aditya Mahajan
> >setglobalcount("MyCount",maxCount); > > \stopMPcode > > > > > > \dorecurse{\MyMacro}{It is \recurselevel. }\par > > \dorecurse{\MyCount}{It is \recurselevel. }\par > > > > \stoptext > > I applied your method to my code as following. >

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-23 Thread Aditya Mahajan
On Thu, 24 Jun 2021, Jeong Dal wrote: > Now, I am trying to do the same thing using \startuseMPgraphic, but I don’t > the correct result yet. > Using \startuseMPgraphic, and \dorecurse, the code is simpler. But, it seems > to me that \startanimation … \stopanimation is

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-23 Thread Jeong Dal
inal]} \stopanimation \stoptext Now, I am trying to do the same thing using \startuseMPgraphic, but I don’t the correct result yet. Using \startuseMPgraphic, and \dorecurse, the code is simpler. But, it seems to me that \startanimation … \stopanimation is not working with \dorecurse{}{} … It just

[NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-23 Thread Jeong Dal
Hi, Is there a way to deliver the value of a variable in MetaFun to ConTeXt. For example, I want to do the following: \starttext \startMPcode numeric maxCount; % … some code maxCount := 10; \stopMPcode dorecurse{maxCount} {It is \recurselevel.\par} \stoptext Thank you for reading. Best

Re: [NTG-context] Delivering the value of a variable in MetaFun to ConTeXt

2021-06-23 Thread Hans Hagen
On 6/23/2021 10:00 PM, Jeong Dal wrote: Hi, Is there a way to deliver the value of a variable in MetaFun to ConTeXt. For example, I want to do the following: \starttext \startMPcode numeric maxCount; % … some code maxCount := 10; \stopMPcode dorecurse{maxCount} {It is \recurselevel.\par

Re: [NTG-context] Adjust Grid to last line textheight

2021-06-23 Thread denis.maier
=0, %bottom=0.4, %bottom=0, %bottom=1, %bottom=5, line=2.8ex, ] \setuplayout[grid=yes] \showgrid \starttext \dorecurse{5}{\input knuth\par} \stoptext == Even extreme values

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-21 Thread Mikael Sundqvist
Hans > >> using this expression, but I had always thought this is just a name… > >> > >> Best regards: Otared > >> > >>> On 21 Jun 2021, at 06:26, Aditya Mahajan wrote: > >>> > >>> On Mon, 21 Jun 2021, Jeong Dal wrote: > >

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-21 Thread Otared Kavian
;> On 21 Jun 2021, at 06:26, Aditya Mahajan wrote: >>> >>> On Mon, 21 Jun 2021, Jeong Dal wrote: >>> >>>> >>>> Hi, >>>> >>>> I defined a macro definition in metafun, and draw figures using >>>

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-21 Thread Mikael Sundqvist
n is used > >> repeatedly by changing the numeric argument. > >> Is there a better way to simplify the code, for example, using \dorecurse > >> and recurselevel? > > > > See attached. The main idea is to store the repetitive bits in > > \startuseMPgraphic{..

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-21 Thread Otared Kavian
ing >> \startbuffer[] … \stopbuffer and \processMPbuffer[]. >> As you see in the attached code, the same macro definition is used >> repeatedly by changing the numeric argument. >> Is there a better way to simplify the code, for example, using \dorecurse >> and recurse

Re: [NTG-context] simplifying repeated macro calls in metafun

2021-06-20 Thread Aditya Mahajan
the numeric argument. > Is there a better way to simplify the code, for example, using \dorecurse and > recurselevel? See attached. The main idea is to store the repetitive bits in \startuseMPgraphic{...} and then reuse them using \includeMPgraphic. Aditya mp-test.te

[NTG-context] simplifying repeated macro calls in metafun

2021-06-20 Thread Jeong Dal
, using \dorecurse and recurselevel? Thank you for reading. Best regards, Dalyoung \startbuffer[UDBasic] pair A,B,C,D; pair E, F, G, H; path p,q; numeric ang,maxNum; u:=1in; A=(.95*TextWidth,u); B=(0,u); C=(0,0); D=(.95*TextWidth,0); p := A--B--C--D; q := (TextWidth,1.5u)--(0,1.5u

Re: [NTG-context] xtable as list item (again)

2021-06-17 Thread Pablo Rodriguez
On 6/16/21 9:56 PM, Wolfgang Schuster wrote: > Pablo Rodriguez schrieb am 15.06.2021 um 19:57: >>[...] >>\showframe\showstruts >>\starttext >>\startitemize[n][margin=yes] >>\item a >>\item >> \startembeddedxtable[option={stret

Re: [NTG-context] xtable as list item (again)

2021-06-16 Thread Wolfgang Schuster
] \item a \item \startembeddedxtable[option={stretch, width}] \dorecurse{25}{\startxrow \startxcell \Characters{\recurselevel}\stopxcell \startxcell \characters{\recurselevel}\stopxcell \stopxrow} \stopembeddedxtable \item \startfixed % put your table

[NTG-context] xtable as list item (again)

2021-06-15 Thread Pablo Rodriguez
={stretch, width}] \dorecurse{25}{\startxrow \startxcell \Characters{\recurselevel}\stopxcell \startxcell \characters{\recurselevel}\stopxcell \stopxrow} \stopembeddedxtable \item b \stopitemize \stoptext And I get two issues: 1. Item number in 2 is placed on the bottom

Re: [NTG-context] new upload

2021-06-14 Thread Hans Hagen
, backgroundcolor=red] \setupfacingfloat [whatever:right] [background=color, backgroundcolor=green] \startfacingfloat[whatever] {\dorecurse{10}{\samplefile{tufte} }} {\dorecurse{10}{\samplefile{ward} }} {\dorecurse{10}{\samplefile{tufte} }} {\dorecurse{10

Re: [NTG-context] new upload

2021-06-14 Thread Pablo Rodriguez
\setupfacingfloat [whatever:right] [background=color, backgroundcolor=green] \startfacingfloat[whatever] {\dorecurse{10}{\samplefile{tufte} }} {\dorecurse{10}{\samplefile{ward} }} {\dorecurse{10}{\samplefile{tufte} }} {\dorecurse{10}{\samplefile{ward} }} \stopfacingfloat

Re: [NTG-context] help with xtreme tables

2021-06-08 Thread Ajith R
][background=color,backgroundcolor=green] \starttext \startlinetablehead \dorecurse{2}{\dorecurse{5}{\NC head #1 ##1\NC head \NC head \NC head \NC head \NC head} \NC \NR} \stoplinetablehead \startlinetable \dorecurse{2000}{\dorecurse{5}{\NC cell #1 ##1\NC cell \NC cell \NC cell \NC cell

Re: [NTG-context] help with xtreme tables

2021-06-08 Thread Hans Hagen
,backgroundcolor=red] % \setuplinetable[c][4] [width=3cm,background=color,backgroundcolor=yellow] % \setuplinetable[c][6] [width=3cm,background=color,backgroundcolor=magenta] % \setuplinetable[r][even][background=color,backgroundcolor=green] \starttext \startlinetablehead \dorecurse{2}{\dorecurse{5

[NTG-context] wrong link rectagle in LMTX

2021-05-28 Thread Pablo Rodriguez
Dear list, I have the following sample: \setuppapersize[A9] \setupinteraction[state=start] \enabledirectives[references.border] \unexpanded\def\MyURL#1% {\bgroup\goto{{\tt\hyphenatedurl{#1}}}[url(#1)]\egroup} \starttext \startitemize \dorecurse{2}{\item \MyURL{a.b\\/c.d

[NTG-context] styling references

2021-05-28 Thread Pablo Rodriguez
Dear list, I have the following sample: \starttext \startitemize \dorecurse{15} {\item[\recurselevel]whatever} \stopitemize As exposed in \in{item}[9]... \stoptext How can I add style to the item reference (9)? I mean, how can I get “As exposed in item {\em 9}”? Many thanks

Re: [NTG-context] TeX capacity exceeded

2021-05-19 Thread Hans Hagen
\ss BB}\par \dorecurse{1000}{ \char1234 } \stoptext You can set up a list of 'quick and dirty fallback' fonts (you can set a sequence for each style). This doesn't replace the normal fallback mechanisms but can be handy as catch. H

[NTG-context] Expanding a figure into the second column

2021-05-16 Thread Jeroen
{tufte} \placefigure [here] [] {my pic} {\externalfigure [cow] [width=.95\textwidth]} \dorecurse{3}{\input{tufte}} \stopcolumns \stoptext ___ If your question is of interest to others as well, please

Re: [NTG-context] What is the ConTeXt way to handle this \vbox trick?

2021-05-09 Thread Hans Hagen
] \starttext \startbuffer \dorecurse{20}{\ruby{XYZ}{a|bc|d} }\par \dorecurse{20}{\ruby{PQR}{p|q|r} }\par \dorecurse{20}{\ruby{XYZ}{1|22|333} }\par \dorecurse{20}{\ruby{XYZ}{111|222|333} }\par \dorecurse{20}{\ruby{XYZ}{foobar} }\par \dorecurse{20}{\ruby{XYZ}{fooledbar} }\par

Re: [NTG-context] very long hanging caption

2021-05-07 Thread Hans Hagen
tance=4mm,   location=righthanging] \startbuffer[caption] \dorecurse{60}{very long caption } \stopbuffer \starttext \startplacefigure[title={\getbuffer[caption]}] \externalfigure[cow][height=40mm,width=80mm] \stopplacefigure \stoptext Thank you,

Re: [NTG-context] very long hanging caption

2021-05-07 Thread Jano Kula
between image and the > caption, distance parameter has no effect. MkIV, because footnotes in > columns are needed (not in lmtx, yet). > > % macros=mkiv > \setupcaption[ > number=no, > hang=yes, > align={nothyphenated,flushleft}, > distance=4mm, > location=ri

Re: [NTG-context] Double-sided layer

2021-05-06 Thread Wolfgang Schuster
erdistance\relax] {\externalfigure[32.png]} \setlayer [backgroundimage] [left] [x=\cutspace, y=\dimexpr\topspace+\headerheight+\headerdistance\relax] {\externalfigure[32.png]} \showframe [text] [text] \starttext \dorecurse{10}{\dontleavehmode\page} \stoptext

[NTG-context] LuaMetaFun MPinclusions doublefun

2021-05-02 Thread Fabrice L
= "\dorecurse{9}{· Just random text }", path = p xsized TextWidth, autoscaleup = "max", reverse=true, ] xsized 5in; \stopMPpage % ——— Log says: metafun > log > error: Isolated expression metafun > log > metapost

[NTG-context] very long hanging caption

2021-05-02 Thread Jano Kula
={nothyphenated,flushleft}, distance=4mm, location=righthanging] \startbuffer[caption] \dorecurse{60}{very long caption } \stopbuffer \starttext \startplacefigure[title={\getbuffer[caption]}] \externalfigure[cow][height=40mm,width=80mm] \stopplacefigure \stoptext Thank you, Jano

Re: [NTG-context] calculating optimal height of textblock

2021-04-29 Thread denis.maier
\displaywidowpenalties{2}{0} \stopsetups \setuplayout[setups=mypenalties] %\showframe \showmakeup \showsetups \starttext \dorecurse{5}{\input knuth\par} \stoptext === > -Ursprüngliche Nachricht- > Von: Maier, Denis Christian (UB) > Gesendet: Donne

[NTG-context] calculating optimal height of textblock

2021-04-28 Thread denis.maier
=mypenalties] %\showframe \showmakeup %\showsetups \starttext \dorecurse{5}{\input knuth\par} \stoptext = How do you do this usually? Any best-practices? Hints? Trial and error seems to work ok, but maybe there is a more efficient method... Best Denis

Re: [NTG-context] \setupalign[height] and \setupalign[line] in LMTX

2021-04-28 Thread denis.maier
]}, spacebefore={medium,flexible}, leftmargin=no] \starttext \dorecurse{10}{ \input knuth \startblockquote \input knuth \stopblockquote \input knuth } \stoptext Two noteworthy things: 1

Re: [NTG-context] clubs and widows in columns

2021-04-27 Thread Jano Kula
st. > > > > \setuppapersize[A7] > > \starttext > > \startcolumns[separator=rule, > > align={right,nothyphenated}] > > \dorecurse{12}{→ one two three four five\par} > > \stopcolumns > > \stoptext > > > > For a different task:

Re: [NTG-context] \setupalign[height] and \setupalign[line] in LMTX

2021-04-26 Thread denis.maier
, indentnext=no, leftmargin=no, rightmargin=no, ] \starttext \dorecurse{10}{ \input knuth \startblockquote

Re: [NTG-context] clubs and widows in columns

2021-04-26 Thread mf
,nothyphenated}] \dorecurse{12}{→ one two three four five\par} \stopcolumns \stoptext For a different task: are there some higher level commands in ctx than \vsplitprimitive to play with vbox splitting? As a workaround, you could try switching to pagecolumns: since they are typeset as pages

[NTG-context] clubs and widows in columns

2021-04-25 Thread Jano Kula
Dear list, is there a way to avoid clubs and widows in columns? I don't know, how it would be implemented, if the task is splitting typeset vertical list. \setuppapersize[A7] \starttext \startcolumns[separator=rule, align={right,nothyphenated}] \dorecurse{12}{→ one two three four

[NTG-context] new page before xtable with repeated headers

2021-04-23 Thread Werner Hennrich
header] \setupxtable[mytable:header] [ foregroundstyle=\bf, foregroundcolor=darkred, ] % ====== \startdocument \dorecurse{2} { \input tufte \vskip7mm } \startxtable[mytable] \startxtablehead \startxrow[mytable:header] \startxcell Some Header \stopxcell \st

[NTG-context] \setupalign[height] and \setupalign[line] in LMTX

2021-04-22 Thread denis.maier
=no, leftmargin=no, rightmargin=no, ] \starttext \dorecurse{10}{ \input knuth \startblockquote \input knuth \stopblockquote

Re: [NTG-context] Suppressing headers and footers on blank pages before pagebreak at the end of a chapter.

2021-04-07 Thread Wolfgang Schuster
from pre-computer times. You have to change the argument of the page-setting for chapters. \setuppagenumbering [alternative=doublesided] \setuphead [chapter] [page={yes,header,footer,right}] \starttext \startchapter[title=Knuth] \dorecurse{10}{\samplefile{knuth}} \stopchapter

[NTG-context] Grid typesetting, blockquotes in smaller font across pagebreaks

2021-03-25 Thread denis.maier
\dorecurse{5}{ \dorecurse{5}{Some text on a grid. } \startblockquote \dorecurse{10}{A quotation in a smaller font. } \stopblockquote \dorecurse{5}{This should be on the grid again. }} \stoptext -- With style=\tfx it kind of works as long as the quotations

Re: [NTG-context] Writing to .tuc directly from Lua

2021-03-24 Thread Jairo A. del Rio
; 2 then > return c > else > return inner(c*m, m-1) > end > end > return inner(1,n) > end > > local function factorial(n) > local data = job.datasets.getdata("factorials","list") >

Re: [NTG-context] Writing to .tuc directly from Lua

2021-03-24 Thread Hans Hagen
ot;factorial", public= true, arguments = { "integer" }, actions = { factorial, context } } \stopluacode \dorecurse {20} { \factorial #1 \relax } \stoptext but you probably don't gain much as the

Re: [NTG-context] Questions regarding \startexceptions and ligature prevention

2021-03-22 Thread Hans Hagen
xte \stopexceptions \mainlanguage[de] \dorecurse{100}{#1 auffasste auffaxxte } Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53

Re: [NTG-context] Formula numbering including all prefix segments

2021-03-21 Thread Adam Reviczky
ll (default is limited to 3, see strc-def) > > \starttext > \setupcounter[formula][way=bytext] > \setupcaption[figure][way=bytext,prefixsegments=1:*] > \setupformulas[way=bytext,prefixsegments=1:*,prefixset=all] > > \startchapter[title=Chapter] > \do

Re: [NTG-context] Formula numbering including all prefix segments

2021-03-21 Thread Hans Hagen
[title=Chapter] \dorecurse{4}{ \startsection[title=Section] \startsubsection[title=SubSection] \startplacefigure[list=cow] \externalfigure[cow] \stopplacefigure \startplaceformula[reference=eq1] \startformula c^2 = a^2 + b^2

Re: [NTG-context] Keeping track of hyphenations

2021-03-20 Thread Hans Hagen
[hyphenation.applied.visualize] % \enabletrackers[hyphenation.applied.console] \startbuffer \samplefile{tufte} \blank {\hsize 4em \dorecurse{4}{x\discretionary{aa}{bb}{cc}x #1 }} \blank \stopbuffer \starttext \switchtobodyfont[modern] \getbuffer \switchtobodyfont[pagella

Re: [NTG-context] lmt_followtext and cycle

2021-03-19 Thread Hans Hagen
:46 requires two scalings, in path and in lmt_followtext: \showframe \setuppapersize[A6, landscape] \starttext \startMPcode{doublefun} path p; p := (0,0)..(3,3.5)..(9,-3.5).. (12,0)..(9,3.5)..(3,-3.5)..cycle; draw lmt_followtext [ text = "\dorecurse{9}{· Just random

Re: [NTG-context] lmt_followtext and cycle

2021-03-19 Thread Pablo Rodriguez
alings, in path and in lmt_followtext: \showframe \setuppapersize[A6, landscape] \starttext \startMPcode{doublefun} path p; p := (0,0)..(3,3.5)..(9,-3.5).. (12,0)..(9,3.5)..(3,-3.5)..cycle; draw lmt_followtext [ text = "\dorecurse{9}{· Just random text }", path = p xsized Te

Re: [NTG-context] lmt_followtext and cycle

2021-03-18 Thread Hans Hagen
[ text = "\dorecurse{9}{Just random text · } ", path = p, autoscaleup = "max", reverse=true, ] xsized TextWidth ; \stopMPcode \stoptext You can't expect two overlayed graphics to know of each others independent applied scaling. So you need to do this: \sta

[NTG-context] lmt_followtext and cycle

2021-03-18 Thread Pablo Rodriguez
Hans, I’m afraid that lmt_followtext has problems with cycle again. \starttext \startMPcode{doublefun} path p ; p := (0,0)..(3,3.5)..(9,-3.5).. (12,0)..(9,3.5)..(3,-3.5)..cycle; draw p xsized TextWidth ; draw lmt_followtext [ text = "\dorecurse{9}{Just random text · } ",

[NTG-context] working on page refs with MP

2021-03-18 Thread Werner Hennrich
] \pagebreak[yes] \pagereference[\dummyparameter{ref}] \doassign[header][first=\dummyparameter{ref}] \doassign[header][next=\dummyparameter{next}] {\tfc\bf{#2}}\par \vskip3mm } \def\fillWithText[#1]{ \dorecurse{#1}{ \input tufte \input knuth } } \setupheadertexts

[NTG-context] Multiple Layouts

2021-03-13 Thread Jeroen
] \startchapter[title={Bryson and Tufte}] \dorecurse{5}{ \startsection[title={Bryson}] \input{bryson} \stopsection \startsection[title={Tufte}] \input{tufte} \stopsection} \stopchapter \startchapter[title={Zapf and Ward}] \dorecurse{5}{ \startsection[title={Zapf}] \input{zapf} \stopsection

[NTG-context] (no subject)

2021-03-13 Thread Jeroen
] \startchapter[title={Bryson and Tufte}] \dorecurse{5}{ \startsection[title={Bryson}] \input{bryson} \stopsection \startsection[title={Tufte}] \input{tufte} \stopsection} \stopchapter \startchapter[title={Zapf and Ward}] \dorecurse{5}{ \startsection[title={Zapf}] \input{zapf} \stopsection

Re: [NTG-context] Write to tuc file

2021-03-07 Thread Pablo Rodriguez
er > \startchapter[reference=moreover,title=oof] > \stopchapter > > and --pages=whatever,moreover will give you the info you need to call > context --extra=copy or whatever with the right arguments Hans, real-world needs may be complex, such as in the following sample: \startte

<    1   2   3   4   5   6   7   8   9   10   >