Re: [NTG-context] Sources of Tutorial.text.pdf

2018-11-28 Thread luigi scarso
On Thu, Nov 29, 2018 at 8:10 AM Tommaso Gordini 
wrote:

> Thank you, Willi!
>
> I hope my ConTeXt guide will be a great work.
>
> "L'arte di scrivere in ConTeXt " -- where *you* are the author
(make a nice pair with
https://www.amazon.it/Larte-scrivere-LaTeX-Unintroduzione-LaTeX/dp/8854818097
)

here in Padua Luigi Scarso also lives, with whom I have known for years.
>
>
it's also the hometown of Enrico Gregorio
https://www.latex-project.org/news/2018/10/16/new-kids/

-- 
luigi
___
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] Sources of Tutorial.text.pdf

2018-11-28 Thread Tommaso Gordini
Thank you, Willi!

I hope my ConTeXt guide will be a great work.

here in Padua Luigi Scarso also lives, with whom I have known for years.

Thanks again
Tommy

Il gio 29 nov 2018, 08:06 Willi Egger  ha scritto:

> Aditya, no problem, I was of the same idea as you, but I thought it to be
> correct to ask. But I am fine with you sending the sources to Tommaso!
>
> Best
> Willi
>
> > On 28 Nov 2018, at 18:58, Aditya Mahajan  wrote:
> >
> > On Wed, 28 Nov 2018, Willi Egger wrote:
> >
> >> As being one of the authors, yes I have these file still here. — When
> the second author agrees I can deliver them to you. — However there is a
> warning to be made, that the project is 10 years old and was built in
> pdfTeX/ConTeXt MKII.
> >
> > Hi Willi,
> >
> > I sent the files to Thomas (without asking you I am afraid as I never
> thought that it would be an issue).
> >
> >
> Aditya___
> > If your question is of interest to others as well, please add an entry
> to the Wiki!
> >
> > maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context
> > webpage  : http://www.pragma-ade.nl / http://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] Sources of Tutorial.text.pdf

2018-11-28 Thread Willi Egger
Aditya, no problem, I was of the same idea as you, but I thought it to be 
correct to ask. But I am fine with you sending the sources to Tommaso!

Best
Willi

> On 28 Nov 2018, at 18:58, Aditya Mahajan  wrote:
> 
> On Wed, 28 Nov 2018, Willi Egger wrote:
> 
>> As being one of the authors, yes I have these file still here. — When the 
>> second author agrees I can deliver them to you. — However there is a warning 
>> to be made, that the project is 10 years old and was built in pdfTeX/ConTeXt 
>> MKII.
> 
> Hi Willi,
> 
> I sent the files to Thomas (without asking you I am afraid as I never thought 
> that it would be an issue).
> 
> Aditya___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://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] Language dependency in environment-project file

2018-11-28 Thread Wolfgang Schuster

Marco Patzer schrieb am 28.11.18 um 08:38:

On Tue, 27 Nov 2018 22:41:25 +0100
Wolfgang Schuster  wrote:


With named setups I need to specify a name for each occurrence and
gather them at the end. This is not as clean. Is it possible e.g. to
add something to an already existing setup instead of creating a new
one every time?

No, this is only possible with a token list.

Works perfectly.

Your first solution is technically better since it works even if the
language is changed mid document (something not used in this
project). However, the second solution is cleaner. I'll make up my mind.


The solution with the token list would be nicer if there where a way
to store the content in a similar fashion as buffers (which allow adding
content but this requires Lua) or setups.


\unprotect

\installnamespace {tokenlist}

\unexpanded\def\definetokenlist[#1]%
  {\expandafter\newtoks\csname\tokenlist#1\endcsname}

\unexpanded\def\starttokenlist[#1]#2\stoptokenlist
  {\ifcsname\tokenlist#1\endcsname \else
 \expandafter\newtoks\csname\tokenlist#1\endcsname
   \fi
   \expandafter\toksapp\csname\tokenlist#1\endcsname{#2}}

\def\gettokenlist[#1]%
  {\ifcsname\tokenlist#1\endcsname
 \expandafter\the\csname\tokenlist#1\endcsname
   \fi}

% \unexpanded\def\definetokenlist[#1]%
%   {\expandafter\let\csname\tokenlist#1\endcsname\empty}
%
% \unexpanded\def\starttokenlist[#1]#2\stoptokenlist
%   {\ifcsname\tokenlist#1\endcsname \else
%  \expandafter\let\csname\tokenlist#1\endcsname\empty
%    \fi
%    \expandafter\edef\csname\tokenlist#1\endcsname
% 
{\normalunexpanded\expandafter\expandafter\expandafter{\csname\tokenlist#1\endcsname}%

%   \normalunexpanded\expandafter{#2}}}
%
% \def\gettokenlist[#1]%
%   {\ifcsname\tokenlist#1\endcsname
%  \csname\tokenlist#1\endcsname
%    \fi}

\protect

\starttext

% \definetokenlist[test]

\starttokenlist[test]
a
\stoptokenlist

b

\starttokenlist[test]
c
\stoptokenlist

\gettokenlist[test]

\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] Installation on a PC

2018-11-28 Thread Nigel King
Dear Clyde,
Thank you very much for pointing us to this page. Before we send you any errors 
we will have another go and let you know whether we are successful.

—
Nigel
ni...@nigelking.me.uk

On 28 Nov 2018, at 11:59, Clyde Johnston  wrote:

These instructions should get the basic ConTeXt installed:
  https://wiki.contextgarden.net/ConTeXt_Standalone#Installation 

It is the other things that usually cause the problems though.

Clyde


 Forwarded Message 
Subject:Re: [NTG-context] Installation on a PC
Date:   Wed, 28 Nov 2018 13:44:44 +0200
From:   Clyde Johnston  
To: ntg-context@ntg.nl 

I am planning to update the installation instructions on the ConTeXt Garden 
Wiki.  The short answer is: no, not yet.  Are you planning a single-user or 
system-wide installation?  Do you plan to use SciTE or some other editor?  Are 
you using CygWin?  Send me the errors and some more details on you 
installation. I might be able to help.

On 28/11/2018 13:01, Nigel King wrote:
> Dear Group,
> I am a Mac user and have had many happy years using ConTeXt. I now need to 
> install ConTeXt on a PC (Windows) and this has been troublesome. Is anybody 
> able to point me to a foolproof method?
> 
> (I started this mail with all of our errors but reasoned that somebody might 
> know the answer to the more simple question.)
> 
> Thanks in advance.
> —
> Nigel
> ni...@nigelking.me.uk 
> 
> ___
> 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] (bug?) weird line break in firstlines-001.tex

2018-11-28 Thread Rik

On 11/28/2018 12:01, Pablo Rodriguez wrote:

Dear list,

the following code comes from firstlines-001.tex:

 \setupbodyfont
[pagella]

 \setupfirstline
[fancy]
[n=3]

 \starttext
  \setupindenting[medium,yes]

  \setfirstline[fancy]

  \input ward \par
 \stoptext

I’m afraid that the second and third lines have a weird line break. No
hyphens involved, but “not“ and “packs” are broken as “n ot” and “p acks”.

I think this may be a bug. Could anyone confirm this?

Many thanks for your help,

Pablo


Confirmed here with both the current beta and TL18.

--
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] Sources of Tutorial.text.pdf

2018-11-28 Thread Aditya Mahajan

On Wed, 28 Nov 2018, Willi Egger wrote:

As being one of the authors, yes I have these file still here. — When 
the second author agrees I can deliver them to you. — However there is a 
warning to be made, that the project is 10 years old and was built in 
pdfTeX/ConTeXt MKII.


Hi Willi,

I sent the files to Thomas (without asking you I am afraid as I never 
thought that it would be an issue).


Aditya___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Sources of Tutorial.text.pdf

2018-11-28 Thread Willi Egger
Hello Tommaso,

As being one of the authors, yes I have these file still here. — When the 
second author agrees I can deliver them to you. — However there is a warning to 
be made, that the project is 10 years old and was built in pdfTeX/ConTeXt MKII.

Kind regards

Willi

> On 28 Nov 2018, at 17:42, Tommaso Gordini  wrote:
> 
> Hi everyone,
> looking here and there on the Internet, I found a very interesting document 
> by Aditya Mahajan and Willi Egger: Beginners Tutorial. ConTeXt 
> (Tutorial-text.pdf), written in 2008 for the 2nd International ConTeXt User 
> Meeting in Bohinj, Slovenia.
> 
> This is a very interesting booklet, for me, congratulations to the authors!
> 
> Are there also the sources of it, somewhere?
> I'd like to get some ideas for the ConTeXt guide in Italian that I'm planning.
> In particular, I appreciated the way in which the commands are presented: «do 
> you need to do this? well, the commands that are useful to you are this and 
> that». I really appreciated that. :-)
> 
> Thank you in advance
> Thomas
> ___
> 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] Sources of Tutorial.text.pdf

2018-11-28 Thread Aditya Mahajan

On Wed, 28 Nov 2018, Tommaso Gordini wrote:


Hi everyone,
looking here and there on the Internet, I found a very interesting document
by Aditya Mahajan and Willi Egger: *Beginners Tutorial. ConTeXt *(
Tutorial-text.pdf), written in 2008 for the 2nd International ConTeXt User
Meeting in Bohinj, Slovenia.

This is a very interesting booklet, for me, congratulations to the authors!

Are there also the sources of it, somewhere?
I'd like to get some ideas for the ConTeXt guide in Italian that I'm
planning.
In particular, I appreciated the way in which the commands are presented:
«do you need to do this? well, the commands that are useful to you are this
and that». I really appreciated that. :-)


We did not publish the source anywhere, but they are still on my computer. 
I will send it to you offlist (the zip file is too big to be send on the 
list). Do keep in mind that these were generated in 2008 (using 
luaTeX-0.29, before there was split between mkii and mkiv). So, the setup 
will require some minor changes before it can be used.


Aditya___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] (bug?) weird line break in firstlines-001.tex

2018-11-28 Thread Pablo Rodriguez
Dear list,

the following code comes from firstlines-001.tex:

\setupbodyfont
   [pagella]

\setupfirstline
   [fancy]
   [n=3]

\starttext
 \setupindenting[medium,yes]

 \setfirstline[fancy]

 \input ward \par
\stoptext

I’m afraid that the second and third lines have a weird line break. No
hyphens involved, but “not“ and “packs” are broken as “n ot” and “p acks”.

I think this may be a bug. Could anyone confirm this?

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] Sources of Tutorial.text.pdf

2018-11-28 Thread Tommaso Gordini
Hi everyone,
looking here and there on the Internet, I found a very interesting document
by Aditya Mahajan and Willi Egger: *Beginners Tutorial. ConTeXt *(
Tutorial-text.pdf), written in 2008 for the 2nd International ConTeXt User
Meeting in Bohinj, Slovenia.

This is a very interesting booklet, for me, congratulations to the authors!

Are there also the sources of it, somewhere?
I'd like to get some ideas for the ConTeXt guide in Italian that I'm
planning.
In particular, I appreciated the way in which the commands are presented:
«do you need to do this? well, the commands that are useful to you are this
and that». I really appreciated that. :-)

Thank you in advance
Thomas
___
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] Installation on a PC

2018-11-28 Thread Clyde Johnston
I am planning to update the installation instructions on the ConTeXt 
Garden Wiki.  The short answer is: no, not yet.  Are you planning a 
single-user or system-wide installation?  Do you plan to use SciTE or 
some other editor?  Are you using CygWin?  Send me the errors and some 
more details on you installation. I might be able to help.



On 28/11/2018 13:01, Nigel King wrote:

Dear Group,
I am a Mac user and have had many happy years using ConTeXt. I now 
need to install ConTeXt on a PC (Windows) and this has been 
troublesome. Is anybody able to point me to a foolproof method?


(I started this mail with all of our errors but reasoned that somebody 
might know the answer to the more simple question.)


Thanks in advance.
—
Nigel
ni...@nigelking.me.uk 

___
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] Installation on a PC

2018-11-28 Thread Nigel King
Dear Group,
I am a Mac user and have had many happy years using ConTeXt. I now need to 
install ConTeXt on a PC (Windows) and this has been troublesome. Is anybody 
able to point me to a foolproof method?

(I started this mail with all of our errors but reasoned that somebody might 
know the answer to the more simple question.)

Thanks in advance.
—
Nigel
ni...@nigelking.me.uk___
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] Grammar to parse TeX input?

2018-11-28 Thread Hans Hagen

On 11/28/2018 9:33 AM, Joseph Canedo wrote:
I’d like to change some input to modify used font but only in parts of 
it, for example to implement having first line with different font. So 
basically if I have text with macros etc…:

% firstlines-001.tex

\setupbodyfont
  [pagella]

\setupalign
  [tolerant,stretch]

\setupfirstline
  [alternative=line,
   color=darkred,
   style=\setfontfeature{smallcaps}]

\setupfirstline
  [fancy]
  [n=3]

\setupfirstline
  [fancier]
  [alternative=word,
   color=darkblue,
   style=bold,
   n=3]

\setupfirstline
  [weirder]
  [alternative=line,
   color=darkgreen,
   style=\setfontfeature{smallcaps},
   n=3]

\setupinitial
  [location=text,
   n=2,
   color=darkred,
   voffset=1.2\lineheight,
   before={\blank[2*big]}]

% \enabletrackers[typesetters.firstlines,typesetters.initials]

\starttext

\setfirstline

\input ward \par

\placeinitial

\input ward \par

\setupindenting[medium,yes]

\setinitial % \placeinitial

\input ward \par

\setinitial %  \placeinitial
\setfirstline

\input ward \par

\setfirstline[fancy]

\input ward \par

\setfirstline[fancier]

\input ward \par

\setinitial %  \placeinitial
\setfirstline[weirder]

\input ward \par

\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] Language dependency in environment-project file

2018-11-28 Thread Marco Patzer
On Wed, 28 Nov 2018 09:20:49 +0100
Hans Hagen  wrote:

> An alternative is to use system modes:
> 
> \mainlanguage[nl]
> 
> % \startmode[*en]
> % \setupitemize[n]
> % \stopmode
> 
> % \startmode[*nl]
> % \setupitemize[a]
> % \stopmode
> 
> % \startmode[*de]
> % \setupitemize[i]
> % \stopmode
> 
> \startmodeset
>  [*en] {
>  \setupitemize[n]
>  }
>  [*nl] {
>  \setupitemize[a]
>  }
>  [*de] {
>  \setupitemize[i]
>  }
> \stopmodeset

I do use modes and modesets in this project, but mainly in the
components. In the environment files it's a bit more tricky because
the language is unknown at this point and the system modes trigger
the wrong language. But Wolfgang already provided a solution, which
works fine.

Marco
___
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] \everystarttext in components

2018-11-28 Thread Marco Patzer
On Wed, 28 Nov 2018 09:12:45 +0100
Hans Hagen  wrote:

> On 11/27/2018 9:40 PM, Marco Patzer wrote:
> > On Tue, 27 Nov 2018 18:42:51 +0100
> > Wolfgang Schuster  wrote:
> >   
> >>> Has that changed over the course of the last year or always been
> >>> that way?  
> >>
> >> This was always the case.  
> > 
> > OK, I'm wondering why I set it up that way back then. I'm sure I
> > tested it. But I don't remember.  
> with nested files (components etc) you can end up with
> 
> \starttext
>\starttext
>   \starttext
> 
> and it's the outer one that counts, so appending after that one is
> seen, won't help you

I (falsely) assumed it gets triggered on *every* \starttext, not just
the outer one.

Marco
___
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] Grammar to parse TeX input?

2018-11-28 Thread Joseph Canedo
I’d like to change some input to modify used font but only in parts of it, for 
example to implement having first line with different font. So basically if I 
have text with macros etc…:

\WORD{i}eu \Note[]{}{Ebrieux \LeftDot 11.a.}crea au commencement le ciel et la 
terre. Et la terre
estoit \Note[]{*}{{\Hebreu\Tav\He\Vav} c'est a dire/ vaine/ qui ne proffite et 
ne sert a rien.}indisposee et \Note[]{*}{{\Hebreu\Bet\He\Vav} non remplie & 
ornee/ de plantes et d'animaux.}vuyde/ et les tenebres estoient sus les 
abysmes/ et \Note[]{*}{Selon les Ebrieux/ ou esperit: car 
{\Hebreu\Dalet\Vav\Het} signifie vent & esperit.}le vent \Note[]{*}{ou/ 
vehement car {\Hebreu\Alef\Lamed\Resh\He\Yod\Memfinal} se prent aucunesfois 
pour hault/ excellent/ & puissant.}de Dieu se demenoit par dessus les eaues.

I’d like to typeset the beginning of that using a different font BigFont (but 
letting lua code to determine the position of closing brace). Ie :

{\BigFont \WORD{i}eu \Note[]{}{Ebrieux \LeftDot 11.a.}crea au commencement le 
ciel et la terre.} Et la terre
estoit \Note[]{*}{{\Hebreu\Tav\He\Vav} c'est a dire/ vaine/ qui ne proffite et 
ne sert a rien.}indisposee et \Note[]{*}{{\Hebreu\Bet\He\Vav} non remplie & 
ornee/ de plantes et d'animaux.}vuyde/ et les tenebres estoient sus les 
abysmes/ et \Note[]{*}{Selon les Ebrieux/ ou esperit: car 
{\Hebreu\Dalet\Vav\Het} signifie vent & esperit.}le vent \Note[]{*}{ou/ 
vehement car {\Hebreu\Alef\Lamed\Resh\He\Yod\Memfinal} se prent aucunesfois 
pour hault/ excellent/ & puissant.}de Dieu se demenoit par dessus les eaues.

To do this I’d need to extract the macros etc… « Worst » case scenario I’ll 
write a simple adhoc lpeg grammar to parse input, but was wondering if such 
grammar existed already in context lua code, or elsewhere.

Thanks

De : Hans Hagen
Envoyé le :mercredi 28 novembre 2018 09:04
À : Joseph Canedo; mailing list for ConTeXt users
Objet :Re: [NTG-context] Grammar to parse TeX input?

On 11/27/2018 11:00 PM, Joseph Canedo wrote:
> I’ve tried context.processbuffer but I am afraid it’s not what I am 
> after, most probably I have not phrased clearly my question.
> 
> What I am looking for is roughly what’s described in Taco’s presentation 
> https://meeting.contextgarden.net/2014/talks/2014-09-12-taco-luatex/luatextalk.pdf
> 
> A way to decompose some input into tokens which represent either normal 
> text, csnames etc…  I had a try to this token library in LuaTeX but I 
> could not find examples of how to use it. I suspect that buffers 
> mechanism use it somehow.
you can pick up stuff from the input so in principle you can start your 
input with a token scanner, but then you not only end up with lots of 
'tokens' but also need to interpret them ... and that is actually what 
tex is quite effecient in and good at, so the question is: what do you 
want to achieve ... there might be better ways

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] Language dependency in environment-project file

2018-11-28 Thread Hans Hagen

On 11/27/2018 10:05 PM, Wolfgang Schuster wrote:

Marco Patzer schrieb am 27.11.18 um 21:56:

On Tue, 27 Nov 2018 21:41:52 +0100
Wolfgang Schuster  wrote:


A nudge in the right direction appreciated.

\appendtoks
    \mainlanguage[\documentvariable{language}]%
%\doifdocumentvariable{language}{\mainlanguage[\documentvariable{language}]}% 


\to \everysetupdocument

That's basically what I've done in my project file (te-proj.tex). At
least the code is supposed to do exactly that.

But even your solution doesn't work here. Did you try it in the
example project file?


\startenvironment [*]

\startsetups [itemgroup:en]
   \setupitemgroup [itemize] [i]
\stopsetups

\startsetups [itemgroup:sv]
   \setupitemgroup [itemize] [a]
\stopsetups

\setuplanguage
   [en]
   [setups=itemgroup:en]

\setuplanguage
   [sv]
   [setups=itemgroup:sv]

\appendtoks
\doifdocumentvariable{language}{\mainlanguage[\documentvariable{language}]}
\to \everysetupdocument

\stopenvironment

An alternative is to use system modes:

\mainlanguage[nl]

% \startmode[*en]
% \setupitemize[n]
% \stopmode

% \startmode[*nl]
% \setupitemize[a]
% \stopmode

% \startmode[*de]
% \setupitemize[i]
% \stopmode

\startmodeset
[*en] {
\setupitemize[n]
}
[*nl] {
\setupitemize[a]
}
[*de] {
\setupitemize[i]
}
\stopmodeset

\starttext

\startitemize
\startitem test \stopitem
\startitem test \stopitem
\stopitemize

\stoptext

where modesets have a sort of special syntax (so probably only wolfgang 
and i know that this one exists),


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] \everystarttext in components

2018-11-28 Thread Hans Hagen

On 11/27/2018 9:40 PM, Marco Patzer wrote:

On Tue, 27 Nov 2018 18:42:51 +0100
Wolfgang Schuster  wrote:


Has that changed over the course of the last year or always been
that way?


This was always the case.


OK, I'm wondering why I set it up that way back then. I'm sure I
tested it. But I don't remember.

with nested files (components etc) you can end up with

\starttext
  \starttext
 \starttext

and it's the outer one that counts, so appending after that one is seen, 
won't help you


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] Grammar to parse TeX input?

2018-11-28 Thread Hans Hagen

On 11/27/2018 11:00 PM, Joseph Canedo wrote:
I’ve tried context.processbuffer but I am afraid it’s not what I am 
after, most probably I have not phrased clearly my question.


What I am looking for is roughly what’s described in Taco’s presentation 
https://meeting.contextgarden.net/2014/talks/2014-09-12-taco-luatex/luatextalk.pdf


A way to decompose some input into tokens which represent either normal 
text, csnames etc…  I had a try to this token library in LuaTeX but I 
could not find examples of how to use it. I suspect that buffers 
mechanism use it somehow.
you can pick up stuff from the input so in principle you can start your 
input with a token scanner, but then you not only end up with lots of 
'tokens' but also need to interpret them ... and that is actually what 
tex is quite effecient in and good at, so the question is: what do you 
want to achieve ... there might be better ways


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
___