Re: [NTG-context] Registers and getparameters

2018-01-22 Thread Otared Kavian
Hi Wolfgang,

Thanks a lot! Indeed with removing the \doflushatpar and putting the page 
reference out of the tabulate solves all the problems.

Have a nice day: Otared K.

> On 22 Jan 2018, at 22:38, Wolfgang Schuster  
> wrote:
> 
> 
>> Otared Kavian  22. Januar 2018 um 21:39
>> Hi Wolfgang,
>> 
>> Thank you very much for your reply and your wise advice to use the 
>> \setvariable mechanism. It is indeed much more convenient to use for what I 
>> intend to do.
>> 
>> The only remaining problem is that when several talks are included in my 
>> file (in the following example there three of them), then the entries to the 
>> register are correct but the associated pagenumbers are incorrect and are 
>> given the last pagenumber: in the following example all three talks are 
>> given the pagenumber 4 in the register. Is there something I am doing wrong?
> I moved the link for the page number to the next paragraph because putting 
> the reference command into the tabulate environment hasn’t worked but in your 
> example the first paragraph starts on the last page. This was necessary 
> because the \pagereference starts a new paragraph which results in an empty 
> line before the table. A way to fix the page number is to omit the 
> \doflushatpar command, the table itself can be moved upwards by a line with a 
> negative vertical skip (\vskip-).
> 
> \startbuffer[pagetalk]
>  %\blank
>   \expanded{\pagereference[talk:\getvariable{talk}{speakername}]}%
>   \expanded{\speakers{\getvariable{talk}{speakername}}}%
>   \vskip-\lineheight
>   \starttabulate[|f{\bi}l|p|][before=]%
>   \NC Speaker \EQ \getvariable{talk}{speakername} \NC\NR
>   \NC Title   \EQ \getvariable{talk}{title}   \NC\NR
>   \NC Time\EQ \getvariable{talk}{time}\NC\NR
>   \NC Room\EQ \getvariable{talk}{room}\NC\NR
>   \HL
>   \stoptabulate
> \stopbuffer
> 
> 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
> ___

___
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] Registers and getparameters

2018-01-22 Thread Wolfgang Schuster



Otared Kavian 
22. Januar 2018 um 21:39
Hi Wolfgang,

Thank you very much for your reply and your wise advice to use the 
\setvariable mechanism. It is indeed much more convenient to use for 
what I intend to do.


The only remaining problem is that when several talks are included in 
my file (in the following example there three of them), then the 
entries to the register are correct but the associated pagenumbers are 
incorrect and are given the last pagenumber: in the following example 
all three talks are given the pagenumber 4 in the register. Is there 
something I am doing wrong?
I moved the link for the page number to the next paragraph because 
putting the reference command into the tabulate environment hasn’t 
worked but in your example the first paragraph starts on the last page. 
This was necessary because the \pagereference starts a new paragraph 
which results in an empty line before the table. A way to fix the page 
number is to omit the \doflushatpar command, the table itself can be 
moved upwards by a line with a negative vertical skip (\vskip-).


\startbuffer[pagetalk]
 %\blank
  \expanded{\pagereference[talk:\getvariable{talk}{speakername}]}%
  \expanded{\speakers{\getvariable{talk}{speakername}}}%
  \vskip-\lineheight
  \starttabulate[|f{\bi}l|p|][before=]%
  \NC Speaker \EQ \getvariable{talk}{speakername} \NC\NR
  \NC Title   \EQ \getvariable{talk}{title}   \NC\NR
  \NC Time\EQ \getvariable{talk}{time}\NC\NR
  \NC Room\EQ \getvariable{talk}{room}\NC\NR
  \HL
  \stoptabulate
\stopbuffer

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] Support for musl

2018-01-22 Thread Henri
On Mon, 2018-01-22 at 20:09 +0100, Andreas Schneider wrote:
> Am Freitag, den 19.01.2018, 12:22 +0100 schrieb Mojca Miklavec:
> > 
> > On 19 January 2018 at 11:40, Henri Menke wrote:
> > > 
> > > Dear list,
> > > 
> > > I'd like to support Linux platforms which use musl (https://www.mus
> > > l-libc.org/) instead of glibc, like for instance Alpine Linux.
> > > 
> > > How would I go about this?  Can you share existing build scripts
> > > for, e.g. Linux-64?  Do I have to provide build infrastructure?
> > Can you please raise that question on the TeX Live mailing list?
> > 
> > If TL team is not willing to support it, we can still do it
> > ourselves,
> > but let's first see if there's an "official" way to support it, also
> > with respect to naming.
> You can link musl statically which makes these binaries run basically
> everywhere, so it's actually a win for everybody.

You cannot link musl statically if you use the dynamic linker (dlopen) which is 
needed for the FFI
in LuaTeX and LuaJITTeX.  Just search online for "musl dlopen", e.g. with Google
https://google.com/search?q=musl%20dlopen

> The only downsides of musl against libc that I am aware of are some
> restrictions in DNS lookups (it doesn't use NSS) and that it may not
> link easily against C++ ... but that should be a one-time-fix at source
> code level and full fledged DNS support shouldn't matter for TeX
> anyway.
> 
> Anyway: IMHO it's worth it and I'm also all for it since I prefer
> Alpine as well :D
> (I compile my projects using Alpine as well and statically link it
> against musl to have binaries that run on all possible linux
> distributions independant of their underlying libc.)
> 
> Best regards
> Andreas
> ___
> 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] Registers and getparameters

2018-01-22 Thread Otared Kavian
Hi Wolfgang,

Thank you very much for your reply and your wise advice to use the \setvariable 
mechanism. It is indeed much more convenient to use for what I intend to do.

The only remaining problem is that when several talks are included in my file 
(in the following example there three of them), then the entries to the 
register are correct but the associated pagenumbers are incorrect and are given 
the last pagenumber: in the following example all three talks are given the 
pagenumber 4 in the register. Is there something I am doing wrong?

Thanks agin for your time and attention: Otared K.
%%% begin register-talks.tex
\setupinteraction[state=start]
\defineregister[speakers]

\setupregister
  [speakers]
  [style=sansbold,
   n=2]

\startbuffer[pagetalk]
  \doflushatpar 
{\expanded{\speakers{\getvariable{talk}{speakername}}}%
 \expanded{\pagereference[talk:\getvariable{talk}{speakername}]}}%
  \starttabulate[|f{\bi}l|p|]
  \NC Speaker \EQ \getvariable{talk}{speakername} \NC\NR
  \NC Title   \EQ \getvariable{talk}{title}   \NC\NR
  \NC Time\EQ \getvariable{talk}{time}\NC\NR
  \NC Room\EQ \getvariable{talk}{room}\NC\NR
  \HL
  \stoptabulate
\stopbuffer

\setvariable{talk}{set}{\getbuffer[pagetalk]}

\showframe[text][text]

\starttext

\setvariables[talk]
[speakername={Gauss},
title={Remarks on Number Theory},
time={10:30},
room={A}]


\page

\setvariables[talk]
[speakername={Poincaré},
title={Remarks on Relativity},
time={16:30},
room={B}]

\page

\setvariables[talk]%
[speakername={Dirac},
title={Quaternions and the wave equation},
time={15:30},
room={B}]

\page

The talk about Gauss is on \at{page}[talk:Gauss].

\completeregister[speakers]

\stoptext
%%% end register-talks.tex

> On 22 Jan 2018, at 20:26, Wolfgang Schuster  > wrote:
> 
> 
>> Otared Kavian  22. Januar 2018 um 19:53
>> Hi all,
>> 
>> I have a list of speakers (and abstracts of their talk) in a rather long 
>> document, and the name of each speaker is written to a register named 
>> speakers. 
>> Then with the command \getparameters[Talk] I get the name of each speaker 
>> and try to write it to the register with
>> 
>> \speakers{\TalkSpeakerName}
> 
> You have to add \expanded, i.e. \expanded{\speakers{...}}.
> 
>> Indeed this does not work to obtain the result I am looking for: the sorting 
>> is indeed under the letter « t », and most importantly the register gets 
>> only the last name in the list instead of getting each speaker name.
>> 
>> The following is a (not so minimal…) example. Can anyone help me in this 
>> matter?
> 
> When you replace \getparameters with \setvariables you can set a command
> which is applied each time when you set new values.
> 
> 
> \defineregister[speakers]
> 
> \setupregister
>   [speakers]
>   [style=sansbold,
>n=2]
> 
> \startbuffer[pagetalk]
>   \doflushatpar 
> {\expanded{\speakers{\getvariable{talk}{speakername}}}%
>  \expanded{\pagereference[talk:\getvariable{talk}{speakername}]}}%
>   \starttabulate[|f{\bi}l|p|]
>   \NC Speaker \EQ \getvariable{talk}{speakername} \NC\NR
>   \NC Title   \EQ \getvariable{talk}{title}   \NC\NR
>   \NC Time\EQ \getvariable{talk}{time}\NC\NR
>   \NC Room\EQ \getvariable{talk}{room}\NC\NR
>   \HL
>   \stoptabulate
> \stopbuffer
> 
> \setvariable{talk}{set}{\getbuffer[pagetalk]}
> 
> \showframe[text][text]
> 
> \starttext
> 
> \setvariables
>   [talk]
>   [speakername={Gauss},
>title={Remarks on Number Theory},
>time={10:30},
>room={A}]
> 
> The talk about Gauss was on \at{page}[talk:Gauss].
> 
> \completeregister[speakers]
> 
> \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 
> ___

___
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] Registers and getparameters

2018-01-22 Thread Wolfgang Schuster



Otared Kavian 
22. Januar 2018 um 19:53
Hi all,

I have a list of speakers (and abstracts of their talk) in a rather 
long document, and the name of each speaker is written to a register 
named speakers.
Then with the command \getparameters[Talk] I get the name of each 
speaker and try to write it to the register with


\speakers{\TalkSpeakerName}


You have to add \expanded, i.e. \expanded{\speakers{...}}.

Indeed this does not work to obtain the result I am looking for: the 
sorting is indeed under the letter « t », and most importantly the 
register gets only the last name in the list instead of getting each 
speaker name.


The following is a (not so minimal…) example. Can anyone help me in 
this matter?


When you replace \getparameters with \setvariables you can set a command
which is applied each time when you set new values.


\defineregister[speakers]

\setupregister
  [speakers]
  [style=sansbold,
   n=2]

\startbuffer[pagetalk]
  \doflushatpar
{\expanded{\speakers{\getvariable{talk}{speakername}}}%
 \expanded{\pagereference[talk:\getvariable{talk}{speakername}]}}%
  \starttabulate[|f{\bi}l|p|]
  \NC Speaker \EQ \getvariable{talk}{speakername} \NC\NR
  \NC Title   \EQ \getvariable{talk}{title}   \NC\NR
  \NC Time\EQ \getvariable{talk}{time}\NC\NR
  \NC Room\EQ \getvariable{talk}{room}\NC\NR
  \HL
  \stoptabulate
\stopbuffer

\setvariable{talk}{set}{\getbuffer[pagetalk]}

\showframe[text][text]

\starttext

\setvariables
  [talk]
  [speakername={Gauss},
   title={Remarks on Number Theory},
   time={10:30},
   room={A}]

The talk about Gauss was on \at{page}[talk:Gauss].

\completeregister[speakers]

\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
___

[NTG-context] issue with \hyphenatedword

2018-01-22 Thread Pablo Rodriguez
Dear list,

I have the following sample:

\setuppapersize[A9]
\starttext
\hyphenatedword{office}
office

\hsize\zeropoint
office
\hyphenatedword{office}
\stoptext

Compiling with latest beta (2018.01.19 13:42), hyphen isn’t used in
\hyphenated word and the character after ffi is removed.

Could anyone confirm the issue?

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] Support for musl

2018-01-22 Thread Andreas Schneider
Am Freitag, den 19.01.2018, 12:22 +0100 schrieb Mojca Miklavec:
> On 19 January 2018 at 11:40, Henri Menke wrote:
> > Dear list,
> > 
> > I'd like to support Linux platforms which use musl (https://www.mus
> > l-libc.org/) instead of glibc, like for instance Alpine Linux.
> > 
> > How would I go about this?  Can you share existing build scripts
> > for, e.g. Linux-64?  Do I have to provide build infrastructure?
> 
> Can you please raise that question on the TeX Live mailing list?
> 
> If TL team is not willing to support it, we can still do it
> ourselves,
> but let's first see if there's an "official" way to support it, also
> with respect to naming.

You can link musl statically which makes these binaries run basically
everywhere, so it's actually a win for everybody.
The only downsides of musl against libc that I am aware of are some
restrictions in DNS lookups (it doesn't use NSS) and that it may not
link easily against C++ ... but that should be a one-time-fix at source
code level and full fledged DNS support shouldn't matter for TeX
anyway.

Anyway: IMHO it's worth it and I'm also all for it since I prefer
Alpine as well :D
(I compile my projects using Alpine as well and statically link it
against musl to have binaries that run on all possible linux
distributions independant of their underlying libc.)

Best regards
Andreas
___
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] Registers and getparameters

2018-01-22 Thread Otared Kavian
Hi all,

I have a list of speakers (and abstracts of their talk) in a rather long 
document, and the name of each speaker is written to a register named speakers. 
Then with the command \getparameters[Talk] I get the name of each speaker and 
try to write it to the register with

\speakers{\TalkSpeakerName}

Indeed this does not work to obtain the result I am looking for: the sorting is 
indeed under the letter « t », and most importantly the register gets only the 
last name in the list instead of getting each speaker name.

The following is a (not so minimal…) example. Can anyone help me in this matter?
Thanks in advance for your attention and time!
Best regards: OK

%%% begin register-speaker.tex
\defineregister[speakers]
\setupregister[speakers] [
style=sansbold,   %% headings
n=2,  %% columns
]

\define\MakePageTalk{%
\reference[ref:\TalkSpeakerName]{}
{\bi Speaker~:\/} \TalkSpeakerName \speakers{\TalkSpeakerName}.\crlf
{\bi Title :} \TalkTitle \crlf
{\bi Time:} \TalkTime \crlf
{\bi Room :} \TalkRoom\crlf 
\hairline\par}

\starttext 
\getparameters[Talk]%
[SpeakerName={Gauss},
Title={Remarks on Number Theory},
Time={10:30},
Room={A}]
\MakePageTalk

\page

\getparameters[Talk]%
[SpeakerName={Poincaré},
Title={Remarks on Relativity},
Time={16:30},
Room={B}]
\MakePageTalk

\page

\getparameters[Talk]%
[SpeakerName={Dirac},
Title={Quaternions and the wave equation},
Time={15:30},
Room={B}]
\MakePageTalk

\page

\completeregister[speakers]

\stoptext
%%% end register-speaker.tex
___
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] Support for musl

2018-01-22 Thread luigi scarso
On Sun, Jan 21, 2018 at 9:49 PM, Henri  wrote:
> Thus the following binaries remain untested by me:
:
> mpost
mpost can be done in the same manner as luatex, the repository is the same
https://serveur-svn.lri.fr/svn/modhel/metapost


-- 
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
___