Re: [NTG-context] filling page to bottom
Hans van der Meer schrieb am 15.05.2019 um 09:24: I find that the current (default) settings tend to break pages early, leaving a fairly large amount of whitespace at the bottom of the pages. Obviously in order to avoid breaking paragraphs or to avoid small parts of a paragraph at the top of the page. What parameters do I have to tweak to fill the pages more completely? Because I planned already to examine all pages individually for their appearance, inserting breaks by hand is not the problem here. You have to change the penalty values for orphans, widows etc. \startsetups [hvdm] \directsetup{*reset} \nopenalties \stopsetups \showgrid \starttext \dorecurse{10}{\samplefile{knuth}} \page \setuplayout[setups=hvdm] \dorecurse{10}{\samplefile{knuth}} \stoptext 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] issue with page numbering
On 5/8/19 9:28 PM, Wolfgang Schuster wrote: > [...] >> Is there any way to avoid that \lastsubpagenumber counts the blank page >> that might be placed among two chapters? > You have to reset the subpage counter at the end of each chapter. > > \startsetups [chapter:after] > \page > \resetsubpagenumber > \stopsetups > > \setuphead > [chapter] > [aftersection=\directsetup{chapter:after}] Many thanks for your fast reply, Wolfgang. It works perfectly fine. It doesn’t work in my real document, but it took me a while to realize that I was using \chapter instead of \startchapter...\stopchapter. Time to get a break... Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] issue with page numbering
Pablo Rodriguez schrieb am 08.05.2019 um 20:14: Dear list, inspired by strc-pag.mkiv, I have the following sample: \setuppagenumbering[alternative=doublesided] \setupsubpagenumber[way=bychapter] \starttext \dorecurse{5}{\startchapter[title=My Chapter] \userpagenumber/\lastuserpagenumber--- \subpagenumber/\lastsubpagenumber \stopchapter} \stoptext I need that chapters start on an odd page. Is there any way to avoid that \lastsubpagenumber counts the blank page that might be placed among two chapters? You have to reset the subpage counter at the end of each chapter. \startsetups [chapter:after] \page \resetsubpagenumber \stopsetups \setuphead [chapter] [aftersection=\directsetup{chapter:after}] 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] endnotes customizing how?
On 4/9/2019 11:19, Hans van der Meer wrote: In typesetting my endnotes with \placenotes[endnote] I seem unable to unfluence the text characteristics. I tried things like (1) \setupnotes[endnote][textcolor=blue] (2) changed fonts before the \ bgroup\bf\placenote\egroup call (3) \startsetups[setups:endnotes] \setupwhitespace[0pt] \stopsetups % textstyle influences endnotemarker in the text. \setupnote[endnote][textcommand=\hifnmarker,before=\directsetup{setups:endnotes}] (4)\setupnotes[endnote][bodyfont=italic] Where (3) made a difference in linespacing, nothing else does. How can one determine the text characteristics of the endnotes? dr. 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___ Not sure exactly what you want, but if it helps, here is what I have used. \setupnote handles the in-text reference to the note, \setupnotation handles the note itself. The choice of SignalStyle depends on the appearance of the chosen font's superiors, if they exist. \define[1]\SignalStyle{\high{\small\hairspace#1}} %definefontfeature [f:su] % [sups=yes] %define[1]\SignalStyle{\feature[+][f:su]{\hairspace#1}} \setupnote [endnote][ textseparator={,}, textstyle=\SignalStyle, location=none, bodyfont=, ] \setupnotation[endnote] [headstyle=\small, numbercommand=, after={\blank[halfline]}, ] -- Rik ___ 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] endnotes customizing how?
Hans van der Meer schrieb am 09.04.2019 um 17:19: In typesetting my endnotes with \placenotes[endnote] I seem unable to unfluence the text characteristics. I tried things like (1) \setupnotes[endnote][textcolor=blue] (2) changed fonts before the \ bgroup\bf\placenote\egroup call (3) \startsetups[setups:endnotes] \setupwhitespace[0pt] \stopsetups % textstyle influences endnotemarker in the text. \setupnote[endnote][textcommand=\hifnmarker,before=\directsetup{setups:endnotes}] \setupnote [endnote] [setups=setups:endnotes] (4)\setupnotes[endnote][bodyfont=italic] Where (3) made a difference in linespacing, nothing else does. How can one determine the text characteristics of the endnotes? \setupnotation [endnote] [style=italic] 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
[NTG-context] endnotes customizing how?
In typesetting my endnotes with \placenotes[endnote] I seem unable to unfluence the text characteristics. I tried things like (1) \setupnotes[endnote][textcolor=blue] (2) changed fonts before the \ bgroup\bf\placenote\egroup call (3) \startsetups[setups:endnotes] \setupwhitespace[0pt] \stopsetups % textstyle influences endnotemarker in the text. \setupnote[endnote][textcommand=\hifnmarker,before=\directsetup{setups:endnotes}] (4) \setupnotes[endnote][bodyfont=italic] Where (3) made a difference in linespacing, nothing else does. How can one determine the text characteristics of the endnotes? dr. 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Troubles with the \cldcontext command
Dear Wolfgang! thank you so much for your reply. I tried the test file and it works. tomorrow I will look further in a bigger environment. Thanks and good night! Willi > On 2 Apr 2019, at 21:17, Willi Egger wrote: > > Hello! > > I have the following code, which should manipulate the page number. However I > get an error: > > > MWE: > > \setuppapersize [A6] [A6] > > \setuppagenumbering[location=none] > > \startsetups [Pagenumber] > \doifrightpageelse >{\cldcontext{"\letterpercent d",(\pagenumber+1)/2}} >{} > \stopsetups > > \setupfootertexts [\directsetup{Pagenumber}] > > \setupbodyfont [pagella,9pt] > > > \starttext > > \startstandardmakeup > Hello world! > \stopstandardmakeup > > \dorecurse{3}{TEST\page} > > \stoptext > > > Error: > > > \cldcontext #1->\directlua {context(#1)} > > \ignorecrlf \directsetup {Pagenumber} > {}{}{} > \secondoftwoarguments #1#2->#2 > > \page_layouts_process_element_single_indeed ...#4} > \fi \endgroup > \page_layouts_process_element_single ...#1#2#3{#4} > \fi > ...th {\hss \layoutelementparameter \c!middletext > \hss }\kern -\makeupwidth ... > > > What do i miss here? I am stumid… > > Willi > ___ > 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 ___
[NTG-context] Troubles with the \cldcontext command
Hello! I have the following code, which should manipulate the page number. However I get an error: MWE: \setuppapersize [A6] [A6] \setuppagenumbering[location=none] \startsetups [Pagenumber] \doifrightpageelse {\cldcontext{"\letterpercent d",(\pagenumber+1)/2}} {} \stopsetups \setupfootertexts [\directsetup{Pagenumber}] \setupbodyfont [pagella,9pt] \starttext \startstandardmakeup Hello world! \stopstandardmakeup \dorecurse{3}{TEST\page} \stoptext Error: \cldcontext #1->\directlua {context(#1)} \ignorecrlf \directsetup {Pagenumber} {}{}{} \secondoftwoarguments #1#2->#2 \page_layouts_process_element_single_indeed ...#4} \fi \endgroup \page_layouts_process_element_single ...#1#2#3{#4} \fi ...th {\hss \layoutelementparameter \c!middletext \hss }\kern -\makeupwidth ... What do i miss here? I am stumid… Willi ___ 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] A strange request...
Willi Egger schrieb am 20.02.19 um 17:23: Hi all, I am siting with a project of making a “dwarsligger”, you know these books, printed on bible-thin-printing paper, which are about 12 x 8 cm. One opens them while holding them ‘landscape’ with the spine on the top… Now there is of course a little struggle with the page numbering. The reading page consists out of the even page together with the following uneven page. It is easy to print on the uneven page a page number, however this will result in uneven page numbers only throughout the book. My question is, whether there is an algorithm to print page numbers as follows: 1 2 3 4 5 6 7 8 9 (this is the ordinary numbering) 1 2 3 4 5 (this is the requested numbering) Does someone have an idea how to solve this? Variant 1: \setuppapersize[A5,landscape] \setuppagenumbering[location=none] \startsetups [pagenumber] \doifoddpageelse {\cldcontext{"\letterpercent d",(\pagenumber+1)/2}} {} \stopsetups \setupheadertexts [\directsetup{pagenumber}] \starttext \dorecurse{10}{\samplefile{knuth}} \stoptext Variant 2: \defineexpandable[1]\DwarsliggerNumber {\cldcontext{"\letterpercent d",(#1+1)/2}} \defineconversion [dwarsligger] [\DwarsliggerNumber] \setuppapersize[A5,landscape] \setupuserpagenumber[numberconversion=dwarsligger] \setuppagenumbering[location=none] \setupheadertexts [\doifoddpageelse{\prefixedpagenumber}{}] \starttext \dorecurse{10}{\samplefile{knuth}} \stoptext 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Macro for a header does not work as well
Hi Fabrice, After adding \mainlanguage[fr] to your file I obtain the attached output (Context version 2019.02.14 16:57). Best regards: OK macros-header-date.pdf Description: Adobe PDF document > On 19 Feb 2019, at 11:37, Fabrice Couvreur > wrote: > > Hi Otared, > No that's not what I want to talk about. Before I got this "27 février 2019" > and now this d = 27 m = 02 y = 2019. > Thank you. > Fabrice > > Le lun. 18 févr. 2019 à 14:31, Otared Kavian a écrit : > Hi Fabrice, > > Do you mean the fact that the date is not in the usual French format? In that > case you should add > > \mainlanguage[fr] > > to the beginning of your file. > > Best regards: OK > > > On 18 Feb 2019, at 12:04, Fabrice Couvreur > > wrote: > > > > Hi, > > Aditya offered me this macro some time ago for my header. I updated context > > standalone, and the display of the date I want to do the evaluation > > (different from the current date) is no longer the same. > > Thank you. > > Fabrice > > > > \setupbackgrounds > >[header] > >[text] > >[frame=off, > > topframe=off, > > bottomframe=on, > > framecolor=, > > rulethickness=1pt] > > > > \defineframed > >[headerframed] > >[frame=off, > > height=fit, > > width=fit] > > > > \startsetups [headertext] > > > > \setupheadertexts > >[{ > > \startframed [headerframed] [foregroundstyle=bold] > > \getvariable{headertext}{title} > > n\high{o}\,\getvariable{headertext}{number} > > \stopframed > >}] > > > > \setupheadertexts > > [{ > > \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] > > \getvariable{headertext}{location}\\ > > \getvariable{headertext}{time} > > \stopframed > > }] > > [{ > > \startframed [headerframed] > > [align=flushright,foregroundstyle=\ssx] > >Lycée LA SALLE\\ > > > > \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] > > \stopframed > > }] > > > > \stopsetups > > > > > > \setvariable{headertext}{set}{\directsetup{headertext}} > > \setvariables > > [headertext] > > [title={Devoir surveillé de Mathématiques}, > >number={4}, > >day={27}, > >month={02}, > >year={2019}, > >location={T\high{\tfxx ale}~ES}, > >time={3 heures}] > > > > \starttext > > \input knuth > > \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://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 > ___ > ___ > 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] Macro for a header does not work as well
Hi Otared, No that's not what I want to talk about. Before I got this "27 février 2019" and now this d = 27 m = 02 y = 2019. Thank you. Fabrice Le lun. 18 févr. 2019 à 14:31, Otared Kavian a écrit : > Hi Fabrice, > > Do you mean the fact that the date is not in the usual French format? In > that case you should add > > \mainlanguage[fr] > > to the beginning of your file. > > Best regards: OK > > > On 18 Feb 2019, at 12:04, Fabrice Couvreur > wrote: > > > > Hi, > > Aditya offered me this macro some time ago for my header. I updated > context standalone, and the display of the date I want to do the evaluation > (different from the current date) is no longer the same. > > Thank you. > > Fabrice > > > > \setupbackgrounds > >[header] > >[text] > >[frame=off, > > topframe=off, > > bottomframe=on, > > framecolor=, > > rulethickness=1pt] > > > > \defineframed > >[headerframed] > >[frame=off, > > height=fit, > > width=fit] > > > > \startsetups [headertext] > > > > \setupheadertexts > >[{ > > \startframed [headerframed] [foregroundstyle=bold] > > \getvariable{headertext}{title} > n\high{o}\,\getvariable{headertext}{number} > > \stopframed > >}] > > > > \setupheadertexts > > [{ > > \startframed [headerframed] > [align=flushleft,foregroundstyle=\ssx] > > \getvariable{headertext}{location}\\ > > \getvariable{headertext}{time} > > \stopframed > > }] > > [{ > > \startframed [headerframed] > [align=flushright,foregroundstyle=\ssx] > >Lycée LA SALLE\\ > > > > \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] > > \stopframed > > }] > > > > \stopsetups > > > > > > \setvariable{headertext}{set}{\directsetup{headertext}} > > \setvariables > > [headertext] > > [title={Devoir surveillé de Mathématiques}, > >number={4}, > >day={27}, > >month={02}, > >year={2019}, > >location={T\high{\tfxx ale}~ES}, > >time={3 heures}] > > > > \starttext > > \input knuth > > \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://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 > > ___ > ___ 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] Macro for a header does not work as well
Hi Fabrice, Do you mean the fact that the date is not in the usual French format? In that case you should add \mainlanguage[fr] to the beginning of your file. Best regards: OK > On 18 Feb 2019, at 12:04, Fabrice Couvreur > wrote: > > Hi, > Aditya offered me this macro some time ago for my header. I updated context > standalone, and the display of the date I want to do the evaluation > (different from the current date) is no longer the same. > Thank you. > Fabrice > > \setupbackgrounds >[header] >[text] >[frame=off, > topframe=off, > bottomframe=on, > framecolor=, > rulethickness=1pt] > > \defineframed >[headerframed] >[frame=off, > height=fit, > width=fit] > > \startsetups [headertext] > > \setupheadertexts >[{ > \startframed [headerframed] [foregroundstyle=bold] > \getvariable{headertext}{title} > n\high{o}\,\getvariable{headertext}{number} > \stopframed >}] > > \setupheadertexts > [{ > \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] > \getvariable{headertext}{location}\\ > \getvariable{headertext}{time} > \stopframed > }] > [{ > \startframed [headerframed] [align=flushright,foregroundstyle=\ssx] >Lycée LA SALLE\\ > > \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] > \stopframed > }] > > \stopsetups > > > \setvariable{headertext}{set}{\directsetup{headertext}} > \setvariables > [headertext] > [title={Devoir surveillé de Mathématiques}, >number={4}, >day={27}, >month={02}, >year={2019}, >location={T\high{\tfxx ale}~ES}, >time={3 heures}] > > \starttext > \input knuth > \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://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 ___
[NTG-context] Macro for a header does not work as well
Hi, Aditya offered me this macro some time ago for my header. I updated context standalone, and the display of the date I want to do the evaluation (different from the current date) is no longer the same. Thank you. Fabrice \setupbackgrounds [header] [text] [frame=off, topframe=off, bottomframe=on, framecolor=, rulethickness=1pt] \defineframed [headerframed] [frame=off, height=fit, width=fit] \startsetups [headertext] \setupheadertexts [{ \startframed [headerframed] [foregroundstyle=bold] \getvariable{headertext}{title} n\high{o}\,\getvariable{headertext}{number} \stopframed }] \setupheadertexts [{ \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] \getvariable{headertext}{location}\\ \getvariable{headertext}{time} \stopframed }] [{ \startframed [headerframed] [align=flushright,foregroundstyle=\ssx] Lycée LA SALLE\\ \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] \stopframed }] \stopsetups \setvariable{headertext}{set}{\directsetup{headertext}} \setvariables [headertext] [title={Devoir surveillé de Mathématiques}, number={4}, day={27}, month={02}, year={2019}, location={T\high{\tfxx ale}~ES}, time={3 heures}] \starttext \input knuth \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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Issue with the latest beta of context standalone
Hi, I added the patch but the output is not that expected because I get d = 4m = 02 y = 2019 instead of "4 février 2019" Thank you Fabrice \mainlanguage[fr] \setupbackgrounds [header] [text] [frame=off, topframe=off, bottomframe=on, framecolor=, rulethickness=1pt] \defineframed [headerframed] [frame=off, height=fit, width=fit] \startsetups [headertext] \setupheadertexts [{ \startframed [headerframed] [foregroundstyle=bold] \getvariable{headertext}{title} n\high{o}\,\getvariable{headertext}{number} \stopframed }] \setupheadertexts [{ \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] \getvariable{headertext}{location}\\ \getvariable{headertext}{time} \stopframed }] [{ \startframed [headerframed] [align=flushright,foregroundstyle=\ssx] Lycée LA SALLE\\ \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] \stopframed }] \stopsetups \setvariable{headertext}{set}{\directsetup{headertext}} \setvariables [headertext] [title={Interrogation écrite}, number={6}, day={4}, month={02}, year={2019}, location={Seconde GTE}, time={55 minutes}] \starttext \input Knuth \stoptext Le dim. 27 janv. 2019 à 17:54, Otared Kavian a écrit : > On 27 Jan 2019, at 17:30, Wolfgang Schuster < > wolfgang.schuster.li...@gmail.com> wrote: > > > […] > 1. You don’t have to remake the format for patches in cont-new.mkiv > because the file is loaded at runtime. > > 2. The patch works and I get “2019 januari 27” with your example. > > > Hi Wolfgang, > > Thanks for the clarification about cont-new.mkiv. > The corrected cont-new.mkiv begins with > > \unprotect > > \def\syst_converters_check_date > {\edef\temp{\systemparameter\c!d}\scratchcounterone > \ifx\temp\empty\normalday \else\temp\fi > \edef\temp{\systemparameter\c!m}\scratchcountertwo > \ifx\temp\empty\normalmonth\else\temp\fi > \edef\temp{\systemparameter\c!y}\scratchcounterthree\ifx\temp\empty\normalyear > \else\temp\fi} > > \writestatus\m!system{beware: some patches loaded from cont-new.mkiv} > > > However I still get the wrong date with the example I sent, and Fabrice's > example with \mainlanguage[fr], as well as with \mainlanguage[nl], gives an > incorrect result (even though the result is correct with \mainlanguage[en]). > > Best regards: OK > > ___ > 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] Issue with the latest beta of context standalone
On 1/27/2019 1:17 PM, Fabrice Couvreur wrote: Hi, I just updated context standalone and if I compile the following file, the date does not appear anymore. side effect of some experiments by alan and me put this in cont-new.mkiv (after \unprotect) \def\syst_converters_check_date {\edef\temp{\systemparameter\c!d}\scratchcounterone \ifx\temp\empty\normalday \else\temp\fi \edef\temp{\systemparameter\c!m}\scratchcountertwo \ifx\temp\empty\normalmonth\else\temp\fi \edef\temp{\systemparameter\c!y}\scratchcounterthree\ifx\temp\empty\normalyear \else\temp\fi} Thank you Fabrice \mainlanguage[fr] \setupbackgrounds [header] [text] [frame=off, topframe=off, bottomframe=on, framecolor=, rulethickness=1pt] \defineframed [headerframed] [frame=off, height=fit, width=fit] \startsetups [headertext] \setupheadertexts [{ \startframed [headerframed] [foregroundstyle=bold] \getvariable{headertext}{title} n\high{o}\,\getvariable{headertext}{number} \stopframed }] \setupheadertexts [{ \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] \getvariable{headertext}{location}\\ \getvariable{headertext}{time} \stopframed }] [{ \startframed [headerframed] [align=flushright,foregroundstyle=\ssx] Lycée LA SALLE\\ \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] \stopframed }] \stopsetups \setvariable{headertext}{set}{\directsetup{headertext}} \setvariables [headertext] [title={Interrogation écrite}, number={6}, day={29}, month={01}, year={2019}, location={Seconde GTE}, time={55 minutes}] \starttext \input Knuth \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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___ -- - 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] Issue with the latest beta of context standalone
Hi Hans, I can confirm that with version 2019.01.25 20:06, when the main language is set to fr, the \date command does not work correctly. However setting \mainlanguage[en] gives the correct behavior of \date, in english, in the example file sent by Fabrice. Also this minimal example gives a wrong date: \mainlanguage[fr] \starttext \currentdate \stoptext gives 27 mars 2019 (with two months in advance… :-) \mainlanguage[en] or any other language, gives the same error (March 27, 2019). Best regards: OK > On 27 Jan 2019, at 13:17, Fabrice Couvreur > wrote: > > Hi, > I just updated context standalone and if I compile the following file, the > date does not appear anymore. > Thank you > Fabrice > > \mainlanguage[fr] > > \setupbackgrounds > [header] > [text] > [frame=off, > topframe=off, > bottomframe=on, > framecolor=, > rulethickness=1pt] > > \defineframed >[headerframed] >[frame=off, > height=fit, > width=fit] > >\startsetups [headertext] > \setupheadertexts > [{ > \startframed [headerframed] [foregroundstyle=bold] > \getvariable{headertext}{title} > n\high{o}\,\getvariable{headertext}{number} > \stopframed > }] > > \setupheadertexts > [{ > \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] > \getvariable{headertext}{location}\\ > \getvariable{headertext}{time} > \stopframed > }] > [{ > \startframed [headerframed] > [align=flushright,foregroundstyle=\ssx] > Lycée LA SALLE\\ > > \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] > \stopframed > }] > > \stopsetups > > \setvariable{headertext}{set}{\directsetup{headertext}} > > \setvariables > [headertext] > [title={Interrogation écrite}, >number={6}, >day={29}, >month={01}, >year={2019}, >location={Seconde GTE}, >time={55 minutes}] > >\starttext > \input Knuth >\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://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 ___
[NTG-context] Issue with the latest beta of context standalone
Hi, I just updated context standalone and if I compile the following file, the date does not appear anymore. Thank you Fabrice \mainlanguage[fr] \setupbackgrounds [header] [text] [frame=off, topframe=off, bottomframe=on, framecolor=, rulethickness=1pt] \defineframed [headerframed] [frame=off, height=fit, width=fit] \startsetups [headertext] \setupheadertexts [{ \startframed [headerframed] [foregroundstyle=bold] \getvariable{headertext}{title} n\high{o}\,\getvariable{headertext}{number} \stopframed }] \setupheadertexts [{ \startframed [headerframed] [align=flushleft,foregroundstyle=\ssx] \getvariable{headertext}{location}\\ \getvariable{headertext}{time} \stopframed }] [{ \startframed [headerframed] [align=flushright,foregroundstyle=\ssx] Lycée LA SALLE\\ \date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}] \stopframed }] \stopsetups \setvariable{headertext}{set}{\directsetup{headertext}} \setvariables [headertext] [title={Interrogation écrite}, number={6}, day={29}, month={01}, year={2019}, location={Seconde GTE}, time={55 minutes}] \starttext \input Knuth \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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Changes \setuphead
Hi Otared Thank you, that helped. I have tried the example, as written. Ursula Hermann -Ursprüngliche Nachricht- Von: ntg-context Im Auftrag von Otared Kavian Gesendet: Montag, 21. Jänner 2019 12:08 An: mailing list for ConTeXt users Betreff: Re: [NTG-context] Changes \setuphead Hi Ursula, If you replace the \startsetups[chapter:before] with the following, you obtain a page without the page number: \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setuppagenumbering[state=stop] \setupbackgrounds[page][background=color,backgroundcolor=gray] \page[right] \setuppagenumbering[state=start] \popbackground} \stopsetups However probably there is a better way to achieve what you want… Best regards: OK > On 21 Jan 2019, at 11:26, Ursula Hermann wrote: > > Hello List! > > It is a long time ago, that I have written the last mail to you. > Thank you Taco so much, because for the new example of the Recent changes > from 17.January 2019. Because: Modyfying the page before a chapter is > something, that i can need. I mean this one: > > % next five lines just to show the effect on this wiki > \setuppapersize[A8][A5,landscape] \setuppaper[nx=4, ny=2] > \setuplayout[page][location=middle, marking=on] \setuparranging [XY] > \setupbodyfont[6pt] > > % actual example starts here > \setuppagenumbering > [alternative=doublesided] > > \startsetups [chapter:before] > \doifoddpageelse > {} > {\pushbackground[page] > \setupbackgrounds[page][background=color,backgroundcolor=gray] > \page[right] > \popbackground} > \stopsetups > > \setuphead > [chapter] > [page=yes, >before=\directsetup{chapter:before}] > > \starttext > > \startchapter[title={Knuth}] > \dorecurse{2}{\samplefile{knuth}} > \stopchapter > > \startchapter[title={Ward}] > \dorecurse{1}{\samplefile{ward}} > \stopchapter > > \startchapter[title={Zapf}] > \dorecurse{2}{\samplefile{zapf}} > \stopchapter > > > \stoptext > > I have a question: how can I have a empty page before the next chapter > without a page number? Do I have to write: \page =empty. ? > > Ursula Hermann > > > __ > _ 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 ___ ___ 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] Changes \setuphead
Hi Ursula, If you replace the \startsetups[chapter:before] with the following, you obtain a page without the page number: \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setuppagenumbering[state=stop] \setupbackgrounds[page][background=color,backgroundcolor=gray] \page[right] \setuppagenumbering[state=start] \popbackground} \stopsetups However probably there is a better way to achieve what you want… Best regards: OK > On 21 Jan 2019, at 11:26, Ursula Hermann wrote: > > Hello List! > > It is a long time ago, that I have written the last mail to you. > Thank you Taco so much, because for the new example of the Recent changes > from 17.January 2019. Because: Modyfying the page before a chapter is > something, that i can need. I mean this one: > > % next five lines just to show the effect on this wiki > \setuppapersize[A8][A5,landscape] > \setuppaper[nx=4, ny=2] > \setuplayout[page][location=middle, marking=on] > \setuparranging [XY] > \setupbodyfont[6pt] > > % actual example starts here > \setuppagenumbering > [alternative=doublesided] > > \startsetups [chapter:before] > \doifoddpageelse > {} > {\pushbackground[page] > \setupbackgrounds[page][background=color,backgroundcolor=gray] > \page[right] > \popbackground} > \stopsetups > > \setuphead > [chapter] > [page=yes, >before=\directsetup{chapter:before}] > > \starttext > > \startchapter[title={Knuth}] > \dorecurse{2}{\samplefile{knuth}} > \stopchapter > > \startchapter[title={Ward}] > \dorecurse{1}{\samplefile{ward}} > \stopchapter > > \startchapter[title={Zapf}] > \dorecurse{2}{\samplefile{zapf}} > \stopchapter > > > \stoptext > > I have a question: how can I have a empty page before the next chapter > without a page number? Do I have to write: \page =empty. ? > > Ursula Hermann > > > ___ > 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 ___
[NTG-context] Changes \setuphead
Hello List! It is a long time ago, that I have written the last mail to you. Thank you Taco so much, because for the new example of the Recent changes from 17.January 2019. Because: Modyfying the page before a chapter is something, that i can need. I mean this one: % next five lines just to show the effect on this wiki \setuppapersize[A8][A5,landscape] \setuppaper[nx=4, ny=2] \setuplayout[page][location=middle, marking=on] \setuparranging [XY] \setupbodyfont[6pt] % actual example starts here \setuppagenumbering [alternative=doublesided] \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=gray] \page[right] \popbackground} \stopsetups \setuphead [chapter] [page=yes, before=\directsetup{chapter:before}] \starttext \startchapter[title={Knuth}] \dorecurse{2}{\samplefile{knuth}} \stopchapter \startchapter[title={Ward}] \dorecurse{1}{\samplefile{ward}} \stopchapter \startchapter[title={Zapf}] \dorecurse{2}{\samplefile{zapf}} \stopchapter \stoptext I have a question: how can I have a empty page before the next chapter without a page number? Do I have to write: \page =empty. ? Ursula Hermann ___ 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] How to adjust inter item vertical space
Hi, You can define your own white space and then attribute it to each item, as in the following: \setupwhitespace[big] \startsetups[mywhitespace] \setupwhitespace[small] \setupblank[small] \stopsetups \setupitemize[each][inner=\directsetup{mywhitespace}] \starttext \input knuth \startitemize \dorecurse{3}{% \startitem \input ward \stopitem} \stopitemize \stoptext Best regards: OK > On 16 Jan 2019, at 10:48, jdh wrote: > > > > I want to fit a page with an itemized group of items. > The normal vertical spacing is to large and the [packed] doesn't give enough > seperation between > items. I should think that there's a simple way to adjust this with > \setupitemize command or even with \startitemize. Is there? > > I did try \setupitemize[inbetween=\whitespace[medium]] , but it didn't do > much or seemed to be applied > to every line and not just between item and 'medium' doesn't give much > information. Is there some way to specify a measurement to seperate between > items such as .5cm for example? > > > > Thanks > ___ > 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] MetaFun: how to check the number of arguments
On 1/16/2019 12:53 AM, Jeong Dal wrote: Dear Hans, Thank you for a solution. In my memory, it is possible to check the argument in Lua, so I hope that there is a similar method in MetaFun. It may be easier to draw grid using lines instead of squares. vardef textlength(text t) = save n ; n := 0 ; for i = t : n := n + 1 ; endfor; n enddef; def drawGridF (expr nb) (text s) = if textlength(s) = 0 : draw textext("A grid!"); else : path p ; picture pic ; numeric n; p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; fi ; enddef; Thank you again. Best regards, Dalyoung 2019. 1. 16. 오전 2:04, Hans Hagen <mailto:j.ha...@xs4all.nl>> 작성: On 1/14/2019 10:44 PM, Jeong Dal wrote: Dear all, In the following sample, it draws squares with label which is given. I’d like to know how to check the number of elements in the second argument? If it is 0, then I just draw grids only. Thank you for reading. Best regards, Dalyoung \startbuffer[defs] def drawGridF (expr nb) (text s) = p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; enddef; \stopbuffer \startbuffer[3x3b] wu := \MPvar{width}; drawGridF (3) (1,2,3,0,1, 1,4,5,8); \stopbuffer \starttext \setupMPvariables[width=30pt] \processMPbuffer[defs,3x3b] \stoptext \startbuffer[defs] def drawGridF (expr nb) (text s) = path p ; picture pic ; numeric n; p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; if n == 0 : draw textext("A grid!"); fi ; enddef; \stopbuffer \startbuffer[3x3b] wu := \MPvar{width}; drawGridF (3) (1,2,3,0,1, 1,4,5,8); currentpicture := currentpicture shifted (bbwidth(currentpicture),0); drawGridF (3) (); \stopbuffer \setupMPvariables[width=30pt] \processMPbuffer[defs,3x3b] 2019. 1. 14. 오후 8:00, ntg-context-requ...@ntg.nl <mailto:ntg-context-requ...@ntg.nl> 작성: Send ntg-context mailing list submissions to ntg-context@ntg.nl <mailto:ntg-context@ntg.nl> To subscribe or unsubscribe via the World Wide Web, visit https://mailman.ntg.nl/mailman/listinfo/ntg-context or, via email, send a message with subject or body 'help' to ntg-context-requ...@ntg.nl You can reach the person managing the list at ntg-context-ow...@ntg.nl When replying, please edit your Subject line so it is more specific than "Re: Contents of ntg-context digest..." Today's Topics: 1. Re: Manipulating the left blank page when chapter starts on the right page (Wolfgang Schuster) 2. Re: Footnotes in float combinations missing in output (Wolfgang Schuster) 3. Re: Manipulating the left blank page when chapter starts on the right page (Jan U. Hasecke) -- Message: 1 Date: Sun, 13 Jan 2019 16:56:40 +0100 From: Wolfgang Schuster To: mailing list for ConTeXt users , "Jan U. Hasecke" Subject: Re: [NTG-context] Manipulating the left blank page when chapter starts on the right page Message-ID: Content-Type: text/plain; charset=utf-8; format=flowed Jan U. Hasecke schrieb am 12.01.19 um 22:08: Hi Aditya, Am 12.01.19 um 20:11 schrieb Aditya Mahajan: On Sat, 12 Jan 2019, Jan U. Hasecke wrote: Hi all, in my document \startchapter and \starttitle starts a new chapter on the right (odd) page. So sometimes, there is a blank even page just before a new chapter. I would like to manipulate this blank even page. There are several things I would like to do, eg. having no headers and footers, setting the background color to a named color, placing an image or some graphics on the page. Is there a way to define such a page, name it and call it in \startchapter so that it is placed on the left side. See https://tex.stackexchange.com/q/457428/323 Thanks a lot, but I wasn't looking for a way to just delete page numbers but to style the empty page in arbitrary ways. Maybe it is better to do this manually. I would let chapter open on even pages too and just insert a styled page by hand. Here is a example which shows how you can change the background color of a empty page before the chapter title. \setuppagenumbering [alternative=doublesided] \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=black] \page[empty,right] \popbackground} \stopsetups \setuphead [chapter] [page=yes, before=\directsetup{chapter:before}] \starttext \startchapter[t
Re: [NTG-context] MetaFun: how to check the number of arguments
Dear Hans, Thank you for a solution. In my memory, it is possible to check the argument in Lua, so I hope that there is a similar method in MetaFun. It may be easier to draw grid using lines instead of squares. Thank you again. Best regards, Dalyoung > 2019. 1. 16. 오전 2:04, Hans Hagen 작성: > > On 1/14/2019 10:44 PM, Jeong Dal wrote: >> Dear all, >> In the following sample, it draws squares with label which is given. >> I’d like to know how to check the number of elements in the second argument? >> If it is 0, then I just draw grids only. >> Thank you for reading. >> Best regards, >> Dalyoung >> >> \startbuffer[defs] >> def drawGridF (expr nb) (text s) = >> p := unitsquare scaled wu; >> n:= 0; >> for m = s: >> i:= n mod nb; >> j:= n div nb; >> pic := image (draw p; label(textext(m), center p); ); >> draw pic shifted (i*wu, j*wu); >> n:= n+ 1; >> endfor; >> enddef; >> \stopbuffer >> \startbuffer[3x3b] >> wu := \MPvar{width}; >> drawGridF (3) (1,2,3,0,1, 1,4,5,8); >> \stopbuffer >> \starttext >> \setupMPvariables[width=30pt] >> \processMPbuffer[defs,3x3b] >> \stoptext > > > \startbuffer[defs] > def drawGridF (expr nb) (text s) = >path p ; >picture pic ; >numeric n; > p := unitsquare scaled wu; > n:= 0; > for m = s: > i:= n mod nb; > j:= n div nb; > pic := image (draw p; label(textext(m), center p); ); > draw pic shifted (i*wu, j*wu); > n:= n+ 1; > endfor; >if n == 0 : >draw textext("A grid!"); >fi ; > enddef; > \stopbuffer > > \startbuffer[3x3b] > wu := \MPvar{width}; > drawGridF (3) (1,2,3,0,1, 1,4,5,8); > currentpicture := currentpicture shifted (bbwidth(currentpicture),0); > drawGridF (3) (); > \stopbuffer > > \setupMPvariables[width=30pt] > \processMPbuffer[defs,3x3b] > > > > >>> 2019. 1. 14. 오후 8:00, ntg-context-requ...@ntg.nl 작성: >>> >>> Send ntg-context mailing list submissions to >>> ntg-context@ntg.nl >>> >>> To subscribe or unsubscribe via the World Wide Web, visit >>> https://mailman.ntg.nl/mailman/listinfo/ntg-context >>> or, via email, send a message with subject or body 'help' to >>> ntg-context-requ...@ntg.nl >>> >>> You can reach the person managing the list at >>> ntg-context-ow...@ntg.nl >>> >>> When replying, please edit your Subject line so it is more specific >>> than "Re: Contents of ntg-context digest..." >>> >>> >>> Today's Topics: >>> >>> 1. Re: Manipulating the left blank page when chapter starts on >>> the right page (Wolfgang Schuster) >>> 2. Re: Footnotes in float combinations missing in output >>> (Wolfgang Schuster) >>> 3. Re: Manipulating the left blank page when chapter starts on >>> the right page (Jan U. Hasecke) >>> >>> >>> -- >>> >>> Message: 1 >>> Date: Sun, 13 Jan 2019 16:56:40 +0100 >>> From: Wolfgang Schuster >>> To: mailing list for ConTeXt users , "Jan U. >>> Hasecke" >>> Subject: Re: [NTG-context] Manipulating the left blank page when >>> chapter starts on the right page >>> Message-ID: >>> Content-Type: text/plain; charset=utf-8; format=flowed >>> >>> Jan U. Hasecke schrieb am 12.01.19 um 22:08: >>>> Hi Aditya, >>>> >>>> Am 12.01.19 um 20:11 schrieb Aditya Mahajan: >>>>> On Sat, 12 Jan 2019, Jan U. Hasecke wrote: >>>>> >>>>>> Hi all, >>>>>> >>>>>> in my document \startchapter and \starttitle starts a new chapter on the >>>>>> right (odd) page. So sometimes, there is a blank even page just before a >>>>>> new chapter. >>>>>> >>>>>> I would like to manipulate this blank even page. >>>>>> >>>>>> There are several things I would like to do, eg. having no headers and >>>>>> footers, setting the background color to a named color, placing an image >>>>>> or some graphics on the page. >>>>>> >>>>>> Is there a way to define such a page, name it and ca
Re: [NTG-context] MetaFun: how to check the number of arguments
On 1/14/2019 10:44 PM, Jeong Dal wrote: Dear all, In the following sample, it draws squares with label which is given. I’d like to know how to check the number of elements in the second argument? If it is 0, then I just draw grids only. Thank you for reading. Best regards, Dalyoung \startbuffer[defs] def drawGridF (expr nb) (text s) = p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; enddef; \stopbuffer \startbuffer[3x3b] wu := \MPvar{width}; drawGridF (3) (1,2,3,0,1, 1,4,5,8); \stopbuffer \starttext \setupMPvariables[width=30pt] \processMPbuffer[defs,3x3b] \stoptext \startbuffer[defs] def drawGridF (expr nb) (text s) = path p ; picture pic ; numeric n; p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; if n == 0 : draw textext("A grid!"); fi ; enddef; \stopbuffer \startbuffer[3x3b] wu := \MPvar{width}; drawGridF (3) (1,2,3,0,1, 1,4,5,8); currentpicture := currentpicture shifted (bbwidth(currentpicture),0); drawGridF (3) (); \stopbuffer \setupMPvariables[width=30pt] \processMPbuffer[defs,3x3b] 2019. 1. 14. 오후 8:00, ntg-context-requ...@ntg.nl 작성: Send ntg-context mailing list submissions to ntg-context@ntg.nl To subscribe or unsubscribe via the World Wide Web, visit https://mailman.ntg.nl/mailman/listinfo/ntg-context or, via email, send a message with subject or body 'help' to ntg-context-requ...@ntg.nl You can reach the person managing the list at ntg-context-ow...@ntg.nl When replying, please edit your Subject line so it is more specific than "Re: Contents of ntg-context digest..." Today's Topics: 1. Re: Manipulating the left blank page when chapter starts on the right page (Wolfgang Schuster) 2. Re: Footnotes in float combinations missing in output (Wolfgang Schuster) 3. Re: Manipulating the left blank page when chapter starts on the right page (Jan U. Hasecke) -- Message: 1 Date: Sun, 13 Jan 2019 16:56:40 +0100 From: Wolfgang Schuster To: mailing list for ConTeXt users , "Jan U. Hasecke" Subject: Re: [NTG-context] Manipulating the left blank page when chapter starts on the right page Message-ID: Content-Type: text/plain; charset=utf-8; format=flowed Jan U. Hasecke schrieb am 12.01.19 um 22:08: Hi Aditya, Am 12.01.19 um 20:11 schrieb Aditya Mahajan: On Sat, 12 Jan 2019, Jan U. Hasecke wrote: Hi all, in my document \startchapter and \starttitle starts a new chapter on the right (odd) page. So sometimes, there is a blank even page just before a new chapter. I would like to manipulate this blank even page. There are several things I would like to do, eg. having no headers and footers, setting the background color to a named color, placing an image or some graphics on the page. Is there a way to define such a page, name it and call it in \startchapter so that it is placed on the left side. See https://tex.stackexchange.com/q/457428/323 Thanks a lot, but I wasn't looking for a way to just delete page numbers but to style the empty page in arbitrary ways. Maybe it is better to do this manually. I would let chapter open on even pages too and just insert a styled page by hand. Here is a example which shows how you can change the background color of a empty page before the chapter title. \setuppagenumbering [alternative=doublesided] \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=black] \page[empty,right] \popbackground} \stopsetups \setuphead [chapter] [page=yes, before=\directsetup{chapter:before}] \starttext \startchapter[title={Knuth}] \dorecurse{10}{\samplefile{knuth}} \stopchapter \startchapter[title={Zapf}] \dorecurse{10}{\samplefile{zapf}} \stopchapter \startchapter[title={Ward}] \dorecurse{10}{\samplefile{ward}} \stopchapter \stoptext Wolfgang -- Message: 2 Date: Sun, 13 Jan 2019 21:06:42 +0100 From: Wolfgang Schuster To: mailing list for ConTeXt users , Lars Subject: Re: [NTG-context] Footnotes in float combinations missing in output Message-ID: Content-Type: text/plain; charset=utf-8; format=flowed Lars schrieb am 09.01.19 um 23:01: Hi there, hi Hans, I just want to let you know that footnotes insterted in float-combinations don't get rendered properly, i. e. only the last footnote is placed i
[NTG-context] MetaFun: how to check the number of arguments
Dear all, In the following sample, it draws squares with label which is given. I’d like to know how to check the number of elements in the second argument? If it is 0, then I just draw grids only. Thank you for reading. Best regards, Dalyoung \startbuffer[defs] def drawGridF (expr nb) (text s) = p := unitsquare scaled wu; n:= 0; for m = s: i:= n mod nb; j:= n div nb; pic := image (draw p; label(textext(m), center p); ); draw pic shifted (i*wu, j*wu); n:= n+ 1; endfor; enddef; \stopbuffer \startbuffer[3x3b] wu := \MPvar{width}; drawGridF (3) (1,2,3,0,1, 1,4,5,8); \stopbuffer \starttext \setupMPvariables[width=30pt] \processMPbuffer[defs,3x3b] \stoptext > 2019. 1. 14. 오후 8:00, ntg-context-requ...@ntg.nl 작성: > > Send ntg-context mailing list submissions to > ntg-context@ntg.nl > > To subscribe or unsubscribe via the World Wide Web, visit > https://mailman.ntg.nl/mailman/listinfo/ntg-context > or, via email, send a message with subject or body 'help' to > ntg-context-requ...@ntg.nl > > You can reach the person managing the list at > ntg-context-ow...@ntg.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of ntg-context digest..." > > > Today's Topics: > > 1. Re: Manipulating the left blank page when chapter starts on > the right page (Wolfgang Schuster) > 2. Re: Footnotes in float combinations missing in output > (Wolfgang Schuster) > 3. Re: Manipulating the left blank page when chapter starts on > the right page (Jan U. Hasecke) > > > -- > > Message: 1 > Date: Sun, 13 Jan 2019 16:56:40 +0100 > From: Wolfgang Schuster > To: mailing list for ConTeXt users , "Jan U. > Hasecke" > Subject: Re: [NTG-context] Manipulating the left blank page when > chapter starts on the right page > Message-ID: > Content-Type: text/plain; charset=utf-8; format=flowed > > Jan U. Hasecke schrieb am 12.01.19 um 22:08: >> Hi Aditya, >> >> Am 12.01.19 um 20:11 schrieb Aditya Mahajan: >>> On Sat, 12 Jan 2019, Jan U. Hasecke wrote: >>> >>>> Hi all, >>>> >>>> in my document \startchapter and \starttitle starts a new chapter on the >>>> right (odd) page. So sometimes, there is a blank even page just before a >>>> new chapter. >>>> >>>> I would like to manipulate this blank even page. >>>> >>>> There are several things I would like to do, eg. having no headers and >>>> footers, setting the background color to a named color, placing an image >>>> or some graphics on the page. >>>> >>>> Is there a way to define such a page, name it and call it in >>>> \startchapter so that it is placed on the left side. >>> See https://tex.stackexchange.com/q/457428/323 >> Thanks a lot, but I wasn't looking for a way to just delete page numbers >> but to style the empty page in arbitrary ways. >> >> Maybe it is better to do this manually. >> >> I would let chapter open on even pages too and just insert a styled page >> by hand. > > Here is a example which shows how you can change the background color > of a empty page before the chapter title. > > \setuppagenumbering > [alternative=doublesided] > > \startsetups [chapter:before] > \doifoddpageelse > {} > {\pushbackground[page] > \setupbackgrounds[page][background=color,backgroundcolor=black] > \page[empty,right] > \popbackground} > \stopsetups > > \setuphead > [chapter] > [page=yes, >before=\directsetup{chapter:before}] > > \starttext > > \startchapter[title={Knuth}] > \dorecurse{10}{\samplefile{knuth}} > \stopchapter > > \startchapter[title={Zapf}] > \dorecurse{10}{\samplefile{zapf}} > \stopchapter > > \startchapter[title={Ward}] > \dorecurse{10}{\samplefile{ward}} > \stopchapter > > \stoptext > > Wolfgang > > > > -- > > Message: 2 > Date: Sun, 13 Jan 2019 21:06:42 +0100 > From: Wolfgang Schuster > To: mailing list for ConTeXt users , Lars > > Subject: Re: [NTG-context] Footnotes in float combinations missing in > output > Message-ID: > Content-Type: text/plain; charset=utf-8; format=flowed > > Lars schrieb am 09.01.19 um 23:01: >> Hi there, hi Hans, >> >> I just want to let you know that footnotes insterted in >> float-combinatio
Re: [NTG-context] Manipulating the left blank page when chapter starts on the right page
Jan U. Hasecke schrieb am 14.01.19 um 08:39: Am 13.01.19 um 16:56 schrieb Wolfgang Schuster: Here is a example which shows how you can change the background color of a empty page before the chapter title. \setuppagenumbering [alternative=doublesided] \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=black] \page[empty,right] \popbackground} \stopsetups \setuphead [chapter] [page=yes, before=\directsetup{chapter:before}] \starttext \startchapter[title={Knuth}] \dorecurse{10}{\samplefile{knuth}} \stopchapter \startchapter[title={Zapf}] \dorecurse{10}{\samplefile{zapf}} \stopchapter \startchapter[title={Ward}] \dorecurse{10}{\samplefile{ward}} \stopchapter \stoptext Thanks a lot Wolfgang! This was just the thing I was looking for. These setups seems to be the golden bullet in ConTeXt but I often have difficulties to understand the mechanism. If you mean the setups-environment with setups you’re wrong because this is only a alternative way to a command (e.g. \define\mycommand{...}). The main point is that you finish the page before the section title and check on the new page whether you’re on a odd or even numbered page. When the test tells you that you’re on a even numbered page you know there is a empty left page before the chapter which can be used to add something special. Below is a simplified example for the method. \starttext \dorecurse{10}{\samplefile{knuth}} \page \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=red] \page[empty] \popbackground} \dorecurse{10}{\samplefile{zapf}} \stoptext I'll try to wikify this later this week. The push-pop-background pair is mentionend in x-setups-overview together with some other push-pop-pairs or push single commands. Are they documented somewhere? Most of these push/pop commands are used for internal stuff (or sometimes in styles) which means there is no documentation for them. The purpose of them is to store the state of a command (e.g. the page background) before you change its values, afterwards you can just revert back to the previously saved state. As these commands are no real environments they are listed as separate commands but it’s possible I will change this. 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Manipulating the left blank page when chapter starts on the right page
Am 13.01.19 um 16:56 schrieb Wolfgang Schuster: > Here is a example which shows how you can change the background color > of a empty page before the chapter title. > > \setuppagenumbering > [alternative=doublesided] > > \startsetups [chapter:before] > \doifoddpageelse > {} > {\pushbackground[page] > \setupbackgrounds[page][background=color,backgroundcolor=black] > \page[empty,right] > \popbackground} > \stopsetups > > \setuphead > [chapter] > [page=yes, > before=\directsetup{chapter:before}] > > \starttext > > \startchapter[title={Knuth}] > \dorecurse{10}{\samplefile{knuth}} > \stopchapter > > \startchapter[title={Zapf}] > \dorecurse{10}{\samplefile{zapf}} > \stopchapter > > \startchapter[title={Ward}] > \dorecurse{10}{\samplefile{ward}} > \stopchapter > > \stoptext Thanks a lot Wolfgang! This was just the thing I was looking for. These setups seems to be the golden bullet in ConTeXt but I often have difficulties to understand the mechanism. I'll try to wikify this later this week. The push-pop-background pair is mentionend in x-setups-overview together with some other push-pop-pairs or push single commands. Are they documented somewhere? juh ___ 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] Manipulating the left blank page when chapter starts on the right page
Jan U. Hasecke schrieb am 12.01.19 um 22:08: Hi Aditya, Am 12.01.19 um 20:11 schrieb Aditya Mahajan: On Sat, 12 Jan 2019, Jan U. Hasecke wrote: Hi all, in my document \startchapter and \starttitle starts a new chapter on the right (odd) page. So sometimes, there is a blank even page just before a new chapter. I would like to manipulate this blank even page. There are several things I would like to do, eg. having no headers and footers, setting the background color to a named color, placing an image or some graphics on the page. Is there a way to define such a page, name it and call it in \startchapter so that it is placed on the left side. See https://tex.stackexchange.com/q/457428/323 Thanks a lot, but I wasn't looking for a way to just delete page numbers but to style the empty page in arbitrary ways. Maybe it is better to do this manually. I would let chapter open on even pages too and just insert a styled page by hand. Here is a example which shows how you can change the background color of a empty page before the chapter title. \setuppagenumbering [alternative=doublesided] \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=black] \page[empty,right] \popbackground} \stopsetups \setuphead [chapter] [page=yes, before=\directsetup{chapter:before}] \starttext \startchapter[title={Knuth}] \dorecurse{10}{\samplefile{knuth}} \stopchapter \startchapter[title={Zapf}] \dorecurse{10}{\samplefile{zapf}} \stopchapter \startchapter[title={Ward}] \dorecurse{10}{\samplefile{ward}} \stopchapter \stoptext 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] whitespace inside a description
Pablo Rodriguez schrieb am 30.11.18 um 19:36: Dear list, I have the following sample: \setupwhitespace[big] \startsetups[small:whitespace] \setupwhitespace[small] \stopsetups \definedescription [description] [setups={small:whitespace}, inbetween={\directsetup[small:whitespace]}] \starttext \input knuth \startdescription{Knuth} \input knuth \stopdescription \stoptext How can I get a different whitespace inside the description? \setupdescription [description] [style={\setupwhitespace[small]}] 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
[NTG-context] whitespace inside a description
Dear list, I have the following sample: \setupwhitespace[big] \startsetups[small:whitespace] \setupwhitespace[small] \stopsetups \definedescription [description] [setups={small:whitespace}, inbetween={\directsetup[small:whitespace]}] \starttext \input knuth \startdescription{Knuth} \input knuth \stopdescription \stoptext How can I get a different whitespace inside the description? Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] Disable overlay on chapter pages
On Fri, Aug 4, 2017 at 9:53 AM, Hans Hagen <pra...@wxs.nl> wrote: > On 8/3/2017 8:11 PM, Mikael P. Sundqvist wrote: > >> that solves the other problem that appeared. What about the one I >> originally posted in this thread? Is it possible to pause backgrounds >> on chapter pages? > > one of the many ways ... > > \definelayer > [chapter] > [width=\paperwidth, >height=\paperheight] > > \defineoverlay > [pagebackground] > [\directsetup{pagebackground}] > > \setupbackgrounds > [page] > [background=pagebackground] > > \startsetups pagebackground > \doifelsemode {chapterpage} { > \setlayer > [chapter] > [preset=middle] > {\scale[width=\textwidth]{CHAPTER}} > \globaldisablemode[chapterpage] > } { > \setlayer > [chapter] > [preset=middle] > {\scale[width=\textwidth]{WHATEVER}} > } > \placelayer[chapter] > \stopsetups > > \startsetups chapter:before > \globalenablemode[chapterpage] > \stopsetups > > \setuphead > [chapter] > [before=\setup{chapter:before}] > > \starttext > \chapter{foo} test \page test > \chapter{bar} test \page test > \stoptext > > - > 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 > ___ Many thanks! It now works as expected. Just if someone finds this thread in the future, to get the texts into the margin, I ended up with something like the code below. /Mikael \showframe \setuppagenumbering[alternative=doublesided] \setuplayout[ %alternative=doublesided, location=middle, width=10cm, backspace=2in, ] \definelayer [chapter] [width=\paperwidth, height=\paperheight, location=right] \defineoverlay [pagebackground] [\directsetup{pagebackground}] \setupbackgrounds [page] [background=pagebackground] \startsetups pagebackground \doifelsemode {chapterpage} { \setlayer [chapter] [x=\dimexpr\backspace+\textwidth+\rightmargindistance\relax, y=3in, location={right,bottom}] {\getmarking[chapternumber]} \globaldisablemode[chapterpage] } { \setlayer [chapter] [x=\dimexpr\backspace+\textwidth+\rightmargindistance\relax, y=3in, location={right,bottom}] {\doifrightpageelse{\getmarking[chapter]}{}} } \placelayer[chapter] \stopsetups \startsetups chapter:before \globalenablemode[chapterpage] \stopsetups \define[2]\mychaptercommand{\midaligned{#2}} \setuphead [chapter] [align=middle,style=\tfa,align=middle,command=\mychaptercommand,before=\setup{chapter:before}] \starttext \chapter{foo} test \page test \page test \page test \chapter{bar} test \page test \page test \page test \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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Disable overlay on chapter pages
On 8/3/2017 8:11 PM, Mikael P. Sundqvist wrote: that solves the other problem that appeared. What about the one I originally posted in this thread? Is it possible to pause backgrounds on chapter pages? one of the many ways ... \definelayer [chapter] [width=\paperwidth, height=\paperheight] \defineoverlay [pagebackground] [\directsetup{pagebackground}] \setupbackgrounds [page] [background=pagebackground] \startsetups pagebackground \doifelsemode {chapterpage} { \setlayer [chapter] [preset=middle] {\scale[width=\textwidth]{CHAPTER}} \globaldisablemode[chapterpage] } { \setlayer [chapter] [preset=middle] {\scale[width=\textwidth]{WHATEVER}} } \placelayer[chapter] \stopsetups \startsetups chapter:before \globalenablemode[chapterpage] \stopsetups \setuphead [chapter] [before=\setup{chapter:before}] \starttext \chapter{foo} test \page test \chapter{bar} test \page test \stoptext - 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] whitespace between endnotes
Exactly what I was looking for. Thanks! Hans van der Meer > On 14 Jul 2017, at 17:07, Pablo Rodriguez <oi...@gmx.es> wrote: > > On 07/14/2017 02:44 PM, Meer, Hans van der wrote: >> \placenotes[endnote] puts a list of endnotes spaced out with the >> setting of \setupwhitespace. Is there a means to keep >> \setupwhitespace undisturbed but changing this for the endnotes >> alone? Some parameter to be specified in \setupnote, \setupnotation >> or one of its friends perhaps? > Hans, > > I guess this is what you need: > >\startsetups[setups:endnotes] >\setupwhitespace[5em] >\stopsetups > >\setupnote >[endnote] >[before=\directsetup{setups:endnotes}] > >\starttext >\dorecurse{5}{\input zapf\endnote{\input knuth}} >\placenotes[endnote] >\stoptext > > I hope it helps, > > Pablo > -- > http://www.ousia.tk > ___ > 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] whitespace between endnotes
On 07/14/2017 02:44 PM, Meer, Hans van der wrote: > \placenotes[endnote] puts a list of endnotes spaced out with the > setting of \setupwhitespace. Is there a means to keep > \setupwhitespace undisturbed but changing this for the endnotes > alone? Some parameter to be specified in \setupnote, \setupnotation > or one of its friends perhaps? Hans, I guess this is what you need: \startsetups[setups:endnotes] \setupwhitespace[5em] \stopsetups \setupnote [endnote] [before=\directsetup{setups:endnotes}] \starttext \dorecurse{5}{\input zapf\endnote{\input knuth}} \placenotes[endnote] \stoptext I hope it helps, Pablo -- http://www.ousia.tk ___ 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] hunting a lua stack error
This is the error message lua error > lua error on line 112 in file c_09-02_Evans.tex: C stack overflow stack traceback: [C]: in function 'type' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:373: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:367> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ... [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:342: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:317> [C]: in function 'tostring' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ini.lua:730: in function 'pdfshareobjectreference' ...eXt/tex/texmf-context/tex/context/base/mkiv/lpdf-ano.lua:664: in function 'prerollreference' ...eXt/tex/texmf-context/tex/context/base/mkiv/node-ref.lua:601: in function 'setreference' ...eXt/tex/texmf-context/tex/context/base/mkiv/node-ref.lua:847: in function <...eXt/tex/texmf-context/tex/context/base/mkiv/node-ref.lua:844> (...tail calls...) the cause is the line: \cite[Evans, Carman, and Thorndike 2010] the problem: \cite[{{Evans, Carman, and Throndike 2010}}] is not fix the oddity: the file is full of entries like \cite[A, B, and C 2017] and worse. If I comment out the offending line, the file processes as it should. My test file does not duplicate the problem: it just shows another one ( that may or may not be relevant): \definedescription[BibItem][ width=broad, margin=1.5pc, indenting={no}, indentnext=no, alternative=hanging, hang=1, headcommand=\gobbleoneargument, align=right, before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] \definereferenceformat [cite] [type=title,left={},right={}] \definereferenceformat [bibpage] [type=page] %\setupinteraction[state=start] \starttext \dorecurse{10}{\cite[A],\\ \cite[A and B],\\ \cite[{{A, B, and C}}]\blank} \page \startbibitem[A] A \stopbibitem \startbibitem[A and B] A and B \stopbibitem \startbibitem[{{A, B, and C}}] A, B, and C \stopbibitem \stoptext The file processes but does not show the “A, B, and C” when interaction is activated. Alan ___ 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] list items not broken in lines
Dear list, I have the following sample: \setupinteraction[state=start, color=, style=, contrastcolor=] \enabledirectives[references.border] \startsetups[placelist:section] \startalign[center] \setupinterlinespace[line=2.8ex] \placelist[section] [alternative=d, pagenumber=no, headnumber=no, style=\itx, criterium=local] \par \stopalign \stopsetups \setuplist[chapter][after=\directsetup{placelist:section}] \starttext \placelist[chapter] \dorecurse{4}{\chapter{Chapter} \dorecurse{20}{\section{Section from This Chapter}}} \stoptext I would like to avoid line breaks in section items. Which would be the right way of doing it? This would be similar (I think) to know how to get the "{this is a expression}" with no line break inside (and not using "~"). Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] new lua/stack error
Excellent, Hans. Many thanks! Alan On Fri, Feb 24, 2017 at 5:21 AM, Hans Hagen <pra...@wxs.nl> wrote: > On 2/23/2017 10:41 PM, Alan Bowen wrote: > >> In my larger document (approx 600 pages, over 1000 references) >> problematic entries like \cite[{{A, B, and C}}] did not display at all, >> though the document did process without claims of stack errors etc. >> Curiously, >> \goto{A, B, and C}[{{A, B, and C}}] >> does work as expected. >> > > i'll upload a beta that support this: > > \setupinteraction[state=start] > > \starttext > > \startchapter[reference={{A, B, and C}},title={Foo}] > > \in{IN}[name{A, B, and C}] > > \in{IN}[name(A, B, and C)] > > \stopchapter > > you need to be aware of the fact that references have some kind of syntax > and are parsed (so that we only need one system for every kind of > referencing); most make only sense for \goto but parsing happens anyway for > \in and \at so i hooked name() into it, similar to [page(123)] we can have > [name(abc)] now > > Hans > > > Alan >> >> On Thu, Feb 23, 2017 at 4:12 PM, Alan Bowen <bowenala...@gmail.com >> <mailto:bowenala...@gmail.com>> wrote: >> >> Thanks, Hans! That does work nicely. >> >> On Thu, Feb 23, 2017 at 3:42 PM, Hans Hagen <pra...@wxs.nl >> <mailto:pra...@wxs.nl>> wrote: >> >> On 2/22/2017 6:21 PM, Alan Bowen wrote: >> >> Here is the file that I have been working with: >> >> \installlanguage[packed][en] >> \setuplanguage[packed][spacing=packed] >> \startsetups[tightspace] >> \spaceskip 0.5\interwordspace plus .5\interwordstretch minus >> \interwordshrink >> \stopsetups >> >> \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={ >> #1}]} >> \def\startbibitem{\dosingleempty\dostartbibitem} >> \def\stopbibitem{\stopBibItem} >> >> \definedescription[BibItem][ >> width=broad, >> margin=1.5pc, >> indenting={no}, >> indentnext=no, >> alternative=hanging, >> hang=1, >> headcommand=\gobbleoneargument, >> align=right, >> before={\directsetup{tightspace}\bgroup\language[packed]}, >> after={\egroup}, >> ] >> >> \definereferenceformat [cite] [type=title,left={},right={}] >> \definereferenceformat [bibpage] [type=page] >> >> \starttext >> >> \startbibitem[A, B, and C]\stopbibitem % TEST by commenting >> these >> %\startbibitem[A{,} B{,} and C]\stopbibitem% lines out >> >> \startbibitem[ABC]\stopbibitem >> \startbibitem[A]\stopbibitem >> \startbibitem[B]\stopbibitem >> \startbibitem[C]\stopbibitem >> >> * \cite[A, B, and C] \qquad{\red output should be: A{,} >> B{,} and C} >> >> **\cite[ABC] \qquad{\red output should be: ABC} >> >> ***\cite[A], \cite[B], \cite[C] \qquad{\red output should >> be: A, B, C} >> >> \cite[A]\cite[B]\cite[C] \qquad{\red output should be: >> ABC} >> >> \stoptext >> >> >> references can be a comma separated list, so >> >> A, B, and C >> >> is actually three tags: "A" "B" "and C" >> >> so, you run into parsing problems, so how to deal with: >> >> [A, B, and C] >> >> maybe: >> >> [{A, B, and C}] >> >> alas, in comma separated list the first level of {} is removed >> but we can cheat: >> >> [{{A, B, and C}}] >> >> works with \cite [{{A, B, and C}}] >> >> Hans >> >> >> - >> Hans Hagen | PRAGMA ADE >> Ridderstraat 27 | 8061 GH Hasselt | The Netherlands >>tel: 038 477 53 69 | www.pragma-ade.nl >> <http://www.pragma-ade.nl> | www.pragma-pod.nl >>
Re: [NTG-context] new lua/stack error
On 2/23/2017 10:41 PM, Alan Bowen wrote: In my larger document (approx 600 pages, over 1000 references) problematic entries like \cite[{{A, B, and C}}] did not display at all, though the document did process without claims of stack errors etc. Curiously, \goto{A, B, and C}[{{A, B, and C}}] does work as expected. i'll upload a beta that support this: \setupinteraction[state=start] \starttext \startchapter[reference={{A, B, and C}},title={Foo}] \in{IN}[name{A, B, and C}] \in{IN}[name(A, B, and C)] \stopchapter you need to be aware of the fact that references have some kind of syntax and are parsed (so that we only need one system for every kind of referencing); most make only sense for \goto but parsing happens anyway for \in and \at so i hooked name() into it, similar to [page(123)] we can have [name(abc)] now Hans Alan On Thu, Feb 23, 2017 at 4:12 PM, Alan Bowen <bowenala...@gmail.com <mailto:bowenala...@gmail.com>> wrote: Thanks, Hans! That does work nicely. On Thu, Feb 23, 2017 at 3:42 PM, Hans Hagen <pra...@wxs.nl <mailto:pra...@wxs.nl>> wrote: On 2/22/2017 6:21 PM, Alan Bowen wrote: Here is the file that I have been working with: \installlanguage[packed][en] \setuplanguage[packed][spacing=packed] \startsetups[tightspace] \spaceskip 0.5\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} \def\startbibitem{\dosingleempty\dostartbibitem} \def\stopbibitem{\stopBibItem} \definedescription[BibItem][ width=broad, margin=1.5pc, indenting={no}, indentnext=no, alternative=hanging, hang=1, headcommand=\gobbleoneargument, align=right, before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] \definereferenceformat [cite] [type=title,left={},right={}] \definereferenceformat [bibpage] [type=page] \starttext \startbibitem[A, B, and C]\stopbibitem % TEST by commenting these %\startbibitem[A{,} B{,} and C]\stopbibitem% lines out \startbibitem[ABC]\stopbibitem \startbibitem[A]\stopbibitem \startbibitem[B]\stopbibitem \startbibitem[C]\stopbibitem * \cite[A, B, and C] \qquad{\red output should be: A{,} B{,} and C} **\cite[ABC] \qquad{\red output should be: ABC} ***\cite[A], \cite[B], \cite[C] \qquad{\red output should be: A, B, C} \cite[A]\cite[B]\cite[C] \qquad{\red output should be: ABC} \stoptext references can be a comma separated list, so A, B, and C is actually three tags: "A" "B" "and C" so, you run into parsing problems, so how to deal with: [A, B, and C] maybe: [{A, B, and C}] alas, in comma separated list the first level of {} is removed but we can cheat: [{{A, B, and C}}] works with \cite [{{A, B, and C}}] Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl <http://www.pragma-ade.nl> | www.pragma-pod.nl <http://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 <mailto:ntg-context@ntg.nl> / http://www.ntg.nl/mailman/listinfo/ntg-context <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/ <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 : h
Re: [NTG-context] new lua/stack error
In my larger document (approx 600 pages, over 1000 references) problematic entries like \cite[{{A, B, and C}}] did not display at all, though the document did process without claims of stack errors etc. Curiously, \goto{A, B, and C}[{{A, B, and C}}] does work as expected. Alan On Thu, Feb 23, 2017 at 4:12 PM, Alan Bowen <bowenala...@gmail.com> wrote: > Thanks, Hans! That does work nicely. > > On Thu, Feb 23, 2017 at 3:42 PM, Hans Hagen <pra...@wxs.nl> wrote: > >> On 2/22/2017 6:21 PM, Alan Bowen wrote: >> >>> Here is the file that I have been working with: >>> >>> \installlanguage[packed][en] >>> \setuplanguage[packed][spacing=packed] >>> \startsetups[tightspace] >>> \spaceskip 0.5\interwordspace plus .5\interwordstretch minus >>> \interwordshrink >>> \stopsetups >>> >>> \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} >>> \def\startbibitem{\dosingleempty\dostartbibitem} >>> \def\stopbibitem{\stopBibItem} >>> >>> \definedescription[BibItem][ >>> width=broad, >>> margin=1.5pc, >>> indenting={no}, >>> indentnext=no, >>> alternative=hanging, >>> hang=1, >>> headcommand=\gobbleoneargument, >>> align=right, >>> before={\directsetup{tightspace}\bgroup\language[packed]}, >>> after={\egroup}, >>> ] >>> >>> \definereferenceformat [cite] [type=title,left={},right={}] >>> \definereferenceformat [bibpage] [type=page] >>> >>> \starttext >>> >>> \startbibitem[A, B, and C]\stopbibitem % TEST by commenting these >>> %\startbibitem[A{,} B{,} and C]\stopbibitem% lines out >>> >>> \startbibitem[ABC]\stopbibitem >>> \startbibitem[A]\stopbibitem >>> \startbibitem[B]\stopbibitem >>> \startbibitem[C]\stopbibitem >>> >>> * \cite[A, B, and C] \qquad{\red output should be: A{,} B{,} and C} >>> >>> **\cite[ABC] \qquad{\red output should be: ABC} >>> >>> ***\cite[A], \cite[B], \cite[C] \qquad{\red output should be: A, B, C} >>> >>> \cite[A]\cite[B]\cite[C] \qquad{\red output should be: ABC} >>> >>> \stoptext >>> >> >> references can be a comma separated list, so >> >> A, B, and C >> >> is actually three tags: "A" "B" "and C" >> >> so, you run into parsing problems, so how to deal with: >> >> [A, B, and C] >> >> maybe: >> >> [{A, B, and C}] >> >> alas, in comma separated list the first level of {} is removed but we can >> cheat: >> >> [{{A, B, and C}}] >> >> works with \cite [{{A, B, and C}}] >> >> 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/list >> info/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] new lua/stack error
Thanks, Hans! That does work nicely. On Thu, Feb 23, 2017 at 3:42 PM, Hans Hagen <pra...@wxs.nl> wrote: > On 2/22/2017 6:21 PM, Alan Bowen wrote: > >> Here is the file that I have been working with: >> >> \installlanguage[packed][en] >> \setuplanguage[packed][spacing=packed] >> \startsetups[tightspace] >> \spaceskip 0.5\interwordspace plus .5\interwordstretch minus >> \interwordshrink >> \stopsetups >> >> \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} >> \def\startbibitem{\dosingleempty\dostartbibitem} >> \def\stopbibitem{\stopBibItem} >> >> \definedescription[BibItem][ >> width=broad, >> margin=1.5pc, >> indenting={no}, >> indentnext=no, >> alternative=hanging, >> hang=1, >> headcommand=\gobbleoneargument, >> align=right, >> before={\directsetup{tightspace}\bgroup\language[packed]}, >> after={\egroup}, >> ] >> >> \definereferenceformat [cite] [type=title,left={},right={}] >> \definereferenceformat [bibpage] [type=page] >> >> \starttext >> >> \startbibitem[A, B, and C]\stopbibitem % TEST by commenting these >> %\startbibitem[A{,} B{,} and C]\stopbibitem% lines out >> >> \startbibitem[ABC]\stopbibitem >> \startbibitem[A]\stopbibitem >> \startbibitem[B]\stopbibitem >> \startbibitem[C]\stopbibitem >> >> * \cite[A, B, and C] \qquad{\red output should be: A{,} B{,} and C} >> >> **\cite[ABC] \qquad{\red output should be: ABC} >> >> ***\cite[A], \cite[B], \cite[C] \qquad{\red output should be: A, B, C} >> >> \cite[A]\cite[B]\cite[C] \qquad{\red output should be: ABC} >> >> \stoptext >> > > references can be a comma separated list, so > > A, B, and C > > is actually three tags: "A" "B" "and C" > > so, you run into parsing problems, so how to deal with: > > [A, B, and C] > > maybe: > > [{A, B, and C}] > > alas, in comma separated list the first level of {} is removed but we can > cheat: > > [{{A, B, and C}}] > > works with \cite [{{A, B, and C}}] > > 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/list > info/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] new lua/stack error
On 2/22/2017 6:21 PM, Alan Bowen wrote: Here is the file that I have been working with: \installlanguage[packed][en] \setuplanguage[packed][spacing=packed] \startsetups[tightspace] \spaceskip 0.5\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} \def\startbibitem{\dosingleempty\dostartbibitem} \def\stopbibitem{\stopBibItem} \definedescription[BibItem][ width=broad, margin=1.5pc, indenting={no}, indentnext=no, alternative=hanging, hang=1, headcommand=\gobbleoneargument, align=right, before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] \definereferenceformat [cite] [type=title,left={},right={}] \definereferenceformat [bibpage] [type=page] \starttext \startbibitem[A, B, and C]\stopbibitem % TEST by commenting these %\startbibitem[A{,} B{,} and C]\stopbibitem% lines out \startbibitem[ABC]\stopbibitem \startbibitem[A]\stopbibitem \startbibitem[B]\stopbibitem \startbibitem[C]\stopbibitem * \cite[A, B, and C] \qquad{\red output should be: A{,} B{,} and C} **\cite[ABC] \qquad{\red output should be: ABC} ***\cite[A], \cite[B], \cite[C] \qquad{\red output should be: A, B, C} \cite[A]\cite[B]\cite[C] \qquad{\red output should be: ABC} \stoptext references can be a comma separated list, so A, B, and C is actually three tags: "A" "B" "and C" so, you run into parsing problems, so how to deal with: [A, B, and C] maybe: [{A, B, and C}] alas, in comma separated list the first level of {} is removed but we can cheat: [{{A, B, and C}}] works with \cite [{{A, B, and C}}] 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] new lua/stack error
Here is the file that I have been working with: \installlanguage[packed][en] \setuplanguage[packed][spacing=packed] \startsetups[tightspace] \spaceskip 0.5\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} \def\startbibitem{\dosingleempty\dostartbibitem} \def\stopbibitem{\stopBibItem} \definedescription[BibItem][ width=broad, margin=1.5pc, indenting={no}, indentnext=no, alternative=hanging, hang=1, headcommand=\gobbleoneargument, align=right, before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] \definereferenceformat [cite] [type=title,left={},right={}] \definereferenceformat [bibpage] [type=page] \starttext \startbibitem[A, B, and C]\stopbibitem % TEST by commenting these %\startbibitem[A{,} B{,} and C]\stopbibitem % lines out \startbibitem[ABC]\stopbibitem \startbibitem[A]\stopbibitem \startbibitem[B]\stopbibitem \startbibitem[C]\stopbibitem * \cite[A, B, and C] \qquad{\red output should be: A{,} B{,} and C} **\cite[ABC] \qquad{\red output should be: ABC} ***\cite[A], \cite[B], \cite[C] \qquad{\red output should be: A, B, C} \cite[A]\cite[B]\cite[C] \qquad{\red output should be: ABC} \stoptext On Wed, Feb 22, 2017 at 11:44 AM, Hans Hagen <pra...@wxs.nl> wrote: > On 2/22/2017 4:50 PM, Alan Bowen wrote: > >> Hi, Hans— >> >> The problem is the line \startbibitem[A, B, and C]\stopbibitem. I can >> either keep it and any others like \cite[A], \cite[B] or >> \cite[A]\cite[B] are messed up or I can comment it out and these same >> citations work. >> \startbibitem[A{,} B{,}and C]\stopbibitem (as you suggested) does allow >> the other citations to work. But, then, neither \cite[A, B, and C] nor >> the \cite[A{,} B{,} and C] works. >> > > so we need a small example > > > - > 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/list > info/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] question about \startitemize...\stopitemize (again)
On 11/29/2016 07:48 PM, Wolfgang Schuster wrote: >> Pablo Rodriguez 29. November 2016 um 19:28 >> Dear list, >> >> sorry for asking this question again, but I’m afraid I really need to >> solve this as soon as possible. >> >> I have the following sample: >> >> \setupwhitespace[5em] >> \startsetups[smallwspa] >> \setupwhitespace[small] >> \setupblank[small] >> \stopsetups >> \setupitemize[each][indenting=no, setups=smallwspa] > > \setupitemize[each][indenting=no,inner=\directsetup{smallwspa}] Wolfgang, many thanks for your ultra-fast reply and for your help. As always, it works perfectly fine. Sorry, but what does the key "inbetween" setup? (I thought it was referred to items.) Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] question about \startitemize...\stopitemize (again)
Pablo Rodriguez <mailto:oi...@gmx.es> 29. November 2016 um 19:28 Dear list, sorry for asking this question again, but I’m afraid I really need to solve this as soon as possible. I have the following sample: \setupwhitespace[5em] \startsetups[smallwspa] \setupwhitespace[small] \setupblank[small] \stopsetups \setupitemize[each][indenting=no, setups=smallwspa] \setupitemize[each][indenting=no,inner=\directsetup{smallwspa}] 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] bug in \directsetup?
On 11/17/2016 09:29 PM, Hans Hagen wrote: > On 11/17/2016 8:53 PM, Pablo Rodriguez wrote: >> [...] >> I need the \directsetup to be able to set up a different interline space >> in the section list from TOC. I’m using latest beta from 2016.11.17 14:19. >> >> There is a weird behaviour: the links from TOC for the first sections >> reach the chapter title and not the section title. > > fixed in next beta Many thanks for the fast fix, Hans. Pablo -- http://www.ousia.tk ___ 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] bug in \directsetup?
On 11/17/2016 8:53 PM, Pablo Rodriguez wrote: Dear list, I have the following sample: \setuppapersize[A6] \setupinteraction[state=start, focus=standard] \placebookmarks[chapter, section][chapter, section] \startsetups[placesect] \start \setupinterlinespace [line=2.8ex] \placelist [section] [alternative=d, numbersegments=section, pagenumber=no, style=\itx] \par \stop \stopsetups \setuplist [chapter] [before={\blank[medium]}, after=\directsetup{placesect}] \starttext \placelist[chapter] \dorecurse{5}{\chapter{Knuth}\input knuth \dorecurse{8}{\section{Zapf}\input zapf}} \stoptext I need the \directsetup to be able to set up a different interline space in the section list from TOC. I’m using latest beta from 2016.11.17 14:19. There is a weird behaviour: the links from TOC for the first sections reach the chapter title an not the section title. fixed in next beta - 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] bug in \directsetup?
Dear list, I have the following sample: \setuppapersize[A6] \setupinteraction[state=start, focus=standard] \placebookmarks[chapter, section][chapter, section] \startsetups[placesect] \start \setupinterlinespace [line=2.8ex] \placelist [section] [alternative=d, numbersegments=section, pagenumber=no, style=\itx] \par \stop \stopsetups \setuplist [chapter] [before={\blank[medium]}, after=\directsetup{placesect}] \starttext \placelist[chapter] \dorecurse{5}{\chapter{Knuth}\input knuth \dorecurse{8}{\section{Zapf}\input zapf}} \stoptext I need the \directsetup to be able to set up a different interline space in the section list from TOC. I’m using latest beta from 2016.11.17 14:19. There is a weird behaviour: the links from TOC for the first sections reach the chapter title an not the section title. All other sections have their right destinations from the table of contents. And bookmarks for first sections have also the right destinations. Of course, this would work as expected, if I avoided the \directsetup (having a wrong interline space). If this isn’t a bug, what am I missing? Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] interline space for \setuplist[alternative=d]
Hans, I have the following sample: \setuppapersize[A6] \setupinteraction[state=start, focus=standard] \placebookmarks[chapter, section][chapter, section] \startsetups[lsect] \setupinterlinespace[line=28ex] \stopsetups \setuplist[section][style=\tfxx, alternative=d, setups=lsect] \starttext \completecontent \dorecurse{5}{\chapter{Knuth}\input knuth \dorecurse{8}{\section{Zapf}\input zapf}} \stoptext I cannot set the interline space for \setuplist[section]. Wolfgang kindly provided me with a workaround: \setuppapersize[A6] \setupinteraction[state=start, focus=standard] \placebookmarks[chapter, section][chapter, section] \startsetups[plsect] \start \setupinterlinespace [line=2.8ex] \placelist [section] [alternative=d, numbersegments=section, pagenumber=no, style=\itx] \par \stop \stopsetups \setuplist [chapter] [before={\blank[medium]}, after=\directsetup{plsect}] \starttext \placelist[chapter] \dorecurse{5}{\chapter{Knuth}\input knuth \dorecurse{8}{\section{Zapf}\input zapf}} \stoptext But the issue I discovered recently is that the first section links from the table of contents reach the chapter destination (and not the first section). Bookmarks work fine, instead. Wouldn’t it be better to improve the alternative=d in \setuplist, so that interline space could be set up with the setups option? Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] annotated text: main text in narrower text, annotations on the right
Hi Massi, Why don't you try this kind of parallel paragraphs ? % \setuppapersize[A5] \defineparagraphs[TwoThird][n=2] % The second paragraph width is automatically calculated, if not specified. \setupparagraphs[TwoThird][1][width=.66\textwidth] \starttext \startTwoThird quotation{...{\it pourquoi y a-t-il quelque chose plutôt que rien ?} Parce que rien n’est plus simple et facile que quelque chose. Plus loin, sachant que les choses existent, on doit être en mesure d’expliquer {\it pourquoi elles existent ainsi,} et pas autrement.} \nextTwoThird G. W. Leibniz, {\it\fr Principes de la nature et de la grâce fondés en raison,} 1714. \stopTwoThird \stoptext Another solution is : \defineparagraphs[TwoColumns][n=2,align=verytolerant] \startsetups[TwoColumns] \setupinterlinespace[line=5ex] \stopsetups \setupparagraphs[TwoColumns:2][inner=\directsetup{TwoColumns}] \starttext \input tufte % here start the twocolumns \startTwoColumns \startlines {\bf ontact information} Adeimantos 3 Achaion Street Attica Gr - 11852 Athens adeiman...@uc.cy {\bf Edition} Essays § Novels {\bf Development} Prototype {\bf Year} 2016 {\bf Private funding} \$0 \stoplines % Starting second column \TwoColumns \input ward \blank \input ward \stopTwoColumns \stoptext - Mail original - De: "mf" <mass...@fastwebnet.it> À: ntg-context@ntg.nl Envoyé: Vendredi 30 Septembre 2016 00:09:16 Objet: Re: [NTG-context] annotated text: main text in narrower text, annotations on the right > Which feature from verbatim annotations do you need because style > and color > changes can be applied in normal text without problems. > > Wolfgang Thanks for the answer, Wolfgang. That's not style and color, it's a sort of two-column layout with the main text in the left column and annotations (comments) in the right one. Example (it does not work): \starttext This is the main text\sidenote{annotation} flowing in the left column... \stoptext resulting in |This is the main text flowing | annotation | |in the left column... | | You can do it with setuplayout and a wider right margin, using \inright for annotations, but it's for the whole document or a whole page. Is that possibile only for a section of text inside a page? Best regards, Massi ___ 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] bug in widows and orphans prevention?
On 08/23/2016 08:46 PM, Wolfgang Schuster wrote: >> Pablo Rodriguez 23. August 2016 um 20:35 >> [...] >> With both typefaces (Latin Modern at 12.5pt and TeX Gyre Pagella at >> 12pt), I get an orphan line on the second page. >> >> Have I hit a bug or am I missing something? > > You can use the \setpenalties command which gives you more options. > > \startsetups[orphanwidow] > \directsetup{*reset} > \setpenalties \widowpenalties{1}{1} > \setpenalties \clubpenalties {1}{1} > \brokenpenalty\plusone > \stopsetups Many thanks for your fast reply, Wolfgang. Why doesn’t the previous code work? Has ConTeXt changed in this area? I would like to know, since I want to know for sure whether I will have to replace the old code with the new one in all my documents. Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] bug in widows and orphans prevention?
Pablo Rodriguez <mailto:oi...@gmx.es> 23. August 2016 um 20:35 Dear list, I have the following sample: \showframe\showgrid \startsetups[orphanwidow] \setup[reset] \widowpenalty=1 \clubpenalty=1 \brokenpenalty=1 \stopsetups \setuplayout[setups={orphanwidow}] \setupbodyfont[12.5pt] %~ \setupbodyfont[pagella] \starttext \dorecurse{10}{\input zapf\par} \stoptext With both typefaces (Latin Modern at 12.5pt and TeX Gyre Pagella at 12pt), I get an orphan line on the second page. Have I hit a bug or am I missing something? You can use the \setpenalties command which gives you more options. \startsetups[orphanwidow] \directsetup{*reset} \setpenalties \widowpenalties{1}{1} \setpenalties \clubpenalties {1}{1} \brokenpenalty\plusone \stopsetups 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] Strange problem with Blockquote
On 08/17/2016 10:55 AM, Robert Blackstone wrote: > Hi Pablo, > > Thanks for your suggestion. I did try to insert this code where I > thought I might help, though must admit that I'm not sure what to do > with the argument [frontpart]. Hi Robert, the command only changed the interline space in the front matter, not in the blockquotes placed in the front part. Sorry, because it was my fault. Today, I realized my mistake. > In my projectfiles, admittedly rather a mess, there is nothing with the > *name *frontpart. Anyway, with or without this or some other possibly > more appropriate argument, nothing changed the behaviour of this, or > rather a blockquote in this first chapter, not even surrounding the > blockquote itself with \setupinterlinespace[small] > ... \setupinterlinespace[reset], as I wrote in my original post. frontpart is the sectionblock name for frontmatter. BTW, I didn’t know it myself. Wolfgang explained to me in one of the many replies I received from him. A correct sample should read: \setupinterlinespace[line=4ex] \startsetups[interlinear:front] \setupinterlinespace[line=2.5ex] \stopsetups \startsetups[interlinear:general] \setupinterlinespace[line=5ex] \stopsetups \setupdelimitedtext [blockquote] [before={\directsetup{interlinear:general}}] \startsectionblockenvironment[frontpart] \setupdelimitedtext [blockquote] [before={\directsetup{interlinear:front}}] \stopsectionblockenvironment \starttext \startfrontmatter \dorecurse{2}{\input knuth\par \startblockquote\input zapf\stopblockquote} \stopfrontmatter \startbodymatter \dorecurse{2}{\input knuth\par \startblockquote\input zapf\stopblockquote} \stopbodymatter \stoptext But I don’t know whether the way of setting the interline space for delimited texts is the best one. Wolfgang, could you correct (or confirm) my previous statement? I hope it helps now, Pablo -- http://www.ousia.tk ___ 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] Interlining in a TwoColumns set
Thank you very much Wolfgang ! With Pablo help, I can manage this flyer. But how to insert a logo on the top right ? Le 13/08/2016 à 08:52, Wolfgang Schuster a écrit : Pablo Rodriguez <mailto:oi...@gmx.es> 12. August 2016 um 17:21 Interline spacing is set in an unorthodox way (to put it fine), but there is no "setups" key for \setupparagraphs (or it doesn’t work). Let us know whether you find more issues. You can apply setups with the inner key: \defineparagraphs[TwoColumns][n=2,align=verytolerant] \startsetups[TwoColumns] \setupinterlinespace[line=5ex] \stopsetups \setupparagraphs[TwoColumns:2][inner=\directsetup{TwoColumns}] \starttext \startTwoColumns \input knuth \TwoColumns \input tufte \stopTwoColumns \stoptext 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 ___ ___ 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] Interlining in a TwoColumns set
Pablo Rodriguez <mailto:oi...@gmx.es> 12. August 2016 um 17:21 Interline spacing is set in an unorthodox way (to put it fine), but there is no "setups" key for \setupparagraphs (or it doesn’t work). Let us know whether you find more issues. You can apply setups with the inner key: \defineparagraphs[TwoColumns][n=2,align=verytolerant] \startsetups[TwoColumns] \setupinterlinespace[line=5ex] \stopsetups \setupparagraphs[TwoColumns:2][inner=\directsetup{TwoColumns}] \starttext \startTwoColumns \input knuth \TwoColumns \input tufte \stopTwoColumns \stoptext 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] Nicer than 'context("\\\\")'?
On 8/8/2016 11:07 AM, Procházka Lukáš Ing. wrote: Hello, is there an alternative code instead of 'context("")'? See the code: \starttext %\startsetups[headertext] % \startframed[width=fit,align=flushleft] %Bla\\ %Uhh % \stopframed %\stopsetups \startluacode context.startsetups{"headertext"} context.startframed{frame = "off", align = "flushright", width = "fit", } context("AB") context("") -- Not very nice here context("CD") context(true) -- Trial 1 but doesn't give the same as "" context("EF") context.crlf() -- Trial 2 but doesn't give the same as "" context("GH") context.stopframed() context.stopsetups() \stopluacode \setupheadertexts[][\directsetup{headertext}] Foo \stoptext context.par() - 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] Nicer than 'context("\\\\")'?
Hello, is there an alternative code instead of 'context("")'? See the code: \starttext %\startsetups[headertext] % \startframed[width=fit,align=flushleft] %Bla\\ %Uhh % \stopframed %\stopsetups \startluacode context.startsetups{"headertext"} context.startframed{frame = "off", align = "flushright", width = "fit", } context("AB") context("") -- Not very nice here context("CD") context(true) -- Trial 1 but doesn't give the same as "" context("EF") context.crlf() -- Trial 2 but doesn't give the same as "" context("GH") context.stopframed() context.stopsetups() \stopluacode \setupheadertexts[][\directsetup{headertext}] Foo \stoptext Best regards, Lukas -- Ing. Lukáš Procházka | mailto:l...@pontex.cz Pontex s. r. o. | mailto:pon...@pontex.cz | http://www.pontex.cz | IDDS:nrpt3sn Bezová 1658 147 14 Praha 4 Tel: +420 241 096 751 (+420 720 951 172) 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 ___
[NTG-context] issue with bookmark for sections
Dear list, I have the following sample: \setuppapersize[A5] \setupinteraction[state=start, focus=standard] \startsetups[placelist:section] \start \setupinterlinespace [line=2.8ex] \placelist [section] [alternative=d, pagenumber=no, style=\itxx] \par \stop \stopsetups \setuplist [chapter] [after=\directsetup{placelist:section}] \starttext \completecontent \dorecurse{5}{\chapter{Chapter \Romannumerals{\recurselevel}} \dorecurse{10}{\section{Section}\input zapf\par\input knuth} } \stoptext The setups are required to allow a different interline space in the list of section items from the content lists. But the issue I’m experiencing is that the bookmarks from the first sections in each chapter have their destinations in the chapter and not in its section titles. Am I missing something or this is a bug in ConTeXt? Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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 get the current section level?
... That's it, thank you! Lukas On Mon, 04 Apr 2016 11:30:15 +0200, Wolfgang Schuster <schuster.wolfg...@gmail.com> wrote: Lukáš Procházka <mailto:l...@pontex.cz> 3. April 2016 um 22:02 Hello, is there a (Lua) way how to get the current section level? \startsetups[headinformation] \starttabulate \NC Name \EQ \currenthead \NC\NR \NC Level \EQ \currentheadlevel \NC\NR \stoptabulate \stopsetups \setuphead[chapter,section,subsection,subsubsection][after=\directsetup{headinformation}] \starttext \chapter{Chapter} \section{Section} \subsubsection{Subsubsection} \stoptext 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 241 096 751 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] How to get the current section level?
Lukáš Procházka <mailto:l...@pontex.cz> 3. April 2016 um 22:02 Hello, is there a (Lua) way how to get the current section level? \startsetups[headinformation] \starttabulate \NC Name \EQ \currenthead \NC\NR \NC Level \EQ \currentheadlevel \NC\NR \stoptabulate \stopsetups \setuphead[chapter,section,subsection,subsubsection][after=\directsetup{headinformation}] \starttext \chapter{Chapter} \section{Section} \subsubsection{Subsubsection} \stoptext 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] Absolute position in table cell
On 02/16/2016 10:49 PM, Hans Hagen wrote: > On 2/16/2016 10:29 PM, Volker Mische wrote: >> On 02/16/2016 05:40 PM, Wolfgang Schuster wrote: >>>> Volker Mische <mailto:volker.mis...@gmail.com> >>>> 16. Februar 2016 um 17:21 >>>> >>>> Thanks a lot that works. >>>> >>>> I've a follow up question. I'd like to wrap the `\setgvariable` in a a >>>> paragraph like thing. I found out about annotations, which look like >>>> what I've after. >>>> >>>> Though sadly I get an error message (! Undefined control sequence) when >>>> I use annotations. It works when I hard-code a value within the >>>> annotation, but it doesn't if I use the contents of the annotation. >>>> I've >>>> also tried it the `\placeannotationcontent` way, but there I get the >>>> same error. Here's the full example: >>>> >>>> \starttext >>>> >>>> \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] >>>> \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] >>>> >>>> >>>> \startsetups pagenumber >>>> \setlayerframed >>>> [pagenumber] >>>> [preset=rightbottom] >>>> {\getvariable{table}{p}} >>>> \stopsetups >>>> >>>> \define[2]\PageWrapper{\setgvariable{table}{p}{#2}} >>>> >>>> \usemodule[annotation] >>>> \defineannotation >>>> [pn] >>>> [alternative=command, command=\PageWrapper] >>> Use this defintion for your \startpn … \stoppn command: >>> >>> \define\startpn >>>{\grabuntil{stoppn}{\setgvariable{table}{p}}} >> >> >> Thanks for you help. Sadly I can't get it working, even if I hard-code >> the value of \setgvariable as e.g. \setgvariable{table}{p}{q}. >> >> I start to wonder if my whole approach is flawed and if there's a better >> way to display something absolutely positioned in (the corner of) a >> table cell that gets defined in the normal flow (just like another >> paragraph within the cell). >> >> Any pointers are welcome, I'm happy to dig deeper myself. > > test \wordright{p} Thanks again. It's not quite what I'm after as it would be on the same line as the last in the paragraph (or one after), but another cell might be higher. So it might not always end up at the absolute bottom. Anyway, you all provided already so much help. As I'm a Context newbie I'll just take the to play around with the stuff and see if I can come up with something that suits my needs. I'll start a new thread in case I've a more more specific question. Cheers, Volker ___ 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] Absolute position in table cell
On 2/16/2016 10:29 PM, Volker Mische wrote: On 02/16/2016 05:40 PM, Wolfgang Schuster wrote: Volker Mische <mailto:volker.mis...@gmail.com> 16. Februar 2016 um 17:21 Thanks a lot that works. I've a follow up question. I'd like to wrap the `\setgvariable` in a a paragraph like thing. I found out about annotations, which look like what I've after. Though sadly I get an error message (! Undefined control sequence) when I use annotations. It works when I hard-code a value within the annotation, but it doesn't if I use the contents of the annotation. I've also tried it the `\placeannotationcontent` way, but there I get the same error. Here's the full example: \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {\getvariable{table}{p}} \stopsetups \define[2]\PageWrapper{\setgvariable{table}{p}{#2}} \usemodule[annotation] \defineannotation [pn] [alternative=command, command=\PageWrapper] Use this defintion for your \startpn … \stoppn command: \define\startpn {\grabuntil{stoppn}{\setgvariable{table}{p}}} Thanks for you help. Sadly I can't get it working, even if I hard-code the value of \setgvariable as e.g. \setgvariable{table}{p}{q}. I start to wonder if my whole approach is flawed and if there's a better way to display something absolutely positioned in (the corner of) a table cell that gets defined in the normal flow (just like another paragraph within the cell). Any pointers are welcome, I'm happy to dig deeper myself. test \wordright{p} - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | 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] Absolute position in table cell
On 02/16/2016 05:40 PM, Wolfgang Schuster wrote: >> Volker Mische <mailto:volker.mis...@gmail.com> >> 16. Februar 2016 um 17:21 >> >> Thanks a lot that works. >> >> I've a follow up question. I'd like to wrap the `\setgvariable` in a a >> paragraph like thing. I found out about annotations, which look like >> what I've after. >> >> Though sadly I get an error message (! Undefined control sequence) when >> I use annotations. It works when I hard-code a value within the >> annotation, but it doesn't if I use the contents of the annotation. I've >> also tried it the `\placeannotationcontent` way, but there I get the >> same error. Here's the full example: >> >> \starttext >> >> \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] >> \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] >> >> \startsetups pagenumber >> \setlayerframed >> [pagenumber] >> [preset=rightbottom] >> {\getvariable{table}{p}} >> \stopsetups >> >> \define[2]\PageWrapper{\setgvariable{table}{p}{#2}} >> >> \usemodule[annotation] >> \defineannotation >> [pn] >> [alternative=command, command=\PageWrapper] > Use this defintion for your \startpn … \stoppn command: > > \define\startpn > {\grabuntil{stoppn}{\setgvariable{table}{p}}} Thanks for you help. Sadly I can't get it working, even if I hard-code the value of \setgvariable as e.g. \setgvariable{table}{p}{q}. I start to wonder if my whole approach is flawed and if there's a better way to display something absolutely positioned in (the corner of) a table cell that gets defined in the normal flow (just like another paragraph within the cell). Any pointers are welcome, I'm happy to dig deeper myself. Cheers, Volker ___ 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] Absolute position in table cell
Volker Mische <mailto:volker.mis...@gmail.com> 16. Februar 2016 um 17:21 Thanks a lot that works. I've a follow up question. I'd like to wrap the `\setgvariable` in a a paragraph like thing. I found out about annotations, which look like what I've after. Though sadly I get an error message (! Undefined control sequence) when I use annotations. It works when I hard-code a value within the annotation, but it doesn't if I use the contents of the annotation. I've also tried it the `\placeannotationcontent` way, but there I get the same error. Here's the full example: \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {\getvariable{table}{p}} \stopsetups \define[2]\PageWrapper{\setgvariable{table}{p}{#2}} \usemodule[annotation] \defineannotation [pn] [alternative=command, command=\PageWrapper] Use this defintion for your \startpn … \stoppn command: \define\startpn {\grabuntil{stoppn}{\setgvariable{table}{p}}} 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] Absolute position in table cell
On 02/15/2016 11:45 AM, Hans Hagen wrote: > On 2/15/2016 11:10 AM, Volker Mische wrote: >> On 02/15/2016 10:58 AM, Hans Hagen wrote: >>> On 2/15/2016 10:32 AM, Volker Mische wrote: >>>> Hi all, >>>> >>>> I'd like to position some text in a corner of a natural table cell. I >>>> got as far as being able to put the same text on every cell (a "p" in >>>> the example). Now my problem is, how do I specify the contents of the >>>> overlay/layer on a per cell basis? >>>> >>>> Best for me would be if I could define the text directly within the >>>> cell. I'm surely open to a completely different solution that has the >>>> same outcome. >>>> >>>> Here's the minimal example of what I currently have. >>>> >>>> \starttext >>>> >>>> \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] >>>> \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] >>>> >>>> >>>> >>>> \startsetups pagenumber >>>> \setlayerframed >>>> [pagenumber] >>>> [preset=rightbottom] >>>> {p} >>>> \stopsetups >>>> >>>> \bTABLE >>>> \setupTABLE[each][each][background=pagenumber] >>>> \bTR >>>> \bTD multiline \par text \eTD >>>> \bTD some cell \par with even \par more \par text \eTD >>>> \eTR >>>> \eTABLE >>>> >>>> \stoptext >>> >>> \bTABLE >>>\bTR >>> \bTD multiline \par text \eTD >>> \bTD[background=pagenumber] some cell \par with even \par more \par >>> text \eTD >>>\eTR >>> \eTABLE >> >> >> I wasn't clear enough. I still want to have `pagenumber` on every cell, >> but I'd like to be able to define its contents within the cell (instead >> of having something like "p" hard-coded). >> >> So I'm looking for something like >> >> \bTD multiline \par text \setlayercontents[pagenumber]{newval}\eTD >> \bTD some cell \par with even \par more \par text >> \setlayercontents[pagenumber]{differentval}\eTD > \startsetups pagenumber >\setlayerframed > [pagenumber] > [preset=rightbottom] > {\getvariable{table}{p}} > \stopsetups > > \bTABLE >\setupTABLE[each][each][background=pagenumber] >\bTR > \bTD \setgvariable{table}{p}{b} multiline \par text \eTD > \bTD \setgvariable{table}{p}{p} some cell \par with even \par more > \par text \eTD >\eTR > \eTABLE Thanks a lot that works. I've a follow up question. I'd like to wrap the `\setgvariable` in a a paragraph like thing. I found out about annotations, which look like what I've after. Though sadly I get an error message (! Undefined control sequence) when I use annotations. It works when I hard-code a value within the annotation, but it doesn't if I use the contents of the annotation. I've also tried it the `\placeannotationcontent` way, but there I get the same error. Here's the full example: \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {\getvariable{table}{p}} \stopsetups \define[2]\PageWrapper{\setgvariable{table}{p}{#2}} \usemodule[annotation] \defineannotation [pn] [alternative=command, command=\PageWrapper] \bTABLE \setupTABLE[each][each][background=pagenumber] \bTR \bTD \startpn b \stoppn multiline \par text \eTD \bTD \startpn p \stoppn some cell \par with even \par more \par text \eTD \eTR \eTABLE \stoptext Cheers, Volker ___ 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] Absolute position in table cell
On 2/15/2016 11:10 AM, Volker Mische wrote: On 02/15/2016 10:58 AM, Hans Hagen wrote: On 2/15/2016 10:32 AM, Volker Mische wrote: Hi all, I'd like to position some text in a corner of a natural table cell. I got as far as being able to put the same text on every cell (a "p" in the example). Now my problem is, how do I specify the contents of the overlay/layer on a per cell basis? Best for me would be if I could define the text directly within the cell. I'm surely open to a completely different solution that has the same outcome. Here's the minimal example of what I currently have. \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {p} \stopsetups \bTABLE \setupTABLE[each][each][background=pagenumber] \bTR \bTD multiline \par text \eTD \bTD some cell \par with even \par more \par text \eTD \eTR \eTABLE \stoptext \bTABLE \bTR \bTD multiline \par text \eTD \bTD[background=pagenumber] some cell \par with even \par more \par text \eTD \eTR \eTABLE I wasn't clear enough. I still want to have `pagenumber` on every cell, but I'd like to be able to define its contents within the cell (instead of having something like "p" hard-coded). So I'm looking for something like \bTD multiline \par text \setlayercontents[pagenumber]{newval}\eTD \bTD some cell \par with even \par more \par text \setlayercontents[pagenumber]{differentval}\eTD \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {\getvariable{table}{p}} \stopsetups \bTABLE \setupTABLE[each][each][background=pagenumber] \bTR \bTD \setgvariable{table}{p}{b} multiline \par text \eTD \bTD \setgvariable{table}{p}{p} some cell \par with even \par more \par text \eTD \eTR \eTABLE - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | 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] Absolute position in table cell
On 02/15/2016 10:58 AM, Hans Hagen wrote: > On 2/15/2016 10:32 AM, Volker Mische wrote: >> Hi all, >> >> I'd like to position some text in a corner of a natural table cell. I >> got as far as being able to put the same text on every cell (a "p" in >> the example). Now my problem is, how do I specify the contents of the >> overlay/layer on a per cell basis? >> >> Best for me would be if I could define the text directly within the >> cell. I'm surely open to a completely different solution that has the >> same outcome. >> >> Here's the minimal example of what I currently have. >> >> \starttext >> >> \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] >> \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] >> >> >> \startsetups pagenumber >>\setlayerframed >> [pagenumber] >> [preset=rightbottom] >> {p} >> \stopsetups >> >> \bTABLE >>\setupTABLE[each][each][background=pagenumber] >>\bTR >> \bTD multiline \par text \eTD >> \bTD some cell \par with even \par more \par text \eTD >>\eTR >> \eTABLE >> >> \stoptext > > \bTABLE > \bTR > \bTD multiline \par text \eTD > \bTD[background=pagenumber] some cell \par with even \par more \par > text \eTD > \eTR > \eTABLE I wasn't clear enough. I still want to have `pagenumber` on every cell, but I'd like to be able to define its contents within the cell (instead of having something like "p" hard-coded). So I'm looking for something like \bTD multiline \par text \setlayercontents[pagenumber]{newval}\eTD \bTD some cell \par with even \par more \par text \setlayercontents[pagenumber]{differentval}\eTD Cheers, Volker ___ 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] Absolute position in table cell
On 2/15/2016 10:32 AM, Volker Mische wrote: Hi all, I'd like to position some text in a corner of a natural table cell. I got as far as being able to put the same text on every cell (a "p" in the example). Now my problem is, how do I specify the contents of the overlay/layer on a per cell basis? Best for me would be if I could define the text directly within the cell. I'm surely open to a completely different solution that has the same outcome. Here's the minimal example of what I currently have. \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {p} \stopsetups \bTABLE \setupTABLE[each][each][background=pagenumber] \bTR \bTD multiline \par text \eTD \bTD some cell \par with even \par more \par text \eTD \eTR \eTABLE \stoptext \bTABLE \bTR \bTD multiline \par text \eTD \bTD[background=pagenumber] some cell \par with even \par more \par text \eTD \eTR \eTABLE - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | 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] Absolute position in table cell
Hi all, I'd like to position some text in a corner of a natural table cell. I got as far as being able to put the same text on every cell (a "p" in the example). Now my problem is, how do I specify the contents of the overlay/layer on a per cell basis? Best for me would be if I could define the text directly within the cell. I'm surely open to a completely different solution that has the same outcome. Here's the minimal example of what I currently have. \starttext \definelayer [pagenumber][width=\overlaywidth,height=\overlayheight] \defineoverlay[pagenumber][{\directsetup{pagenumber}\tightlayer[pagenumber]}] \startsetups pagenumber \setlayerframed [pagenumber] [preset=rightbottom] {p} \stopsetups \bTABLE \setupTABLE[each][each][background=pagenumber] \bTR \bTD multiline \par text \eTD \bTD some cell \par with even \par more \par text \eTD \eTR \eTABLE \stoptext Cheers, Volker ___ 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] Problem with \inouter and text justification
Dear list, The problem with margin notes and main text justification being wrong in some lines when using stack=continue is still present with latest beta mtx-context | current version: 2016.01.18 22:21 This can be verified with the test stacking-002.tex in test suite or with MWE I posted earlier. Just wanted to know if fixing this problem was planned for next “stable” version or if that feature is somewhat deprecated ? This problem does not occur with current “stable” ConTeXt version. Many thanks for any hint, Joseph From: josephcan...@gmail.com Sent: Tuesday, December 15, 2015 9:58 PM To: ntg-context@ntg.nl Is this problem a hard limitation from (lua)TeX ? or simply some bug in ConTeXt ? The problem with main text justification is not present with “stable” version of ConTeXt, so my guess is that’s a regression in beta. I initially used stack=yes but despite the name in some cases the notes fail to stack and overlapped. Thanks a lot, Joseph From: josephcan...@gmail.com Sent: Friday, December 11, 2015 9:03 PM To: ntg-context@ntg.nl Thanks Wolfgang for alternative proposal. I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I am looking for. Is there a way to achieve this using notes ? Otherwise I assume that there is a bug with \ininner \inouter then ? Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner. Thanks a lot Joseph From: Wolfgang Schuster Sent: Friday, December 11, 2015 1:13 PM To: ntg-context@ntg.nl josephcan...@gmail.com 10. Dezember 2015 um 11:04 Dear all, Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked. If the “left note” is removed the right side notes are stacked properly again. Is there any solution to avoid the previous problem and this one please ? Are notes a alternative for you? \startsetups[marginnotes] \startframed[width=max,height=max,align=high,strut=no] \placenotes[marginnote][before=,after=,rule=off] \stopframed \stopsetups \setuptexttexts[margin][][\directsetup{marginnotes}] \definenote [marginnote][criterium=page] \setupnotation[marginnote][number=no] \starttext \dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} } \stoptext 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] inter-word space in bibliographies
The appended code is supposed to allow reduction of the inter-word spacing in my bibliographies but it does not. Adjusting the \spaceskip in the setups for [tightspace] does not seem to make any difference. Any suggestions will be most welcome. I am using the latest beta (ConTeXt ver: 2015.11.19 19:13 MKIV beta with LuaTeX 0.85) Alan \startsetups[tightspace] \spaceskip .7\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \def\dostartbibitem[#1]{\startBibItem[title={#1},reference={#1}]} \def\startbibitem{\dosingleempty\dostartbibitem} \def\stopbibitem{\stopBibItem} \definedescription[BibItem][ width=broad, margin=1.5pc, indenting={no}, indentnext=no, alternative=hanging, hang=1, headcommand=\gobbleoneargument, align=right, before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] \starttext Martin, J. 1956. \emph{Histoire du texte des phénomènes d’Aratos}. Paris. \startbibitem[Martin 1956] Martin, J. 1956. \emph{Histoire du texte des phénomènes d’Aratos}. Paris. \stopbibitem \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] Problem with \inouter and text justification
Is this problem a hard limitation from (lua)TeX ? or simply some bug in ConTeXt ? The problem with main text justification is not present with “stable” version of ConTeXt, so my guess is that’s a regression in beta. I initially used stack=yes but despite the name in some cases the notes fail to stack and overlapped. Thanks a lot, Joseph From: josephcan...@gmail.com Sent: Friday, December 11, 2015 9:03 PM To: ntg-context@ntg.nl Thanks Wolfgang for alternative proposal. I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I am looking for. Is there a way to achieve this using notes ? Otherwise I assume that there is a bug with \ininner \inouter then ? Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner. Thanks a lot Joseph From: Wolfgang Schuster Sent: Friday, December 11, 2015 1:13 PM To: ntg-context@ntg.nl josephcan...@gmail.com 10. Dezember 2015 um 11:04 Dear all, Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked. If the “left note” is removed the right side notes are stacked properly again. Is there any solution to avoid the previous problem and this one please ? Are notes a alternative for you? \startsetups[marginnotes] \startframed[width=max,height=max,align=high,strut=no] \placenotes[marginnote][before=,after=,rule=off] \stopframed \stopsetups \setuptexttexts[margin][][\directsetup{marginnotes}] \definenote [marginnote][criterium=page] \setupnotation[marginnote][number=no] \starttext \dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} } \stoptext 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] horizontal spacing under special circumstances
Am 2015-12-09 um 04:16 schrieb Wolfgang Schuster <schuster.wolfg...@gmail.com>: >> \definedescription[BibItem][ >> before={\directsetup{tightspace}\bgroup\language[packed]}, >> after={\egroup}, >> ] > you can use here (the grouping isn’t necessary) > >before={\directsetup{tightspace}\setupspacing[packed]}, Thank you very much, that’s what i was looking for! Greetlings, Hraban --- http://www.fiee.net 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 ___
Re: [NTG-context] Problem with \inouter and text justification
josephcan...@gmail.com <mailto:josephcan...@gmail.com> 10. Dezember 2015 um 11:04 Dear all, Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked. If the “left note” is removed the right side notes are stacked properly again. Is there any solution to avoid the previous problem and this one please ? Are notes a alternative for you? \startsetups[marginnotes] \startframed[width=max,height=max,align=high,strut=no] \placenotes[marginnote][before=,after=,rule=off] \stopframed \stopsetups \setuptexttexts[margin][][\directsetup{marginnotes}] \definenote [marginnote][criterium=page] \setupnotation[marginnote][number=no] \starttext \dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} } \stoptext 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] Problem with \inouter and text justification
Thanks Wolfgang for alternative proposal. I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I am looking for. Is there a way to achieve this using notes ? Otherwise I assume that there is a bug with \ininner \inouter then ? Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner. Thanks a lot Joseph From: Wolfgang Schuster Sent: Friday, December 11, 2015 1:13 PM To: ntg-context@ntg.nl josephcan...@gmail.com 10. Dezember 2015 um 11:04 Dear all, Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked. If the “left note” is removed the right side notes are stacked properly again. Is there any solution to avoid the previous problem and this one please ? Are notes a alternative for you? \startsetups[marginnotes] \startframed[width=max,height=max,align=high,strut=no] \placenotes[marginnote][before=,after=,rule=off] \stopframed \stopsetups \setuptexttexts[margin][][\directsetup{marginnotes}] \definenote [marginnote][criterium=page] \setupnotation[marginnote][number=no] \starttext \dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} } \stoptext 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] horizontal spacing under special circumstances
On 12/08/2015 12:11 PM, Henning Hraban Ramm wrote: > [...] > Thank you for the suggestion, but I can’t see any change, even if I use > extreme values for \spaceskip (like 0.1 or 10.0), neither in footnotes > nor in my description (is the setups key even supposed to work in > \definedescription?). Hi Hraban, I don’t know whether this is right, but this works for me: \startsetups[footnote:space] \spaceskip .7\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \definedescription[definition][before=\directsetup{footnote:space}] \definedescription[definitiona] \starttext \definition{Hermann Zapf} \input zapf \definitiona{Hermann Zapf} \input zapf \stoptext Pablo -- http://www.ousia.tk ___ 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] horizontal spacing under special circumstances
Am 2015-12-08 um 17:50 schrieb Pablo Rodriguez <oi...@gmx.es>: > On 12/08/2015 12:11 PM, Henning Hraban Ramm wrote: >> [...] >> Thank you for the suggestion, but I can’t see any change, even if I use >> extreme values for \spaceskip (like 0.1 or 10.0), neither in footnotes >> nor in my description (is the setups key even supposed to work in >> \definedescription?). > > Hi Hraban, > > I don’t know whether this is right, but this works for me: > >\startsetups[footnote:space] > \spaceskip .7\interwordspace >plus .5\interwordstretch minus \interwordshrink >\stopsetups > >\definedescription[definition][before=\directsetup{footnote:space}] >\definedescription[definitiona] > >\starttext >\definition{Hermann Zapf} \input zapf > >\definitiona{Hermann Zapf} \input zapf >\stoptext Thank you, this is really nice. Didn’t know \directsetup (i.e. I can’t handle these setups at all). I also tried to get rid of the bigger space after stops: \installlanguage[packed][en] \setuplanguage[packed][spacing=packed] \startsetups[tightspace] \spaceskip 0.7\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \definedescription[BibItem][ before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] Greetlings, Hraban --- http://www.fiee.net 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 ___
Re: [NTG-context] horizontal spacing under special circumstances
Henning Hraban Ramm <mailto:te...@fiee.net> 8. Dezember 2015 um 16:22 Thank you, this is really nice. Didn’t know \directsetup (i.e. I can’t handle these setups at all). I also tried to get rid of the bigger space after stops: \installlanguage[packed][en] \setuplanguage[packed][spacing=packed] You don’t have add a new language because \startsetups[tightspace] \spaceskip 0.7\interwordspace plus .5\interwordstretch minus \interwordshrink \stopsetups \definedescription[BibItem][ before={\directsetup{tightspace}\bgroup\language[packed]}, after={\egroup}, ] you can use here (the grouping isn’t necessary) before={\directsetup{tightspace}\setupspacing[packed]}, 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] How to define a new environment / function?
Dr. Thomas Möbius mailto:kont...@thomasmoebius.de 17. Juni 2015 15:23 Dear list, having used ConTeXt for years now, I am the first time in need to, well, programming something. And I realised, I am a little bit lost. I have a rather long list of variable descriptions that I would like to typeset in a usable and readable way. It should look something like this: ---snip: minimal example--- \starttext \setupdelimitedtext[blockquote] {{\bf Geschlecht} \qquad Geschlecht \hfill $0,1$} \startblockquote Das Geschlecht des Probanden. \stopblockquote \blank {{\bf SoB} \qquad Geburtssaison \hfill $1,\dots,4$} \startblockquote Jahreszeit der Geburt. Kodierung: 1 = Winter, 2 = Frühling, 3 = Sommer, 4 = Herbst. \stopblockquote \blank {{\bf BildungV} \qquad Bildung Vater \hfill $1,\dots,6$} \startblockquote Ordinale Beschreibung der Bildung des Vaters zum Zeitpunkt der Erhebung. Kodierung: 0 = kein Abschluss, 1 = Volksschule, 2 = Hauptschule, 3 = Realschule, 4 = Fachabitur, 5 = Abitur, 6 = Studium. \stopblockquote \blank {{\bf BildungM} \qquad Bildung Mutter \hfill $1,\dots,6$} \startblockquote Ordinale Beschreibung der Bildung der Mutter zum Zeitpunkt der Erhebung. Kodierung siehe {\bf BildungV}. \stopblockquote \blank {{\bf Urb15} \qquad Urbanität \hfill $\naturalnumbers$} \startblockquote Beschreibung der Urbanität des Umfelds in den ersten 15 Lebensjahren. Kodierung: $\sum_{i=1}^{15} u_i$ mit $u_i=$ ein Punkt für eine Stadt bis 10.000 Einwohner, 2 Punkte für bis 100.000 Einwohner, 3 Punkte über 100.000 Einwohner im Jahr $i$. \stopblockquote \blank {{\bf LQ} \qquad Händigkeit \hfill $(0,1)$} \startblockquote Lateralisierungsquotient, wobei -1 = perfekt linkshändig und +1 = perfekt rechtshändig. \stopblockquote \stoptext ---end snip--- What I would like to have is a function/environment/something that would allow me to write the above text in the following way: ---snip: want to example--- \starttext \startvariable [alias=Geschlecht, name=Geschlecht, range={$0,1$}] Das Geschlecht des Probanden. \stopvariable \startvariable [alias=SoB, name=Geburtssaison, range={$1,\dots,4$}] Jahreszeit der Geburt. Kodierung: 1 = Winter, 2 = Frühling, 3 = Sommer, 4 = Herbst. \stopvariable \startvariable [alias=BildungV, name={Bildung Vater}, range={$1,\dots,6$}, reference=bildungDesVater] Ordinale Beschreibung der Bildung des Vaters zum Zeitpunkt der Erhebung. Kodierung: 0 = kein Abschluss, 1 = Volksschule, 2 = Hauptschule, 3 = Realschule, 4 = Fachabitur, 5 = Abitur, 6 = Studium. \stopvariable \startvariable [alias=BildungM, name={Bildung Mutter}, range={$1,\dots,6$}] Ordinale Beschreibung der Bildung der Mutter zum Zeitpunkt der Erhebung. Kodierung siehe \in[bildungDesVater]. \stopvariable \startvariable [alias=Urb15, name=Urbanität, range={$\naturalnumbers$}] Beschreibung der Urbanität des Umfelds in den ersten 15 Lebensjahren. Kodierung: $\sum_{i=1}^{15} u_i$ mit $u_i=$ ein Punkt für eine Stadt bis 10.000 Einwohner, 2 Punkte für bis 100.000 Einwohner, 3 Punkte über 100.000 Einwohner im Jahr $i$. \startvariable [alias=LQ, name=Händigkeit, range={$(0,1)$}] Lateralisierungsquotient, wobei -1 = perfekt linkshändig und +1 = perfekt rechtshändig. \stopvariable \stoptext ---end snip--- Could someone point me in the right direction, or get me started somehow? Is this difficult to accomplish? Or is it super easy and I just don't know it? The code below does what you want. \def\startvariable {\begingroup \dosingleempty\dostartvariable} \def\dostartvariable[#1]% {\getrawparameters[variable][alias=,name=,range=,reference=,#1]% \grabbufferdata[variable][startvariable][stopvariable]} \def\stopvariable {\directsetup{variable:content}% \endgroup} \startsetups[variable:content] \startlinealignment[middle] \variablealias \qquad \variablename \hfill \variablerange \doifsomething{\variablereference}{\expanded{\reference[\variablereference]{\variablealias}}} \stoplinealignment \startblockquote \getbufferdata[variable] \stopblockquote \stopsetups \starttext \startvariable [alias=Geschlecht, name=Geschlecht, range={$0,1$}] Das Geschlecht des Probanden. \stopvariable \startvariable [alias=SoB, name=Geburtssaison, range={$1,\dots,4$}] Jahreszeit der Geburt. Kodierung: 1 = Winter, 2 = Frühling, 3 = Sommer, 4 = Herbst. \stopvariable \startvariable [alias=BildungV, name={Bildung Vater}, range={$1,\dots,6$},reference=bildungDesVater] Ordinale Beschreibung der Bildung des Vaters zum Zeitpunkt der Erhebung. Kodierung: 0 = kein Abschluss, 1 = Volksschule, 2 = Hauptschule, 3 = Realschule, 4 = Fachabitur, 5 = Abitur, 6 = Studium. \stopvariable \startvariable [alias=BildungM, name={Bildung Mutter}, range={$1,\dots,6$}] Ordinale Beschreibung der Bildung der Mutter zum Zeitpunkt der Erhebung. Kodierung siehe \in[bildungDesVater]. \stopvariable \startvariable [alias=Urb15, name=Urbanität, range={$\naturalnumbers$}] Beschreibung der
Re: [NTG-context] Preventing double title pages for nested content
Am 21.05.2015 um 00:36 schrieb Kate F k...@elide.org: Hi, There's been a misunderstanding here. You're showing a structure which is a two-deep hierarchy (Libraries containing Manpages). That's not what the structure in my example is, and you're showing something which I think is different to what I'm asking for. (Or I just can't see how to apply the technique you're illustrating) You have to add just another level to my example, nothing more. The structure for my example is Volumes which contain either Libraries *or* Manpages, and a Library contains Manpages. I'll draw out the tree from my example again: (this is the same as in my first email for this thread, but I'm repeating it here for clarity) \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext Please look at Volume 3; you can see it contains some Libraries (libjpeg, libpng, libbmp). The other Volumes do not contain Libraries; they just contain Manpages directly. So the ToC is: Volume 1: Programs -- I want a title page for this ... manpages for (1) Volume 2: Syscalls -- I want a title page for this ... manpages for (2) Volume 3: Libraries -- no title page for this!! Because this Volume contains Libraries Library libjpeg -- I want a title page for this ... manpages for (3) libjpeg Library libpng -- I want a title page for this ... manpages for (3) libpng Library libbmp -- I want a title page for this ... manpages for (3) libbmp Volume 4: Drivers -- I want a title page for this ... manpages for (4) Volume 7: Makefiles -- I want a title page for this ... manpages for (7) As I said in my original email, this grouping into libraries only applies to Volume 3. The effect I'm trying to achieve is to have a single title page before each set of manpages. So I want a title page for Programs, Syscalls, libjpeg, libpng, libbmp, Drivers, and Makefiles. But I do not want a title page for Volume 3 itself, Libraries because that would be immediately followed by the title page for libjpeg, and my aim is to avoid having two consecutive title pages. I have indicated these with arrows above. I hope that's clear. Sorry for repeating myself… Sorry for resending nearly the same example for another time but it still does what you asked for. \definehead [Volume] [part] \definehead [Library] [chapter] \definehead [Manpage] [section] \setuphead [Volume] [placehead=empty, after=\directsetup{libraryentries}] \startsetups[libraryentries] \determinelistcharacteristics[Library] \ifnum\structurelistsize=0 \startframed[frame=off,width=\textwidth,height=\dimexpr\textheight-\strutdp\relax,align={middle,lohi}] \placeheadtext[Volume] \stopframed \else % Hide the Volume title \fi \stopsetups \starttext \placelist[Volume,Library,Manpage] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3} {\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3} {\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3} {\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3} {\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk
Re: [NTG-context] Preventing double title pages for nested content
On 21 May 2015 at 23:06, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 21.05.2015 um 23:44 schrieb Kate F k...@elide.org: On 21 May 2015 at 22:09, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 21.05.2015 um 14:33 schrieb Kate F k...@elide.org: On 21 May 2015 at 09:06, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 21.05.2015 um 00:36 schrieb Kate F k...@elide.org: Hi, There's been a misunderstanding here. You're showing a structure which is a two-deep hierarchy (Libraries containing Manpages). That's not what the structure in my example is, and you're showing something which I think is different to what I'm asking for. (Or I just can't see how to apply the technique you're illustrating) You have to add just another level to my example, nothing more. The structure for my example is Volumes which contain either Libraries *or* Manpages, and a Library contains Manpages. I'll draw out the tree from my example again: (this is the same as in my first email for this thread, but I'm repeating it here for clarity) \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext Please look at Volume 3; you can see it contains some Libraries (libjpeg, libpng, libbmp). The other Volumes do not contain Libraries; they just contain Manpages directly. So the ToC is: Volume 1: Programs -- I want a title page for this ... manpages for (1) Volume 2: Syscalls -- I want a title page for this ... manpages for (2) Volume 3: Libraries -- no title page for this!! Because this Volume contains Libraries Library libjpeg -- I want a title page for this ... manpages for (3) libjpeg Library libpng -- I want a title page for this ... manpages for (3) libpng Library libbmp -- I want a title page for this ... manpages for (3) libbmp Volume 4: Drivers -- I want a title page for this ... manpages for (4) Volume 7: Makefiles -- I want a title page for this ... manpages for (7) As I said in my original email, this grouping into libraries only applies to Volume 3. The effect I'm trying to achieve is to have a single title page before each set of manpages. So I want a title page for Programs, Syscalls, libjpeg, libpng, libbmp, Drivers, and Makefiles. But I do not want a title page for Volume 3 itself, Libraries because that would be immediately followed by the title page for libjpeg, and my aim is to avoid having two consecutive title pages. I have indicated these with arrows above. I hope that's clear. Sorry for repeating myself… Sorry for resending nearly the same example for another time but it still does what you asked for. But it doesn't... You have a page for Volume 3 (which is made blank due to your \ifnum\structurelistsize=0): You’re wrong, the test for \structurelistsize has nothing to do with the empty page. Volume 3: Libraries -- no title page for this!! Instead, I'm trying to find how to not have this produce a page (or some other way to achieve the same effect). And you have no title pages for these: Volume contains Libraries Library libjpeg -- I want a title page for this ... manpages for (3) libjpeg Library libpng -- I want a title page for this ... manpages for (3) libpng Library libbmp -- I want a title page for this These weren’t needed for the example They were the whole point of what I was asking for help with. \definehead [Volume] [part] \definehead [Library] [chapter] \definehead [Manpage] [section] \setuphead [Volume] [placehead=empty, after=\directsetup{libraryentries}] \setuphead [Library] [ page=, placehead=empty, before=\directsetup{Library:before}, after=\directsetup{Library:after}] \startsetups[Library:before] \ifconditional\libraryentries \page \else \settrue\libraryentries
Re: [NTG-context] Preventing double title pages for nested content
Am 21.05.2015 um 23:44 schrieb Kate F k...@elide.org: On 21 May 2015 at 22:09, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 21.05.2015 um 14:33 schrieb Kate F k...@elide.org: On 21 May 2015 at 09:06, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 21.05.2015 um 00:36 schrieb Kate F k...@elide.org: Hi, There's been a misunderstanding here. You're showing a structure which is a two-deep hierarchy (Libraries containing Manpages). That's not what the structure in my example is, and you're showing something which I think is different to what I'm asking for. (Or I just can't see how to apply the technique you're illustrating) You have to add just another level to my example, nothing more. The structure for my example is Volumes which contain either Libraries *or* Manpages, and a Library contains Manpages. I'll draw out the tree from my example again: (this is the same as in my first email for this thread, but I'm repeating it here for clarity) \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext Please look at Volume 3; you can see it contains some Libraries (libjpeg, libpng, libbmp). The other Volumes do not contain Libraries; they just contain Manpages directly. So the ToC is: Volume 1: Programs -- I want a title page for this ... manpages for (1) Volume 2: Syscalls -- I want a title page for this ... manpages for (2) Volume 3: Libraries -- no title page for this!! Because this Volume contains Libraries Library libjpeg -- I want a title page for this ... manpages for (3) libjpeg Library libpng -- I want a title page for this ... manpages for (3) libpng Library libbmp -- I want a title page for this ... manpages for (3) libbmp Volume 4: Drivers -- I want a title page for this ... manpages for (4) Volume 7: Makefiles -- I want a title page for this ... manpages for (7) As I said in my original email, this grouping into libraries only applies to Volume 3. The effect I'm trying to achieve is to have a single title page before each set of manpages. So I want a title page for Programs, Syscalls, libjpeg, libpng, libbmp, Drivers, and Makefiles. But I do not want a title page for Volume 3 itself, Libraries because that would be immediately followed by the title page for libjpeg, and my aim is to avoid having two consecutive title pages. I have indicated these with arrows above. I hope that's clear. Sorry for repeating myself… Sorry for resending nearly the same example for another time but it still does what you asked for. But it doesn't... You have a page for Volume 3 (which is made blank due to your \ifnum\structurelistsize=0): You’re wrong, the test for \structurelistsize has nothing to do with the empty page. Volume 3: Libraries -- no title page for this!! Instead, I'm trying to find how to not have this produce a page (or some other way to achieve the same effect). And you have no title pages for these: Volume contains Libraries Library libjpeg -- I want a title page for this ... manpages for (3) libjpeg Library libpng -- I want a title page for this ... manpages for (3) libpng Library libbmp -- I want a title page for this These weren’t needed for the example They were the whole point of what I was asking for help with. \definehead [Volume] [part] \definehead [Library] [chapter] \definehead [Manpage] [section] \setuphead [Volume] [placehead=empty, after=\directsetup{libraryentries}] \setuphead [Library] [ page=, placehead=empty, before=\directsetup{Library:before}, after=\directsetup{Library:after}] \startsetups[Library:before] \ifconditional\libraryentries \page \else \settrue\libraryentries \fi \stopsetups \startsetups[Library:after
Re: [NTG-context] Preventing double title pages for nested content
Am 20.05.2015 um 01:26 schrieb Kate F k...@elide.org: On 19 May 2015 at 23:51, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 20.05.2015 um 00:34 schrieb Kate F k...@elide.org: Hello! I'm collating some UNIX-like manpages into a PDF. I'm structuring the content like so: \setupcolors[state=start] \definehead[Volume] [part] % red colour: man(1) section \definehead[Library][part] % blue colour: library within section 3 \definehead[Manpage][chapter] \setuphead[Volume,Library,Manpage][page=yes,number=no,placehead=yes] \setuphead[Volume][color=red] \setuphead[Library][color=blue] \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext There I have grouped Volume 3 manpages into libraries. This grouping only applies to Volume 3. I'd like a single title page for each Volume (which I show in red), except for section 3, where I'd like a title page for each Library (which I show in blue). So the pagination should look like: toc S1 ... S2 ... libjpeg ... libpng ... libbmp ... S4 ... Where S* there is a red title page, S3 is absent, and lib* are blue title pages. I'm trying to work out how best to do this. Would you recommend I hide Volume 3's title page? I think that must be the simplest way, but I don't know how to do it using a setup. My data is coming from XML, and I'd like to avoid having a special \startVolume for Volume 3, if I can. Although perhaps that could help. Are there any other ways which might be more sensible? I wondered about using \setuphead[something][continue=yes] to fold the first blue title pages onto the red title pages, but even if I can do that, I think it would make things more difficult for getting the text right on those pages. Change your manpage headings to \chapter and test at the begin of each new volume for the number of chapters (you can use the list mechanism for this) in each volume. %\setuphead[part][placehead=yes,after=\directsetup{chapterentries}] \setuphead[part][placehead=empty,after=\directsetup{chapterentries}] \startsetups[chapterentries] \determinelistcharacteristics[chapter] \ifcase\structurelistsize No chapter in this part. \or One chapter in this part. \else Two or more chapters in this part. \fi \stopsetups \starttext \dorecurse{4} {\startpart[title=Part #1] \dorecurse{\ifcase#1\or 0\or 3\else 1\fi} {\startchapter[title=Chapter ##1] \stopchapter} \stoppart} \stoptext Wolfgang Very interesting! I don't want to use \chapter because I'm dealing with several types of document, and so I'm trying to keep different things separate, so that I don't confuse myself with all the setups. But I just converted your example to use \definehead[Manpage] instead, and that seems to have the same effect for \determinelistcharacteristics[Manpage]. Maybe I'm being unimaginative, but I don't see how you're suggesting I use this technique to achieve the effect I'm after. Did you mean to count Libraries rather than Manpages? Even then I'm not sure how to apply the idea. (Especially as your example doesn't have the same structure as mine.) Sorry if my original description was unclear. It doesn’t matter which name you use for the sections. \definehead [Library] [part] \definehead [Manpage] [chapter] \setuphead [Library] [placehead=empty, before={\startmakeup[standard][align=middle,style=\ssd]}, after={\directsetup{chapterentries}\stopmakeup}] \startsetups[chapterentries] \determinelistcharacteristics[Manpage] \ifcase\structurelistsize No manpages for this libary. \or One manpage for this Library \else Two or more manpages for this library. \fi \stopsetups \starttext \startLibrary[title=First Library] \startManpage[title=Manpage 1] \stopManpage \stopLibrary
Re: [NTG-context] Preventing double title pages for nested content
On 20 May 2015 at 22:19, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 20.05.2015 um 01:26 schrieb Kate F k...@elide.org: On 19 May 2015 at 23:51, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 20.05.2015 um 00:34 schrieb Kate F k...@elide.org: Hello! I'm collating some UNIX-like manpages into a PDF. I'm structuring the content like so: \setupcolors[state=start] \definehead[Volume] [part] % red colour: man(1) section \definehead[Library][part] % blue colour: library within section 3 \definehead[Manpage][chapter] \setuphead[Volume,Library,Manpage][page=yes,number=no,placehead=yes] \setuphead[Volume][color=red] \setuphead[Library][color=blue] \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext There I have grouped Volume 3 manpages into libraries. This grouping only applies to Volume 3. I'd like a single title page for each Volume (which I show in red), except for section 3, where I'd like a title page for each Library (which I show in blue). So the pagination should look like: toc S1 ... S2 ... libjpeg ... libpng ... libbmp ... S4 ... Where S* there is a red title page, S3 is absent, and lib* are blue title pages. I'm trying to work out how best to do this. Would you recommend I hide Volume 3's title page? I think that must be the simplest way, but I don't know how to do it using a setup. My data is coming from XML, and I'd like to avoid having a special \startVolume for Volume 3, if I can. Although perhaps that could help. Are there any other ways which might be more sensible? I wondered about using \setuphead[something][continue=yes] to fold the first blue title pages onto the red title pages, but even if I can do that, I think it would make things more difficult for getting the text right on those pages. Change your manpage headings to \chapter and test at the begin of each new volume for the number of chapters (you can use the list mechanism for this) in each volume. %\setuphead[part][placehead=yes,after=\directsetup{chapterentries}] \setuphead[part][placehead=empty,after=\directsetup{chapterentries}] \startsetups[chapterentries] \determinelistcharacteristics[chapter] \ifcase\structurelistsize No chapter in this part. \or One chapter in this part. \else Two or more chapters in this part. \fi \stopsetups \starttext \dorecurse{4} {\startpart[title=Part #1] \dorecurse{\ifcase#1\or 0\or 3\else 1\fi} {\startchapter[title=Chapter ##1] \stopchapter} \stoppart} \stoptext Wolfgang Very interesting! I don't want to use \chapter because I'm dealing with several types of document, and so I'm trying to keep different things separate, so that I don't confuse myself with all the setups. But I just converted your example to use \definehead[Manpage] instead, and that seems to have the same effect for \determinelistcharacteristics[Manpage]. Maybe I'm being unimaginative, but I don't see how you're suggesting I use this technique to achieve the effect I'm after. Did you mean to count Libraries rather than Manpages? Even then I'm not sure how to apply the idea. (Especially as your example doesn't have the same structure as mine.) Sorry if my original description was unclear. It doesn’t matter which name you use for the sections. \definehead [Library] [part] \definehead [Manpage] [chapter] \setuphead [Library] [placehead=empty, before={\startmakeup[standard][align=middle,style=\ssd]}, after={\directsetup{chapterentries}\stopmakeup}] \startsetups[chapterentries] \determinelistcharacteristics[Manpage] \ifcase\structurelistsize No manpages for this libary. \or One manpage for this Library \else Two or more manpages for this library. \fi \stopsetups \starttext \startLibrary[title=First Library
Re: [NTG-context] Preventing double title pages for nested content
On 19 May 2015 at 23:51, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 20.05.2015 um 00:34 schrieb Kate F k...@elide.org: Hello! I'm collating some UNIX-like manpages into a PDF. I'm structuring the content like so: \setupcolors[state=start] \definehead[Volume] [part] % red colour: man(1) section \definehead[Library][part] % blue colour: library within section 3 \definehead[Manpage][chapter] \setuphead[Volume,Library,Manpage][page=yes,number=no,placehead=yes] \setuphead[Volume][color=red] \setuphead[Library][color=blue] \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext There I have grouped Volume 3 manpages into libraries. This grouping only applies to Volume 3. I'd like a single title page for each Volume (which I show in red), except for section 3, where I'd like a title page for each Library (which I show in blue). So the pagination should look like: toc S1 ... S2 ... libjpeg ... libpng ... libbmp ... S4 ... Where S* there is a red title page, S3 is absent, and lib* are blue title pages. I'm trying to work out how best to do this. Would you recommend I hide Volume 3's title page? I think that must be the simplest way, but I don't know how to do it using a setup. My data is coming from XML, and I'd like to avoid having a special \startVolume for Volume 3, if I can. Although perhaps that could help. Are there any other ways which might be more sensible? I wondered about using \setuphead[something][continue=yes] to fold the first blue title pages onto the red title pages, but even if I can do that, I think it would make things more difficult for getting the text right on those pages. Change your manpage headings to \chapter and test at the begin of each new volume for the number of chapters (you can use the list mechanism for this) in each volume. %\setuphead[part][placehead=yes,after=\directsetup{chapterentries}] \setuphead[part][placehead=empty,after=\directsetup{chapterentries}] \startsetups[chapterentries] \determinelistcharacteristics[chapter] \ifcase\structurelistsize No chapter in this part. \or One chapter in this part. \else Two or more chapters in this part. \fi \stopsetups \starttext \dorecurse{4} {\startpart[title=Part #1] \dorecurse{\ifcase#1\or 0\or 3\else 1\fi} {\startchapter[title=Chapter ##1] \stopchapter} \stoppart} \stoptext Wolfgang Very interesting! I don't want to use \chapter because I'm dealing with several types of document, and so I'm trying to keep different things separate, so that I don't confuse myself with all the setups. But I just converted your example to use \definehead[Manpage] instead, and that seems to have the same effect for \determinelistcharacteristics[Manpage]. Maybe I'm being unimaginative, but I don't see how you're suggesting I use this technique to achieve the effect I'm after. Did you mean to count Libraries rather than Manpages? Even then I'm not sure how to apply the idea. (Especially as your example doesn't have the same structure as mine.) Sorry if my original description was unclear. Thanks, -- Kate ___ 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] Preventing double title pages for nested content
Am 20.05.2015 um 00:34 schrieb Kate F k...@elide.org: Hello! I'm collating some UNIX-like manpages into a PDF. I'm structuring the content like so: \setupcolors[state=start] \definehead[Volume] [part] % red colour: man(1) section \definehead[Library][part] % blue colour: library within section 3 \definehead[Manpage][chapter] \setuphead[Volume,Library,Manpage][page=yes,number=no,placehead=yes] \setuphead[Volume][color=red] \setuphead[Library][color=blue] \starttext \placecontent[list={Volume,Library,Manpage}] \startVolume[title=Section 1: Programs] \dorecurse{3}{\startManpage[title=progxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 2: Syscalls] \dorecurse{3}{\startManpage[title=syscallxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 3: Libraries] \startLibrary[title=libjpeg] \dorecurse{3}{\startManpage[title=jpegapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libpng] \dorecurse{3}{\startManpage[title=pngapi_a(3)] \input lorem \stopManpage} \stopLibrary \startLibrary[title=libbmp] \dorecurse{3}{\startManpage[title=bmpapi_a(3)] \input lorem \stopManpage} \stopLibrary \stopVolume \startVolume[title=Section 4: Drivers] \dorecurse{3}{\startManpage[title=drvxyz(1)] \input lorem \stopManpage} \stopVolume \startVolume[title=Section 7mk: Makefiles] \dorecurse{3}{\startManpage[title=xyz.mk(1)] \input lorem \stopManpage} \stopVolume \stoptext There I have grouped Volume 3 manpages into libraries. This grouping only applies to Volume 3. I'd like a single title page for each Volume (which I show in red), except for section 3, where I'd like a title page for each Library (which I show in blue). So the pagination should look like: toc S1 ... S2 ... libjpeg ... libpng ... libbmp ... S4 ... Where S* there is a red title page, S3 is absent, and lib* are blue title pages. I'm trying to work out how best to do this. Would you recommend I hide Volume 3's title page? I think that must be the simplest way, but I don't know how to do it using a setup. My data is coming from XML, and I'd like to avoid having a special \startVolume for Volume 3, if I can. Although perhaps that could help. Are there any other ways which might be more sensible? I wondered about using \setuphead[something][continue=yes] to fold the first blue title pages onto the red title pages, but even if I can do that, I think it would make things more difficult for getting the text right on those pages. Change your manpage headings to \chapter and test at the begin of each new volume for the number of chapters (you can use the list mechanism for this) in each volume. %\setuphead[part][placehead=yes,after=\directsetup{chapterentries}] \setuphead[part][placehead=empty,after=\directsetup{chapterentries}] \startsetups[chapterentries] \determinelistcharacteristics[chapter] \ifcase\structurelistsize No chapter in this part. \or One chapter in this part. \else Two or more chapters in this part. \fi \stopsetups \starttext \dorecurse{4} {\startpart[title=Part #1] \dorecurse{\ifcase#1\or 0\or 3\else 1\fi} {\startchapter[title=Chapter ##1] \stopchapter} \stoppart} \stoptext 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] \appendtoks and structuring commands
On 2015-03-25 10:23, Hans Hagen wrote: \startsetups [document:titlepage] bla bla \documentvariable{title} bla bla \stopsetups \setupdocument [before=\directsetup{document:titlepage}] \startdocument[title=Some title] ... \stopdocument Thanks. Can one always use `startdocument` rather than `starttext`, are there any drawbacks ? -- H.-E. ___ 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] \appendtoks and structuring commands
On 3/27/2015 11:27 PM, Sam Ḥilluc wrote: On 2015-03-25 10:23, Hans Hagen wrote: \startsetups [document:titlepage] bla bla \documentvariable{title} bla bla \stopsetups \setupdocument [before=\directsetup{document:titlepage}] \startdocument[title=Some title] ... \stopdocument Thanks. Can one always use `startdocument` rather than `starttext`, are there any drawbacks ? it's just a wrapper around starttext 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] \appendtoks and structuring commands
On 3/24/2015 8:48 PM, Sam Ḥilluc wrote: Hi list, I'm trying to leverage the structuring facilities of context. In my previous setup I added a title page automatically by using: \appendtoks \placetitle \to \everystarttext But now that I'm using environments and products, it doesn't seem to work. Here is a minimal (not) working example: % env.tex \startenvironment env \setuppapersize[A5] \appendtoks Title page \to \everystarttext \stopenvironment % prj.tex \startproject prj \environment env \stopproject % prd.tex \startproduct prd \project prj \starttext Bla bla \stoptext \stopproduct Note that when using \everystoptext rather than \everystarttext, it does work (it adds the text to the last page) So what am I doing wrong ? \startsetups [document:titlepage] bla bla \documentvariable{title} bla bla \stopsetups \setupdocument [before=\directsetup{document:titlepage}] \startdocument[title=Some title] ... \stopdocument - 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] Multiline header
Hello, On Mon, 16 Mar 2015 18:34:00 +0100, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: Am 16.03.2015 um 13:54 schrieb Procházka Lukáš Ing. - Pontex s. r. o. l...@pontex.cz: Hello, how to create multiline header? This code ignores all attempts to force a new line: \setupheadertexts[{abc\par def\\ ghi\crlf jkl}] \startsetups[headertext] \startframed[frame=off,align=flushleft,width=fit] abc\\ def\\ ghi\\ jkl \stopframed \stopsetups \setupheadertexts[\directsetup{headertext}] \starttext aaa \stoptext Wolfgang this works perfectly, thank you! 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 241 096 751 Fax: +420 244 461 038 MLHeader.mkiv Description: Binary data MLHeader.pdf Description: Adobe PDF document ___ 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] Multiline header
Am 16.03.2015 um 13:54 schrieb Procházka Lukáš Ing. - Pontex s. r. o. l...@pontex.cz: Hello, how to create multiline header? This code ignores all attempts to force a new line: \setupheadertexts[{abc\par def\\ ghi\crlf jkl}] \startsetups[headertext] \startframed[frame=off,align=flushleft,width=fit] abc\\ def\\ ghi\\ jkl \stopframed \stopsetups \setupheadertexts[\directsetup{headertext}] \starttext aaa \stoptext 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] [location=text] breaks setups in \setupnotes
Am 11.12.2014 um 20:31 schrieb Pablo Rodriguez oi...@gmx.es: On 12/11/2014 08:02 PM, Wolfgang Schuster wrote: Am 11.12.2014 um 19:14 schrieb Pablo Rodriguez: [...] For some strange reason, when location=text is set \setupnote, the setups option isn’t honored? Could anyone confirm the bug? It’s not a bug, the setups key is only used when notes are placed at the bottom of the page but not when you flush them with the \placenotes command. Many thanks for your reply. Wolfgang. Is there no other way to apply setups to a chapter? You can try to add before=\directsetup{setups:footnote}” to \setupnotes. 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] [location=text] breaks setups in \setupnotes
On 12/11/2014 08:38 PM, Wolfgang Schuster wrote: Am 11.12.2014 um 20:31 schrieb Pablo Rodriguez: On 12/11/2014 08:02 PM, Wolfgang Schuster wrote: [...] It’s not a bug, the setups key is only used when notes are placed at the bottom of the page but not when you flush them with the \placenotes command. Many thanks for your reply. Wolfgang. Is there no other way to apply setups to a chapter? You can try to add before=\directsetup{setups:footnote}” to \setupnotes. Many thanks for your reply, Wolfgang. It worked like charm. Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] still buggy TOC generation
Hans, many thanks for the fix in latest beta from 2014.11.08 15:07. I still experience a bug that it wasn’t there before beta from 2014.11.06 14:55. Here you have the sample: \startsetups[placelist:section] \start \setupinterlinespace[line=2.8ex] \placelist[section][alternative=d, pagenumber=no] \par \stop \stopsetups \setuplist [chapter] [before={\blank[big]}, after=\directsetup{placelist:section}] \starttext \title{Inside}\placelist[part,chapter][criterium=all] \chapter{Foreword} \dorecurse{10}{\section{Section from Foreword}} \part{Introduction} \chapter{\ConTeXt\ and digital typography} \dorecurse{10}{\section{Section from Introduction}} \chapter{Chapter 1} \dorecurse{10}{\section{Section from Chapter 1}} \chapter{Chapter 2} \dorecurse{10}{\section{Section from Chapter 2}} \stoptext Only the latest stable version (beta from 2014.01.03 00:40) generates the right TOC, if I remove [criterium=all] from \placelist[part,chapter]. With [criterium=all], I get all section titles in each chapter entry in the TOC. With latest beta from today and removing [criterium=all], the first two chapters listed in items have the section titles from both chapters (which is wrong). Sorry, but isn’t this caused by the changes introduced in beta from 2014.11.06 14:55? Many thanks for your help, Pablo -- http://www.ousia.tk ___ 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] [doifinset] how it works ?
Hello, I'm currently prepping my teaching material for my back-to-university. I want to design some conditional slides based presentation where I can select the slides that I want to show in my final presentation. My current attempt is to use : 1 - MKIV as I use currently only MKII; 2 - a counter is defined, that it is incremented at each slide definition; 3 - a commalist to indicate the slides that I want. The number affected to each slide is made according to its definition in the file and not the slide number displayed; 4 - a block is added to enclosed each slide in order to allow or not it to be shown in the final presentation. \definenumber[slide][way=bytext,prefix=no] % firstly I generate a full commalist \def\slidelist{} \dorecurse{8}{ \doglobal\appendtocommalist{#1}\slidelist } % then I define my slide where I increment the counter \def\startSlide{\setupbackgrounds[page][background={fond,Auteur,backgraphics,foreground,foregraphics}] \directsetup{slide:start}} \def\stopSlide{\directsetup{slide:stop}} \startsetups slide:start \page \incrementnumber[slide] \switchtobodyfont[14pt] \setupinteractionbar[state=start] \startnarrower[left] \stopsetups \startsetups slide:stop \stopnarrower \page \stopsetups \starttext \doifinset{\getnumber[slide]}{\slidelist} { \startSlide \SlideTitleSub{Hello there} What is my number ? \getnumber[slide] ! \stopSlide } \stoptext This doesn't work. the doifinset doesn't work. I've tried to put some \expanded in order to expand the arguments with no success. The only way is to use direct argument as : \doifinset{1}{1,2,3,4,5} Let me know it it is possible. best regards, Pierre-François Bonnefoi. -- Bonnefoi Pierre-Francois|E-mail : bonne...@unilim.fr http://libpfb.so/ Universite de Limoges, Laboratoire XLIM | Tel : 06 28 18 03 38 123 av Albert Thomas| Mrs. Peel, we're needed... 87060 Limoges CEDEX - FRANCE| The Avengers. ___ 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] [doifinset] how it works ?
Hi, Here are a few examples of how to use \doifinset and \doifinsetelse (they were given by Wolfgang S. a few years ago…): \starttext \type{\doifinset{A}{A,B,C}{should go}:} \doifinset{A}{A,B,C}{should go} \type{\doifinset{D}{A,B,C}{should go}:} \doifinset{D}{A,B,C}{should participate} \type{\doifnotinset{}{A,B,C}{not in the set}:} \doifnotinset{}{A,B,C}{not in the set} \type{\doifnotinset{D}{A,B,C}{not in the set}:} \doifnotinset{D}{A,B,C}{not in the set} \doifinsetelse{D}{A,B,C}{it is in the set}{it is not in the set} \define\test{B} \type{\doifinsetelse{\test}{A,B,C}{\test\ is in the set}{\test\ is not in the set}} \doifinsetelse{\test}{A,B,C}{\test\ is in the set}{\test\ is not in the set} \stoptext Best regards: OK On 21 Aug 2014, at 21:58, Pierre-François Bonnefoi bonne...@unilim.fr wrote: Hello, I'm currently prepping my teaching material for my back-to-university. I want to design some conditional slides based presentation where I can select the slides that I want to show in my final presentation. My current attempt is to use : 1 - MKIV as I use currently only MKII; 2 - a counter is defined, that it is incremented at each slide definition; 3 - a commalist to indicate the slides that I want. The number affected to each slide is made according to its definition in the file and not the slide number displayed; 4 - a block is added to enclosed each slide in order to allow or not it to be shown in the final presentation. \definenumber[slide][way=bytext,prefix=no] % firstly I generate a full commalist \def\slidelist{} \dorecurse{8}{ \doglobal\appendtocommalist{#1}\slidelist } % then I define my slide where I increment the counter \def\startSlide{\setupbackgrounds[page][background={fond,Auteur,backgraphics,foreground,foregraphics}] \directsetup{slide:start}} \def\stopSlide{\directsetup{slide:stop}} \startsetups slide:start \page \incrementnumber[slide] \switchtobodyfont[14pt] \setupinteractionbar[state=start] \startnarrower[left] \stopsetups \startsetups slide:stop \stopnarrower \page \stopsetups \starttext \doifinset{\getnumber[slide]}{\slidelist} { \startSlide \SlideTitleSub{Hello there} What is my number ? \getnumber[slide] ! \stopSlide } \stoptext This doesn't work. the doifinset doesn't work. I've tried to put some \expanded in order to expand the arguments with no success. The only way is to use direct argument as : \doifinset{1}{1,2,3,4,5} Let me know it it is possible. best regards, Pierre-François Bonnefoi. -- Bonnefoi Pierre-Francois|E-mail : bonne...@unilim.fr http://libpfb.so/ Universite de Limoges, Laboratoire XLIM | Tel : 06 28 18 03 38 123 av Albert Thomas| Mrs. Peel, we're needed... 87060 Limoges CEDEX - FRANCE| The Avengers. ___ 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] [doifinset] how it works ?
And here a few more examples… \starttext \doifinset {knuth} {knuth,ward} {\input knuth.tex \blank[2*big]} \doifnotinset {ward} {knuth,Hans} {\input ward.tex\blank[2*big]} \doifinsetelse {Hans} {Hans,knuth} {then Hans is a genious...\blank[2*big]} {else ...} \doifcommon {string,...} {string,...} {it is common...} \doifnotcommon {string} {String,...} {nothing is common...} \doifcommonelse {string,...} {string,...} {then ...} {else ...} \blank %\def\substring{substring} %\doifincsnameelse {substring} {\string} {then ...} {else ...} \blank \doifinstringelse {substring} {substringSUB} {then ...} {else ...} \blank \doifnumberelse {string} {then ...} {else string is not a number...} \doifnumberelse {123} {then string is a number...} {else ...} \stoptext Best regards: OK On 21 Aug 2014, at 21:58, Pierre-François Bonnefoi bonne...@unilim.fr wrote: Hello, I'm currently prepping my teaching material for my back-to-university. I want to design some conditional slides based presentation where I can select the slides that I want to show in my final presentation. My current attempt is to use : 1 - MKIV as I use currently only MKII; 2 - a counter is defined, that it is incremented at each slide definition; 3 - a commalist to indicate the slides that I want. The number affected to each slide is made according to its definition in the file and not the slide number displayed; 4 - a block is added to enclosed each slide in order to allow or not it to be shown in the final presentation. \definenumber[slide][way=bytext,prefix=no] % firstly I generate a full commalist \def\slidelist{} \dorecurse{8}{ \doglobal\appendtocommalist{#1}\slidelist } % then I define my slide where I increment the counter \def\startSlide{\setupbackgrounds[page][background={fond,Auteur,backgraphics,foreground,foregraphics}] \directsetup{slide:start}} \def\stopSlide{\directsetup{slide:stop}} \startsetups slide:start \page \incrementnumber[slide] \switchtobodyfont[14pt] \setupinteractionbar[state=start] \startnarrower[left] \stopsetups \startsetups slide:stop \stopnarrower \page \stopsetups \starttext \doifinset{\getnumber[slide]}{\slidelist} { \startSlide \SlideTitleSub{Hello there} What is my number ? \getnumber[slide] ! \stopSlide } \stoptext This doesn't work. the doifinset doesn't work. I've tried to put some \expanded in order to expand the arguments with no success. The only way is to use direct argument as : \doifinset{1}{1,2,3,4,5} Let me know it it is possible. best regards, Pierre-François Bonnefoi. -- Bonnefoi Pierre-Francois|E-mail : bonne...@unilim.fr http://libpfb.so/ Universite de Limoges, Laboratoire XLIM | Tel : 06 28 18 03 38 123 av Albert Thomas| Mrs. Peel, we're needed... 87060 Limoges CEDEX - FRANCE| The Avengers. ___ 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] [doifinset] how it works ?
Am 21.08.2014 um 21:58 schrieb Pierre-François Bonnefoi bonne...@unilim.fr: Hello, I'm currently prepping my teaching material for my back-to-university. I want to design some conditional slides based presentation where I can select the slides that I want to show in my final presentation. My current attempt is to use : 1 - MKIV as I use currently only MKII; 2 - a counter is defined, that it is incremented at each slide definition; 3 - a commalist to indicate the slides that I want. The number affected to each slide is made according to its definition in the file and not the slide number displayed; 4 - a block is added to enclosed each slide in order to allow or not it to be shown in the final presentation. \definenumber[slide][way=bytext,prefix=no] % firstly I generate a full commalist \def\slidelist{} \dorecurse{8}{ \doglobal\appendtocommalist{#1}\slidelist } % then I define my slide where I increment the counter \def\startSlide{\setupbackgrounds[page][background={fond,Auteur,backgraphics,foreground,foregraphics}] \directsetup{slide:start}} \def\stopSlide{\directsetup{slide:stop}} \startsetups slide:start \page \incrementnumber[slide] \switchtobodyfont[14pt] \setupinteractionbar[state=start] \startnarrower[left] \stopsetups \startsetups slide:stop \stopnarrower \page \stopsetups \starttext \doifinset{\getnumber[slide]}{\slidelist} { \startSlide \SlideTitleSub{Hello there} What is my number ? \getnumber[slide] ! \stopSlide } \stoptext This doesn't work. the doifinset doesn't work. I've tried to put some \expanded in order to expand the arguments with no success. The only way is to use direct argument as : \doifinset{1}{1,2,3,4,5} Let me know it it is possible. You have to access the counter with \rawcountervalue[countername] but in your case you can use a different counter mechanism. \setvariables[slide][list={1,2,3,6,7,8}] % \setupbackgrounds[page][background={fond,Auteur,backgraphics,foreground,foregraphics}] \def\startSlide {\increment\SlideCounter \doifinsetelse\SlideCounter{\getvariable{slide}{list}} {\directsetup{slide:start}} {\gobbleuntil\stopSlide}} \def\stopSlide {\directsetup{slide:stop}} \startsetups slide:start \page \stopsetups \startsetups slide:stop \page \stopsetups \starttext \dorecurse{10} {\startSlide {\tfd\recurselevel} \stopSlide} \stoptext 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] Stop Hyphenating Across Columns and Page Breaks
Am 09.07.2014 um 17:57 schrieb H. Özoguz h.oezo...@mmnetz.de: Adding one information: In TeX \brokenpenalty=1 should do the job. But this is ignored in ConText. In this a bug? ConTeXt integrated the penalty setups in the layout mechanism, you can create your own settings but you should apply them with \setuplayout. To create your own setting use the following method. Use the setups environment where the values are set, the default parameters can be loaded with \directsetup{*reset}. \startsetups[mypenalties] \directsetup{*reset} \widowpenalty\plustenthousand \stopsetups In the next step you load this setup with the \setuplayout command: \setuplayout[setups=mypenalties] When you don want to create you own setting you can choose between two predefined ones (the * is part of the name): - *default (which uses different values in grid mode) - *strict 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] indenting in enumerations in mkiv
Am 01.07.2014 um 15:22 schrieb Sytse sytse.knyps...@home.nl: Within the enumeration environment I want the first paragraph not to be indented, whereas the second and following paragraphs should start with an indent. The example below works fine in mkii, but I would like to use mkiv in which the first line is also indented. Sytse -- \defineenumeration[example][text=Example,indenting={yes,medium,next}] \starttext contextversion: 2013.05.28 00:36 command: context proef.tex \startexample This first line is indented, but shouldn't. Runs ok under mkii. This second line should be indented and is ok under both mkii and mkiv. \stopexample \stoptext This is a bug in the enumeration code where the indent setup is used before the title/head is placed which is then handled as first paragraph. To fix this the \indenting command has to be moved after the \directsetup line in strc-con.mkvi: \unexpanded\setvalue{\??constructionstarthandler\v!construction}% this will be redone (reorganized) .. too much boxing {\dostarttagged\t!construction\currentconstruction ... \edef\p_strc_constructions_indenting{\constructionparameter\c!indenting}% \ifx\p_strc_constructions_indenting\empty \else \indenting[\p_strc_constructions_indenting]% \use... \fi ... \directsetup\p_strc_constructions_renderingsetup\relax % \dostoptagged % tag \dostarttagged\t!constructioncontent\empty \ignorespaces} % args not needed 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] \doifemptyelse
Am 20.02.2014 um 23:09 schrieb Pablo Rodriguez oi...@gmx.es: On 02/20/2014 09:39 PM, Wolfgang Schuster wrote: Am 20.02.2014 um 21:12 schrieb Pablo Rodriguez: [...] How can I make the first conditional work? You can’t, markings are only reliable when you use them in the header of footer of the page. To access the values of a heading you can use the \structurevariable and \namedstructurevariable commands. Many thanks for your reply, Wolfgang. My question was about headers, but I didn’t mention it to make a shorter sample. In this case this was a important part for the solution because it makes a difference when you use \getmarking in \setupheadertexts or in the text. The code now is the following: \setupheadertexts[\hfill\namedstructurevariable{chapter}{title}\hfill] [] [] [\hfill\doifsomethingelse{\namedstructurevariable{section}{title}} {\namedstructurevariable{section}{title}} {\namedstructurevariable{chapter}{title}}\hfill] Only a minor detail: is there a more proper way to center both headings? You can use the simple version of \setupheadertexts and use \doifoddpageelse to check whether you’re on a left or right page. When you make a test for content of a \getmarking command you have to use \doiftext because the \doifempty etc. checks don’t work in this case. \startsetups[header] \doifoddpageelse { \getmarking[chapter] } { \doiftextelse { \getmarking[section] } { \getmarking[section] } { \getmarking[chapter] } } \stopsetups \setupheadertexts[\directsetup{header}] \setupfootertexts[pagenumber] \starttext \chapter{Chapter A} \page \chapter{Chapter B} \page \dorecurse{5} {\chapter{Chapter #1} \dorecurse{10} {\section{Section #1.##1} \dorecurse{3}{\input knuth\par}}} \stoptext 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 ___