Re: [NTG-context] More table questions

2020-09-22 Thread Aditya Mahajan
of table mechanism. The wiki has an example when using the (now deprecated) TaBlE macros https://wiki.contextgarden.net/Table#Booktabs The same effect is rather easy to achieve when using natural tables as well. \startsetups booktabs \setupTABLE[each][each][frame=off] \setupTABLE[row][first]

[NTG-context] Arabic support

2020-09-20 Thread Denis Maier
because > the notes mechanism resets many of these setups. > \startsetups[note:footnote] > \setupdirections[bidi=global] > \stopsetups > > \setupnote[footnote][setups=note:footnote] % align=righttoleft Is that still true? Anything else I need to

Re: [NTG-context] Best way to store text for later use

2020-09-19 Thread Denis Maier
by setups such as this one: there is no linear processing, you just start someplace and recursively deal with the tree (which often looks like linear when you start at the root but basically you can access everything everywhere) \startsetups abstract \startabstract     \docume

Re: [NTG-context] Best way to store text for later use

2020-09-19 Thread Hans Hagen
no linear processing, you just start someplace and recursively deal with the tree (which often looks like linear when you start at the root but basically you can access everything everywhere) \startsetups abstract     \startabstract         \documentvariable{abstract}     \stopabstract \

Re: [NTG-context] Best way to store text for later use

2020-09-18 Thread Denis Maier
erstanding of how these things work. I thought storing the text and retrieving it later would be the easiest way to get rid of the constraints of linar processing of the XML file. The layout itself is determined by setups such as this one: \startsetups abstract     \startabstract         \docume

Re: [NTG-context] Footnote font size equal to main text font size

2020-09-16 Thread Wolfgang Schuster
Jairo A. del Rio schrieb am 15.09.2020 um 04:38: Hi, list. I've adapted the following example from the mailing list. My aim is to use endnotes for each chapter: \mainlanguage[es] \definehead[footnotetitle][title] \startsetups[chapter:after] \ifcase\rawcountervalue[footnote]\relax      

Re: [NTG-context] Footnote font size equal to main text font size

2020-09-16 Thread Henning Hraban Ramm
> Am 15.09.2020 um 04:38 schrieb Jairo A. del Rio : > > Hi, list. I've adapted the following example from the mailing list. My aim is > to use endnotes for each chapter: > > \mainlanguage[es] > \definehead[footnotetitle][title] > \startsetups[chapter:after] >

[NTG-context] update and meeting

2020-09-15 Thread Hans Hagen
as Hala who had to struggle with the old one but still gave a presentation using it. Here's an example: \definedocument[thesis] \setupdocument[a=b,e=f] \setupdocument[thesis][a=x,c=d] % \startsetups[thesis:start] \startsetups[document:start] START \stopsetups \startsetups[thesis

[NTG-context] Footnote font size equal to main text font size

2020-09-14 Thread Jairo A. del Rio
Hi, list. I've adapted the following example from the mailing list. My aim is to use endnotes for each chapter: \mainlanguage[es] \definehead[footnotetitle][title] \startsetups[chapter:after] \ifcase\rawcountervalue[footnote]\relax \else \startfootnotetitle[title={

Re: [NTG-context] Quotation with footnote

2020-09-04 Thread Henning Hraban Ramm
> Am 04.09.2020 um 16:20 schrieb Wolfgang Schuster > : > > \startsetups [userdata:myquote] > \startnarrow [left=2em,right=1.5em] > %\dontleavehmode\llap{\symbol[leftquotation]}\getinlineuserdata\symbol[rightquotation] > \symbol[leftquotation]\getinlineuserdata\

Re: [NTG-context] Quotation with footnote

2020-09-04 Thread Wolfgang Schuster
? \startsetups [userdata:myquote]     \startnarrow [left=2em,right=1.5em] %\dontleavehmode\llap{\symbol[leftquotation]}\getinlineuserdata\symbol[rightquotation]     \symbol[leftquotation]\getinlineuserdata\symbol[rightquotation]     \doifsomething{\userdataparameter{source}} {\footnote[\userdataparameter

Re: [NTG-context] headers again

2020-08-13 Thread Hans Hagen
ve me that will lead me to finding my own solution? It would be much appreciated. A rose by any other name would smell as sweet ... \showframe \setupheadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stopsetups \starttext \startchapter[title={This is a chapte

Re: [NTG-context] headers again

2020-08-13 Thread jbf
not a direct solution, are there any clues someone might give me that will lead me to finding my own solution? It would be much appreciated. A rose by any other name would smell as sweet ... \showframe \setupheadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stops

Re: [NTG-context] headers again

2020-08-13 Thread Aditya Mahajan
roduces the correct result, utlimatley, in the > > > TOC, Is it possible that I may have something else in my preamble that > > > is causing the problem? If so, I can't expect someone to 'guess' that > > > from outside! But at the moment I don't think that

Re: [NTG-context] weird issue with xtable

2020-08-13 Thread Pablo Rodriguez
On 8/13/20 10:11 PM, Wolfgang Schuster wrote: > Wolfgang Schuster schrieb am 13.08.2020 um 20:47: >> [...] >> You can use nested frames: >> >> \startsetups[...] >>     \startframed[offset=overlay,frame=off] >>     \framed[width=.22\textiwdth]{\pinter}

Re: [NTG-context] weird issue with xtable

2020-08-13 Thread Wolfgang Schuster
\pcentr\NC\latext\NC\pexter\NC\NR \stoptabulate You can use nested frames: \startsetups[...]     \startframed[offset=overlay,frame=off]     \framed[width=.22\textiwdth]{\pinter}     \framed[width=.24\textiwdth]{\latint}     \framed[width=.08\textiwdth]{\pcentr}     \framed[width

Re: [NTG-context] weird issue with xtable

2020-08-13 Thread Wolfgang Schuster
can use nested frames: \startsetups[...] \startframed[offset=overlay,frame=off] \framed[width=.22\textiwdth]{\pinter} \framed[width=.24\textiwdth]{\latint} \framed[width=.08\textiwdth]{\pcentr} \framed[width=.24\textiwdth]{\latext} \framed[width=.22

[NTG-context] tabulation and \textwidth

2020-08-13 Thread Pablo Rodriguez
Dear list, I have this sample: \showframe \startsetups[footers] \starttabulate [|cw(.5\textwidth)| cw(.5\textwidth)|] [unit=0pt] \NC one\NC two\NC\NR \stoptabulate \stopsetups \setupfootertexts[\directsetup{footers}] \starttext \dorecurse{20}{\input{zapf.tex}\par

Re: [NTG-context] headers again

2020-08-13 Thread Wolfgang Schuster
rose by any other name would smell as sweet ... \showframe \setupheadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stopsetups \starttext \startchapter[title={This is a chapter}] \input knuth \page \input knuth \stopchapter \startchapter[title={This is a title}, num

Re: [NTG-context] headers again

2020-08-12 Thread jbf
eadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stopsetups and referencing it in the \chapter or \title items, was able to achieve the desired result in every way, including that missing  header on one page. Thank you. J On 13/8/20 3:36 pm, Aditya Mahajan wrote: On T

Re: [NTG-context] headers again

2020-08-12 Thread jbf
ive me that will lead me to finding my own solution? It would be much appreciated. A rose by any other name would smell as sweet ... \showframe \setupheadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stopsetups \starttext \startchapter[title={This is a chapter}] \in

Re: [NTG-context] headers again

2020-08-12 Thread Aditya Mahajan
someone might give me that > will lead me to finding my own solution? It would be much appreciated. A rose by any other name would smell as sweet ... \showframe \setupheadertexts[\setups{header}] \startsetups header \getmarking[chapter] \stopsetups \starttext \startchapter[title={This is

[NTG-context] Help on tweaking alignment, page numbers and ToC

2020-08-11 Thread Nicola
, conversion=Romannumerals, numbercommand=\groupedcommand{\blank[20mm]}{\blank[10mm]}, after={\blank[3cm]}, ] \setupheadtext[content=] \setupheadertexts[] \setupheadertexts[\setups{text a}][][][\setups{text b}] \startsetups[text a] \rlap{whatever} \hfill \getmarking[chapter] \hfill

Re: [NTG-context] orphans and widows not working in LMTX?

2020-08-09 Thread Joseph Canedo
llowing sample: > > \showframe\showgrid > \setuppapersize[A7] > \setuplayout[setups=*lessstrict] > \startsetups[*lessstrict] > \widowpenalty=1000 > \clubpenalty=1000 > \brokenpenalty=1000 > \stopsetups > \setupbodyfont[

[NTG-context] orphans and widows not working in LMTX?

2020-08-09 Thread Pablo Rodriguez
Dear list, I have the following sample: \showframe\showgrid \setuppapersize[A7] \setuplayout[setups=*lessstrict] \startsetups[*lessstrict] \widowpenalty=1000 \clubpenalty=1000 \brokenpenalty=1000 \stopsetups \setupbodyfont[15pt] \starttext

Re: [NTG-context] Placing a section ending depending on odd/even sectionnumber

2020-08-05 Thread Willi Egger
le below shows a > better method. > > 2. What you do with \doifelse{...}{even} is to compare the numeric value of > the section with the string "even" which is always false. To check whether > the value is odd or even you have to use the \ifodd command. > >>

Re: [NTG-context] Placing a section ending depending on odd/even sectionnumber

2020-08-04 Thread Wolfgang Schuster
to compare the numeric value of the section with the string "even" which is always false. To check whether the value is odd or even you have to use the \ifodd command. What to change in order to get the desired result? begin example \startsetups [section:odd] \vfill \bo

[NTG-context] Placing a section ending depending on odd/even sectionnumber

2020-08-04 Thread Willi Egger
Hi, now I have another hurdle to be taken :-) — Depending on the odd or even number of the section I have to place an ornament at the end of the section. I have sofar the following setup: \define\stopmysection {\setups{endsection}} \startsetups endsection \doifelse

Re: [NTG-context] lmtx update

2020-08-01 Thread Otared Kavian
[margin] [] [{\directsetup{notabene}}] \newbox\MyNoteOverflow \setupnotation[endnote] [interaction=yes, after={\blank[big]}] \startsetups notabene \setbox\scratchbox\vbox \bgroup \setupalign[tolerant] \ifvoid\MyNo

Re: [NTG-context] lmtx update

2020-08-01 Thread Hans Hagen
ayout [cutspace=5cm, width=middle, margin=4cm] \setuptexttexts [margin] [] [{\directsetup{notabene}}] \startsetups notabene \vbox to \textheight \bgroup \setupalign[tolerant] \topskipcorrection \placenotes[endnote][before=,after=] \vfilll \e

Re: [NTG-context] About testing rest of space on a page

2020-07-30 Thread Willi Egger
>>> >>> Good evening! >>> >>> I have a bookproject in which sections are ended with a small graphical >>> element. Now as usual this graphic might be moved to a new page which is of >>> course unwanted. >>> >>> A

Re: [NTG-context] ntg-context Digest, Vol 193, Issue 65

2020-07-30 Thread Jan Hansen
; Subject: Re: [NTG-context] Unknown script 'fonts.lua' or >'mtx-fonts.lua' > Message-ID: > Content-Type: text/plain; charset=US-ASCII; format=flowed > >> On Thu, 30 Jul 2020, Marcus Vinicius Mesquita wrote: >> >> Hi, Hans >> >>

Re: [NTG-context] About testing rest of space on a page

2020-07-30 Thread Wolfgang Schuster
have: \startsetups endsection \vfil \placefigure[middle,none][]{}{\externalfigure[ornament2][height=2\lineheight]} \stopsection \stopsetups \def\stopmysection{\setups{endsection}} I use then instead of \stopsection the \stopmysection. This works except that the ornament is in some cases

Re: [NTG-context] About testing rest of space on a page

2020-07-30 Thread Taco Hoekwater
> On 29 Jul 2020, at 23:08, Willi Egger wrote: > > Good evening! > > I have a bookproject in which sections are ended with a small graphical > element. Now as usual this graphic might be moved to a new page which is of > course unwanted. > > At this momen

[NTG-context] About testing rest of space on a page

2020-07-29 Thread Willi Egger
Good evening! I have a bookproject in which sections are ended with a small graphical element. Now as usual this graphic might be moved to a new page which is of course unwanted. At this moment I have: \startsetups endsection \vfil \placefigure[middle,none][]{}{\externalfigure[ornament2

Re: [NTG-context] Store images and text in the right margin

2020-07-06 Thread Fabrice Couvreur
s on what you want to achieve exactly, I think > > \useMPlibrary[dum] > > \setuppapersize[A4] > > \setuplayout > [width=12cm, >rightmargin=5cm] > > \defineuserdata [margintext] [alternative=margintext] > > \defineuserdataalternative [margintext] > [rend

Re: [NTG-context] Store images and text in the right margin

2020-07-06 Thread Taco Hoekwater
=userdata:margintext] \startsetups [userdata:margintext] \margindata [inright] [style={\switchtobodyfont[9pt]}, width=\rightmarginwidth, align={flushleft,broad}, stack=yes] {\startframedtext[before=,after=,offset=0pt,width=max,frame=off] \getinlineuserdata

Re: [NTG-context] Store images and text in the right margin

2020-07-02 Thread Fabrice Couvreur
right] > > \setupmargindata [marginfigure][command=\vbox,align=middle] > > \setupmargindata [marginfigure][command=\vbox,align=middle,stack=yes] > > > \startsetups [userdata:margintext] > > \margindata > > [inright] > > [%style=\smallbodyfont, > > st

Re: [NTG-context] Store images and text in the right margin

2020-07-02 Thread Marco Patzer
lign=middle] \setupmargindata [marginfigure][command=\vbox,align=middle,stack=yes] > \startsetups [userdata:margintext] > \margindata > [inright] > [%style=\smallbodyfont, > style={\switchtobodyfont[9pt]}, > width=\rightmarginwidth, stack=yes, >

Re: [NTG-context] Typesetting poetry with particular indenting

2020-07-02 Thread Tommaso Gordini
idth=force, align=flushleft, before=, after=, frame=off] \definenarrower[poemnarrower] \definelines [poemlines] [before={\startpoemnarrower[left]}, after=\stoppoemnarrower] \definebuffer[poem] \def\stoppoem{\setups{poems:buffer}} \startsetups poems:buffer \set

[NTG-context] Store images and text in the right margin

2020-07-02 Thread Fabrice Couvreur
] \setupmargindata [marginfigure][command=\vbox,align=middle] \defineuserdata [margintext] [alternative=margintext] \defineuserdataalternative [margintext] [renderingsetup=userdata:margintext] \startsetups [userdata:margintext] \margindata [inright] [%style=\smallbodyfont, style

Re: [NTG-context] \hideframe to cancel \showframe

2020-06-30 Thread Mikael Sundqvist
t a few values for > the \setupbackgrounds command which can be done by hand. > > To make everything a bit nice I put the backgrounds setup in a > setup-block and call only these blocks in the document. > > begin example > \startsetups[showframe] > \setupbac

Re: [NTG-context] \hideframe to cancel \showframe

2020-06-30 Thread Wolfgang Schuster
ample \startsetups[showframe] \setupbackgrounds [header,text,footer] [leftmargin,text,rightmargin] [frame=on] \stopsetups \startsetups[hideframe] \setupbackgrounds [header,text,footer] [leftmargin,text,rightmargin] [frame=off] \stopsetups \starttext \input knuth \page \setup[showframe] \input

Re: [NTG-context] margin comment above heading

2020-06-18 Thread Pablo Rodriguez
On 6/17/20 10:47 PM, Wolfgang Schuster wrote: > Pablo Rodriguez schrieb am 16.06.2020 um 22:17: >> Dear list, >> >> I have the following sample: >> >>\startsetups[tinytiny] >> \setupwhitespace[-2em] >> \setupbodyfont[0.01pt] >>

Re: [NTG-context] margin comment above heading

2020-06-17 Thread Henning Hraban Ramm
> Am 17.06.2020 um 22:47 schrieb Wolfgang Schuster > : > > Pablo Rodriguez schrieb am 16.06.2020 um 22:17: >> Dear list, >> I have the following sample: >> \startsetups[tinytiny] >> \setupwhitespace[-2em] >> \setupbodyfont[0.01pt] >>

Re: [NTG-context] margin comment above heading

2020-06-17 Thread Wolfgang Schuster
Pablo Rodriguez schrieb am 16.06.2020 um 22:17: Dear list, I have the following sample: \startsetups[tinytiny] \setupwhitespace[-2em] \setupbodyfont[0.01pt] \setupinterlinespace[1sp] \stopsetups ??? \setupinteraction[state=start] \showframe\showgrid \starttext

[NTG-context] margin comment above heading

2020-06-16 Thread Pablo Rodriguez
Dear list, I have the following sample: \startsetups[tinytiny] \setupwhitespace[-2em] \setupbodyfont[0.01pt] \setupinterlinespace[1sp] \stopsetups \setupinteraction[state=start] \showframe\showgrid \starttext \blank[force, 10em] \section{Move comment above this

Re: [NTG-context] reduced space below chapter title

2020-06-02 Thread Wolfgang Schuster
as well as maintaining the style of the standard chapter head. You can add a check for odd/even chapter numbers and use only a single command. \startsetups[chapter:after]   \ifodd\namedheadnumber{chapter}     \blank[4cm]   \else     \blank[1cm]   \fi \stopsetups \setuphead   [chapter

Re: [NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread Henning Hraban Ramm
In a similar setup I wanted to start every chapter with image and short vita the author and came up with the following (of course not without help from our wizards): \definefont[ChapterFont][Sans*default at 30pt] \startsetups normalheader % default numbers of my bodyfont are oldstyle

Re: [NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread Jan U. Hasecke
Hi Wolfgang, thank you very much. Amazing! Am 29.05.20 um 15:35 schrieb Wolfgang Schuster: > \definedataset [chapter] > > \startsetups [chapter:before] > >   \page[yes] > >   \doglobal\increment\ChapterCounter > >   \doifoddpageelse >     {} >     {\doifsom

Re: [NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread Wolfgang Schuster
found now way to put it on the even page. So what I really want to achieve is a way to redefine this setups at some point in the text to insert eg. a picture on the even page before a chapter. \startsetups [chapter:before]    \doifoddpageelse {} {\pushbackground[page

Re: [NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread Jan U. Hasecke
TEXpage is >> not counted >> correctly like a normal page.  And secondly I found now way to put it >> on the >> even page. >> >> So what I really want to achieve is a way to redefine this setups at >> some point >> in the text to insert eg. a picture

Re: [NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread Wolfgang Schuster
this setups at some point in the text to insert eg. a picture on the even page before a chapter. \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=blue,] \page[empty,right] \popbackground

[NTG-context] Let chapter start on odd page and make the even page before show an image

2020-05-29 Thread juh
to insert eg. a picture on the even page before a chapter. \startsetups [chapter:before] \doifoddpageelse {} {\pushbackground[page] \setupbackgrounds[page][background=color,backgroundcolor=blue,] \page[empty,right] \popbackground} \stopsetups Here comes the not so mwe

Re: [NTG-context] bug in \doifinset

2020-05-27 Thread Wolfgang Schuster
a way to create readable lists, below is another one but in the end it depends on your use case. begin example \starttext \startsetups [check] \doifelseinset { i7 } { i4, i5, i7, } {yes}

Re: [NTG-context] Anyone managed a tabulated table of contents

2020-05-25 Thread Hans Hagen
en you knwo the dimensions you can do this: \usemodule[article-basic] \definelistalternative [whatever] [renderingsetup=whatever] \setuplist [chapter] [alternative=whatever] \startsetups whatever \framed [offset=overlay,frame=off] { \framed [width=25mm,align=flushleft,frame

Re: [NTG-context] two additional pagenumber series

2020-04-29 Thread Wolfgang Schuster
[section:chapter] [way=bychapter] \definecounter [section:section] [way=bysection] \appendtoks \incrementcounter[section:chapter]% \incrementcounter[section:section]% \to \everybeforepagebody \startsetups[header:pagenumber] \starttabulate[|l|rw(1em)|] \NC Pagenumber \EQ \pagenumber

Re: [NTG-context] splitted xtable with repeating headers and placetable

2020-04-05 Thread Wolfgang Schuster
ader area). \setuppapersize[A4,landscape] \setuplayout [location=middle, width=27.5cm, height=18cm, backspace=1cm, header=4cm, headerdistance=5mm] \startsetups[header] \startframed[width=max,height=max,frame=off,offset=overlay] \startframed[height=1cm,width=max,frame=o

Re: [NTG-context] \placenamedfloat and \setuphead[aftersection=...] broken?

2020-04-02 Thread Benjamin Buchmuller
he Wiki’s ConTeXt online) or have been disabled/changed >> for some reason? >> Thanks! >> Benjamin >> (1) palcenamedfloat >> --- >> This is the example from the Wiki: >> [...] >> (2) Footnotes at the end of each chapter >> ---

Re: [NTG-context] \placenamedfloat and \setuphead[aftersection=...] broken?

2020-04-02 Thread Wolfgang Schuster
Also an example from the Wiki: \startsetups chapter:after \ifcase\rawcountervalue[footnote]\relax \or \startsubject[title=Footnote] \placefootnotes \stopsubject \else \startsubject[title=Footnotes

[NTG-context] \placenamedfloat and \setuphead[aftersection=...] broken?

2020-04-02 Thread Benjamin Buchmuller
each chapter Also an example from the Wiki: \startsetups chapter:after \ifcase\rawcountervalue[footnote]\relax \or \startsubject[title=Footnote] \placefootnotes \stopsubject \else

Re: [NTG-context] \startquotation and citations

2020-03-26 Thread Michael Guravage
Thank you Wolfgang, Now is there a way to persuade the quotation marks to protrude? Cheers, Michael \startsetups[userdata:extendedquotation] \startnarrow[] “\getinlineuserdata”\userdataparameter{source} \stopnarrow \stopsetups \defineuserdataalternative [extendedquotation

Re: [NTG-context] \startquotation and citations

2020-03-26 Thread Wolfgang Schuster
use the userdata environment to create a custom environment with optional arguments. \startsetups[userdata:extendedquotation] \startnarrow[middle=4em] “\getinlineuserdata”\userdataparameter{source} \stopnarrow \stopsetups \defineuserdataalternative [extendedquotation] [renderingsetup=userdata:e

Re: [NTG-context] Left hanging hyphen

2020-03-05 Thread Tomas Hala
Hi Wolfgang, # You can use the default language for the reset: # # \startsetups [language:czech] # \setbreakpoints [czcompound] # \stopsetups # # \startsetups [language:other] # \resetbreakpoints # \stopsetups # # \setuplanguage # [cz] # [setups=language:czech] # # \setuplanguage

Re: [NTG-context] Left hanging hyphen

2020-03-04 Thread Wolfgang Schuster
inlanguage[\langpar] > } > > which repeats only the Czech hyphen but with a side effect -- hyphenated > words are not broken anymore in other languages. > What am I doing wrong? Or is there any system solution? > %% > > Best wishes, > > Tomáš > > > begin ex

Re: [NTG-context] Left hanging hyphen

2020-03-04 Thread Tomas Hala
reakpoints [czcompound] \definebreakpoint [czcompound] [-] [nleft=3,nright=3,type=4] \startsetups [czech] \setbreakpoints [czcompound] \stopsetups \setuplanguage [cz] [setups=czech] \definefontfeature [default] [default] [protrusion=tomas_hala] %\def\mylanguage{cs} \appendtoks \ifx\mylanguage\currentlan

Re: [NTG-context] Left hanging hyphen

2020-03-02 Thread Wolfgang Schuster
pound] \definebreakpoint [czcompound] [-] [nleft=3,nright=3,type=4] \startsetups [czech] \setbreakpoints [czcompound] \stopsetups \setuplanguage [cz] [setups=czech] \definefontfeature [default] [default] [protrusion=tomas_hala] \setupalign [hanging] \mainlanguage [cz] \showframe [text] [

[NTG-context] Last names in citations

2020-02-28 Thread Fulvio Satta
aps:cite:margin][authorconversion=normalshort] \startsetups btx:aps:cite:margin \texdefinition{btx:aps:title} \texdefinition{btx:aps:author} \doiftextelse\currentbtxrighttext{ \currentbtxrighttext } { \removeunwantedspaces \removepunctuation } this works and is perfect for my style, b

[NTG-context] column(sets) questions

2020-01-18 Thread Henning Hraban Ramm
width depends on the columnset? e.g. like \definecolumnsetspan[Title][n=2] \definecolumnsetspan[Intro][n=2] \startsetups cs:TwoCol \setupcolumnsetspan[Title][n=2] \setupcolumnsetspan[Intro][n=1] \stopsetups \startsetups cs:ThreeCol \setupcolumnsetspan[Title][n=3] \setupcolumns

Re: [NTG-context] fancy chapter setup

2020-01-13 Thread Wolfgang Schuster
on and the \page command in my setup, the header text changed too early. \definedataset[chapter] \startsetups[chapter:leftpage]     \page[left]     \doglobal\increment\ChapterData     \doifsomething{\datasetvariable{chapter}{\ChapterData}{subtitle}}     {     \starttabulate  

Re: [NTG-context] fancy chapter setup

2020-01-12 Thread Henning Hraban Ramm
Since the structureuservariables of a section aren’t defined in that section’s "before", I would need a macro or buffer to define the contents of that epigraph page, like this: \def\PreImg{Dummy} \startsetups FancyChapter \setupheadertexts[][][][] \doifelsebu

Re: [NTG-context] fancy chapter setup

2020-01-12 Thread Henning Hraban Ramm
”, while “My Fancy Story” doesn’t show anything. Is that why you used buffers? Since I only need two user settings (image name and quote), only one in the example, I’d like to avoid a buffer for every chapter. \startsetups FancyChapter \setupheadertexts[][][][] \doifnot{\structureuse

Re: [NTG-context] fancy chapter setup

2020-01-11 Thread Rik Kabel
in a separate overlay to better control the positioning. Perhaps a bit overthought, but it works for me ... \setupheadertexts [][{\it\getmarking[section]}]   [{\it\getmarking[chapter]}][] \startsetups section:epigraph   \doifelsebuffer{SectionEpigraph}     {\getbu

[NTG-context] Problem with the bottom line of a header

2019-10-22 Thread Fabrice Couvreur
)-- (0,1.05*OverlayHeight)--cycle; fill p shifted (3,-3); fill p withcolor 0.8white; draw p; setbounds currentpicture to p; \stopuseMPgraphic \defineoverlay[framewithshadow][\useMPgraphic{framewithshadow}] \definecolor[ColorA][0.8(white)] \startsetups [headertext

Re: [NTG-context] passing variables/data between context and lua

2019-10-08 Thread Aditya Mahajan
alue of a key can be cumbersome to read. So, we can use setups: \def\totalpoints{0} \startsetups updatepoints \edef\totalpoints{\the\numexpr(\totalpoints + \getvariable{exam}{points})\relax} \stopsetups \setvariables [exam] [ points=0, set=\directsetup{updatepoints}, ]

Re: [NTG-context] Unexpected behavior of subsection labels

2019-10-06 Thread Wolfgang Schuster
onset [frontpart:pagenumber] [] [romannumerals] \startsectionblockenvironment [bodypart] \setcounter [userpage] [1] \stopsectionblockenvironment \setuppagenumbering[location=,alternative=doublesided] \setupheadertexts[\setups{text right}][][][\setups{text left}] \startsetups[text right] \rlap{} \hfill \sc \getma

[NTG-context] Unexpected behavior of subsection labels

2019-10-06 Thread Jairo A. del Rio
[frontpart:pagenumber] [] [romannumerals] \startsectionblockenvironment [bodypart] \setcounter [userpage] [1] \stopsectionblockenvironment \setuppagenumbering[location=,alternative=doublesided] \setupheadertexts[\setups{text right}][][][\setups{text left}] \startsetups[text right] \rlap{} \hfill \sc \getmarking

Re: [NTG-context] passing variables/data between context and lua

2019-10-06 Thread Wolfgang Schuster
to use braces or brackets as delimiters for the argument. The \directsetup skips the check for the argument form and allows only braces as delimiter. \startsetups[example-1]     \startparagraph     First example!     \stopparagraph \stopsetups \startsetups[example-2]     \startparagraph

Re: [NTG-context] passing variables/data between context and lua

2019-10-05 Thread Rudolf Bahr
> A solution which uses only existing commands in the document. > > \startsetups [martin] > \startlua > local points = tonumber(\getvariable{martin}{question}) or 0 ; > points = points * 92 ; > local answer = 42 ; > context.setv

Re: [NTG-context] passing variables/data between context and lua

2019-09-29 Thread Martin Althoff
es only existing commands in the document. > > \startsetups [martin] > \startlua > local points = tonumber(\getvariable{martin}{question}) or 0 ; >points = points * 92 ; > local answer = 42 ; > context.setvariable("martin",&q

Re: [NTG-context] passing variables/data between context and lua

2019-09-27 Thread Wolfgang Schuster
\stoptext A solution which uses only existing commands in the document. \startsetups [martin]     \startlua     local points = tonumber(\getvariable{martin}{question}) or 0 ;   points = points * 92 ;     local answer = 42 ;     context.setvariable("martin&q

Re: [NTG-context] Problem of displaying a date with a macro

2019-09-09 Thread Hans Hagen
gt; >  \definecolor[ColorA][0.8(white)] > > >  \startsetups [headertext] > >    \setupheadertexts >      [{\startframed [headerframed] >      [foregroundstyle=bold,background=framewithshadow] >      \getvariable{headertext}{title}

Re: [NTG-context] Problem of displaying a date with a macro

2019-09-09 Thread Fabrice Couvreur
8 instead of day 2. > > Thank you > > Fabrice > > > > \defineframed > >[headerframed] > >[frame=off, > > height=fit, > > width=fit] > > > > \definecolor[ColorA][0.8(white)] > > > > > > \startsetups [headertex

Re: [NTG-context] no pagenumber depending of number of lines?

2019-09-08 Thread Henning Hraban Ramm
age number. >> >> Is there a simple solution to that request? >> Otherwise I delete the page numbers from the PDF... > % remove header when the text fills less than half of the page > > \startsetups[chapter:after] > \par > \ifdim\pagetotal<.5\pagegoal

Re: [NTG-context] no pagenumber depending of number of lines?

2019-09-08 Thread Wolfgang Schuster
... % remove header when the text fills less than half of the page \startsetups[chapter:after]     \par     \ifdim\pagetotal<.5\pagegoal     \page[header,yes]     \fi \stopsetups % remove header when there are less than 20 lines of text % \startsetups[chapter:after] % \par % \getnofli

Re: [NTG-context] My own marks

2019-08-31 Thread Jon Wong
Hi all, Sorry, I corrected my MWE. As you can see, \currentitemnumber seems strange when used for \marking inside a nested itemize. MWE: \definemarking[M] \startsetups S default=(\getmarking[M])~ first=(\getmarking[M][first])~ last=(\getmarking[M][last])~ previous=(\getmarking[M

Re: [NTG-context] My own marks

2019-08-31 Thread Jon Wong
Hi all, It seems that \currentitemnumber won’t work for \marking if inside a nested itemize? MWE: \definemarking[M] \startsetups S default=(\getmarking[M])~ first=(\getmarking[M][first])~ last=(\getmarking[M][last])~ previous=(\getmarking[M][previous])~ both=(\getmarking[M][both

Re: [NTG-context] setupinterlinespace affects headers and footers

2019-08-31 Thread Jon Wong
Hi Wolfgang! Sadly, it still didn’t work: \startsetups[headertext] \startframed[frame=off,align=flushright,width=fit] \setuplocalinterlinespace[12pt] \the\baselineskip\\ abc \stopframed \stopsetups \setupheadertexts[\directsetup{headertext}] \starttext \setupinterlinespace

Re: [NTG-context] setupinterlinespace affects headers and footers

2019-08-31 Thread Jon Wong
Hi, Yikes! Erm… MWE: \startsetups[headertext] \startframed[frame=off,align=flushright,width=fit] { \setupinterlinespace[12pt] \the\baselineskip\\ abc } \stopframed \stopsetups \setupheadertexts[\directsetup{headertext}] \starttext { \setupinterlinespace[24pt] \input

[NTG-context] My own marks

2019-08-31 Thread Jon Wong
Hi all, How does \marking really work? Can’t seem to get \currentitemnumber into it. MWE: \definemarking[M] \startsetups S \getmarking[M] \stopsetups \setupheadertexts[\setups{S}][][][\setups{S}] \starttext \startitemize[n] \item First item \marking[M]{Really? \currentitemnumber

Re: [NTG-context] Problem of displaying a date with a macro

2019-08-28 Thread Aditya Mahajan
On Wed, 28 Aug 2019, Fabrice Couvreur wrote: Hello, The date display is incorrect : I get day 28 instead of day 2. Thank you Fabrice \defineframed [headerframed] [frame=off, height=fit, width=fit] \definecolor[ColorA][0.8(white)] \startsetups [headertext

[NTG-context] Problem of displaying a date with a macro

2019-08-28 Thread Fabrice Couvreur
Hello, The date display is incorrect : I get day 28 instead of day 2. Thank you Fabrice \defineframed [headerframed] [frame=off, height=fit, width=fit] \definecolor[ColorA][0.8(white)] \startsetups [headertext] \setupheadertexts [{\startframed [headerframed

Re: [NTG-context] Frame with shadow for header

2019-08-27 Thread Mikael P. Sundqvist
eaderframed] > [frame=off, > height=fit, > width=fit] > > \definecolor[ColorA][0.8(white)] > > > \startsetups [headertext] > > \setupheadertexts > [{\startframed [headerframed] > [foregroundstyle=bold,background=color,backgr

Re: [NTG-context] Frame with shadow for header

2019-08-27 Thread Fabrice Couvreur
, topframe=off, bottomframe=off, framecolor=, rulethickness=2pt] \defineframed [headerframed] [frame=off, height=fit, width=fit] \definecolor[ColorA][0.8(white)] \startsetups [headertext] \setupheadertexts [{\startframed [headerframed

Re: [NTG-context] \setupheadertexts \setupfootertexts

2019-08-02 Thread Hans Hagen
solutions, even if we leave in place for reasons of backward compatibility habits that can be hard to quit. What limitations? \foo[{sometext}] is not that different from \foo[text={sometext}] and often I do \setupheadertexts[\setups[header}] \startsetups lots of stuff \stopsetups because

Re: [NTG-context] Strange behavior in somewhat complex layout (again)

2019-06-27 Thread Andres Conrado Montoya
; (even) page, everything works as expected (no color-filled page, no header > in the start-chapter page). > > MWE: > > %% START MWE > > [...] > > \startsetups [chapter:before] >\doifoddpageelse > {} > {\pushbackground[p

Re: [NTG-context] Strange behavior in somewhat complex layout (again)

2019-06-27 Thread Wolfgang Schuster
he color filled page. But, if the start-chapter page comes after a regular (even) page, everything works as expected (no color-filled page, no header in the start-chapter page). MWE: %% START MWE [...] \startsetups [chapter:before]    \doifoddpageelse      

[NTG-context] Strange behavior in somewhat complex layout (again)

2019-06-27 Thread Andres Conrado Montoya
l (bottomboundary Page -- cycle) enlarged(0,0.25u) shifted (0,6i) withcolor \MPcolor{rojo} ; fi; StopPage; \stopuseMPgraphic \defineoverlay [chapter:background] [\useMPgraphic{page:background}] \setupbackgrounds[page][background=chapter:background

[NTG-context] Strange behavior in somewhat complex layout

2019-06-23 Thread Andres Conrado Montoya
lor{rojo} ; fi; StopPage; \stopuseMPgraphic \defineoverlay [chapter:background] [\useMPgraphic{page:background}] \setupbackgrounds[page][background=chapter:background] \definepagebreak[firstpagebreak][yes,header] \startsetups [chapter:before] \doifoddpageelse {} {\pushbac

Re: [NTG-context] Creating one's own style

2019-05-18 Thread Alan Braslau
language= {english}, hyphenation = {english}, % ignored pagetotal = {206}, % ignored pages = {206}, } \stopbuffer \usebtxdataset[bib.buffer] \usebtxdefinitions[apa] \setupbtx[apa:cite:authoryear][left={[},right={]}] \startsetups btx:apa:list:book \btxdoif {author} {

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