Re: [NTG-context] Fieldstacks are broken

2016-01-24 Thread Wolfgang Schuster

Jeong Dal 
24. Januar 2016 um 15:02
Dear Wolfgang and Fabrice,

I am sorry. I didn’t notice that there is a difference between my code 
and Fabrice’s.

I made a wrong comment.

I know that there are several options in the animation module: menu, 
menustyle, menucolor, framerate.

Would you please explain the menustyle option once more?

The key has no effect because there is only one style for the buttons.

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] doifnextcharelse

2016-01-24 Thread Wolfgang Schuster

Meer, Hans van der 
24. Januar 2016 um 15:58
Yes this works. But alas, the ultimate goal is to test against several 
characters and that seems impossible to do with standard ConTeXt 
api-macros.Let alone when these characters are . or . or ) etc.

\startluacode

function checknextstring(str)
if str == "a" then
context("A")
elseif str == "b" then
context("B")
else
context("??")
end
end

interfaces.implement { name = "readnextstring", actions = 
checknextstring,   arguments = "string" }


\stopluacode

\unprotect
\let\readnextstring\clf_readnextstring
\protect

\starttext

\readnextstring c
\readnextstring b
\readnextstring a
\readnextstring {xx}

\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] doifnextcharelse

2016-01-24 Thread Meer, Hans van der
Is it impossible to test on a blank with something alike  \doifnextcharelse ?

The implementation in the source skips blanks, but what if that is one doesn't 
want? For example to distinguish between "\abc \def" and \abc\def"?

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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] doifnextcharelse

2016-01-24 Thread Meer, Hans van der
Yes this works. But alas, the ultimate goal is to test against several 
characters and that seems impossible to do with standard ConTeXt api-macros.Let 
alone when these characters are . or . or ) etc.

Hans van der Meer

met vriendelijke groet
Hans van der Meer




> On 24 Jan 2016, at 15:13, Pablo Rodriguez  wrote:
> 
> On 01/24/2016 02:30 PM, dr. Hans van der Meer wrote:
>> I would like to differentiate on the following character being one of  X or 
>> not X.
>> But cannot get it right in \doifnextcharelse.
>> 
>> For example 
>> \def\mynextchar{\doifnextcharelse{X}{\def\Next{Y}}{\def\Next{Z}}\Next} 
>> delivers: ZX ZQ
>> then input: \mynextchar X \mynextchar Q
>> I hoped for YX ZQ, but it looks as if X tested false against X.
>> 
>> How to?
> 
> Hans,
> 
> the basic \def\mynextchar{\doifnextcharelse{x}{y}{z}} works.
> 
> With your sample:
> 
>\def\mynextchar{
>\doifnextcharelse{X}
>{\def\Next{Y}\Next}
>{\def\Next{Z}\Next}}
> 
> 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] Showcase of Title Pages done with ConTeXt ?

2016-01-24 Thread Ibn Saeed
Hello

I am trying to get a feel of what is possible with ConTeXt for designing
Title Pages or Cover Pages.

In LaTeX, i see the following title pages

http://ctan.asis.io/info/latex-samples/TitlePages/titlepages.pdf

and some are shown here

http://tex.stackexchange.com/questions/85904/showcase-of-beautiful-title-page-done-in-tex

What is the best way on setting up a title page in ConTeXt MarkIV and where
should i start?

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

2016-01-24 Thread Pablo Rodriguez
On 01/24/2016 02:30 PM, dr. Hans van der Meer wrote:
> I would like to differentiate on the following character being one of  X or 
> not X.
> But cannot get it right in \doifnextcharelse.
> 
> For example 
> \def\mynextchar{\doifnextcharelse{X}{\def\Next{Y}}{\def\Next{Z}}\Next} 
> delivers: ZX ZQ
> then input: \mynextchar X \mynextchar Q
> I hoped for YX ZQ, but it looks as if X tested false against X.
> 
> How to?

Hans,

the basic \def\mynextchar{\doifnextcharelse{x}{y}{z}} works.

With your sample:

\def\mynextchar{
\doifnextcharelse{X}
{\def\Next{Y}\Next}
{\def\Next{Z}\Next}}

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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Fieldstacks are broken

2016-01-24 Thread Jeong Dal
Dear Wolfgang and Fabrice,

I am sorry. I didn’t notice that there is a difference between my code and 
Fabrice’s.
I made a wrong comment.

I know that there are several options in the animation module: menu, menustyle, 
menucolor, framerate.  
Would you please explain the menustyle option once more?

Thank you so much.

Best regards,

Dalyoung

 
> 2016. 1. 24., 오후 9:55, ntg-context-requ...@ntg.nl 작성:
> 
> \unexpanded\def\MyGraphics#1%
>   {\startMPcode
>  ...
>\stopMPcode}
> 
> or
> 
> \define[1]\MyGraphics
>   {\startMPcode
>  ...
>\stopMPcode}

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

2016-01-24 Thread dr. Hans van der Meer
I would like to differentiate on the following character being one of  X or not 
X.
But cannot get it right in \doifnextcharelse.

For example 
\def\mynextchar{\doifnextcharelse{X}{\def\Next{Y}}{\def\Next{Z}}\Next} 
delivers: ZX ZQ
then input: \mynextchar X \mynextchar Q
I hoped for YX ZQ, but it looks as if X tested false against X.

How to?

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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Fieldstacks are broken

2016-01-24 Thread Jeong Dal
I am sorry, I forgot to  change the subject. I send it again.

***
Dear Fabrice,

I run the same file again and I think that main things in my log file is not 
different from yours.

Do you use Adobe Reader to view the pdf files?
The pdf viewer of TeXShop and that of TeXworks can not show the animation.

If you have the trouble even if you use the adobe reader, I don’t know the 
solution.

I hope that animation feature works in your computer.

Best regards,

Dalyoung

> 2016. 1. 24., 오후 8:40, ntg-context-requ...@ntg.nl 
>  작성:
> 
> Date: Sun, 24 Jan 2016 12:39:56 +0100
> From: Fabrice Couvreur  >
> To: mailing list for ConTeXt users  >
> Subject: Re: [NTG-context] Fieldstacks are broken
> Message-ID:
>>
> Content-Type: text/plain; charset="utf-8"
> 
> Hello everyone,
> I tested the code and it does not work: I get one page with buttons for
> animation is not working.
> thank you,
> Fabrice

___
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] ntg-context Digest, Vol 139, Issue 61

2016-01-24 Thread Jeong Dal
Dear Fabrice,

I run the same file again and I think that main things in my log file is not 
different from yours.

Do you use Adobe Reader to view the pdf files?
The pdf viewer of TeXShop and that of TeXworks can not show the animation.

If you have the trouble even if you use the adobe reader, I don’t know the 
solution.

I hope that animation feature works in your computer.

Best regards,

Dalyoung

> 2016. 1. 24., 오후 8:40, ntg-context-requ...@ntg.nl 작성:
> 
> Date: Sun, 24 Jan 2016 12:39:56 +0100
> From: Fabrice Couvreur  >
> To: mailing list for ConTeXt users  >
> Subject: Re: [NTG-context] Fieldstacks are broken
> Message-ID:
>>
> Content-Type: text/plain; charset="utf-8"
> 
> Hello everyone,
> I tested the code and it does not work: I get one page with buttons for
> animation is not working.
> thank you,
> Fabrice

___
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] Fieldstacks are broken

2016-01-24 Thread Wolfgang Schuster

Fabrice Couvreur 
24. Januar 2016 um 12:39
Hello everyone,
I tested the code and it does not work: I get one page with buttons 
for animation is not working.

thank you,
Fabrice

\def\MyGraphics#1{%
\unexpanded\def\MyGraphics#1{%
\startMPcode
path p,q;
p:=fullcircle scaled 72;
L:=length p;
N:=20;
q:=subpath (0,#1/N*L) of p;
draw q withcolor red;
fill fullcircle scaled 3 shifted point length q of q withcolor blue;
setbounds currentpicture to unitsquare shifted (-0.5,-0.5) scaled 75;
\stopMPcode}}
You have nested definition which is wrong,the correct way is one of the 
following ones (2 or 3 are recommended):


\unexpanded\def\MyGraphics#1%
  {\startMPcode
 ...
   \stopMPcode}

or

\define[1]\MyGraphics
  {\startMPcode
 ...
   \stopMPcode}

or

\starttexdefinition unexpanded MyGraphics #1
\startMPcode
...
\stopMPcode
\stoptexdefinition

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] Fieldstacks are broken

2016-01-24 Thread Fabrice Couvreur
Hello everyone,
I tested the code and it does not work: I get one page with buttons for
animation is not working.
thank you,
Fabrice

\def\MyGraphics#1{%
\unexpanded\def\MyGraphics#1{%
\startMPcode
path p,q;
p:=fullcircle scaled 72;
L:=length p;
N:=20;
q:=subpath (0,#1/N*L) of p;
draw q withcolor red;
fill fullcircle scaled 3 shifted point length q of q withcolor blue;
setbounds currentpicture to unitsquare shifted (-0.5,-0.5) scaled 75;
\stopMPcode}}
\usemodule[animation]
\setupinteraction[state=start]

\starttext
\startanimation[menu=yes]
{\MyGraphics {5}}
{\MyGraphics {10}}
{\MyGraphics {15}}
{\MyGraphics {20}}
\stopanimation

\stoptext

fab@debian:~$ context ntg43.tex

resolvers   | trees | analyzing 'home:texmf'
mtx-context | run 1: luatex
--fmt="/home/fab/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luatex/cont-en"
--jobname="ntg43"
--lua="/home/fab/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luatex/cont-en.lui"
--no-parse-first-line --c:currentrun=1 --c:fulljobname="./ntg43.tex"
--c:input="./ntg43.tex" --c:kindofrun=1 --c:maxnofruns=9 "cont-yes.mkiv"
This is LuaTeX, Version beta-0.88.0 (TeX Live 2016/dev)
 system commands enabled.

resolvers   > trees > analyzing 'home:texmf'

system  > callbacks > not registering frozen 'find_format_file'
open source > 1 > 1 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/cont-yes.mkiv

ConTeXt  ver: 2016.01.18 22:21 MKIV beta  fmt: 2016.1.22  int:
english/english

system  > 'cont-new.mkiv' loaded
open source > 2 > 2 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/cont-new.mkiv
close source> 2 > 2 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/cont-new.mkiv
system  > files > jobname 'ntg43', input './ntg43', result 'ntg43'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
open source > 2 > 3 > /home/fab/ntg43.tex
resolvers   > modules > 'animation' is loaded
open source > 3 > 4 >
/home/fab/context/tex/texmf-modules/tex/context/third/animation/t-animation.mkvi
close source> 3 > 4 >
/home/fab/context/tex/texmf-modules/tex/context/third/animation/t-animation.mkvi
fonts   > preloading latin modern fonts (second stage)
fonts   > 'fallback modern-designsize rm 12pt' is loaded
open source > 3 > 5 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/java-imp-fld.mkiv
close source> 3 > 5 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/java-imp-fld.mkiv
interactions> javascripts > loaded: library 'fld'
backend > xmp > using file
'/home/fab/context/tex/texmf-context/tex/context/base/mkiv/lpdf-pdx.xml'
pages   > flushing realpage 1, userpage 1
close source> 2 > 5 > /home/fab/ntg43.tex
close source> 1 > 5 >
/home/fab/context/tex/texmf-context/tex/context/base/mkiv/cont-yes.mkiv

mkiv lua stats  > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua
mkiv lua stats  > used cache path:
/home/fab/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e
mkiv lua stats  > resource resolver: loadtime 0.025 seconds, 1 scans with
scantime 0.013 seconds, 0 shared scans, 13 found files, scanned paths:
/home/fab/texmf
mkiv lua stats  > stored bytecode data: 383 modules (0.240 sec), 81 tables
(0.011 sec), 464 chunks (0.251 sec)
mkiv lua stats  > traced context: maxstack: 1169, freed: 9, unreachable:
1160
mkiv lua stats  > cleaned up reserved nodes: 42 nodes, 9 lists of 443
mkiv lua stats  > node memory usage: 2 glue, 2 penalty, 9 attribute, 27
glue_spec, 3 attribute_list, 2 temp, 1 pdf_literal
mkiv lua stats  > node list callback tasks: 6 unique task lists, 6
instances (re)created, 44 calls
mkiv lua stats  > used backend: pdf (backend for directly generating pdf
output)
mkiv lua stats  > jobdata time: 0.001 seconds saving, 0.000 seconds loading
mkiv lua stats  > callbacks: 226 direct, 1256 indirect, 1482 total
mkiv lua stats  > randomizer: resumed with value 0.6945844393664
mkiv lua stats  > loaded tex modules: 1 requested, all found (*-animation)
mkiv lua stats  > loaded patterns: en::2, load time: 0.000
mkiv lua stats  > interactive elements: 5 references, 0 destinations
mkiv lua stats  > result saved in file: ntg43.pdf, compresslevel 3,
objectcompresslevel 3
mkiv lua stats  > loaded fonts: 3 files: contnav.afm, latinmodern-math.otf,
lmroman12-regular.otf
mkiv lua stats  > font engine: otf 3.012, afm 1.500, tfm 1.000, 5
instances, load time 0.196 seconds
mkiv lua stats  > pdf annotations: 5 links (5 unique), 4 special
mkiv lua stats  > used platform: linux-64, type: unix, binary subtree:
texmf-linux-64
mkiv lua stats  > luatex banner: this is luatex, version beta-0.88.0 (tex
live 2016/dev)
mkiv lua stats  > control sequences: 43642 of 65536 + 10
mkiv lua stats  > lua properties: engine: lua, used memory: 57 MB (ctx: 57
MB), hash type: lua, hash chars: min(64,40)

[NTG-context] Incorrect boundingbox information in .tma files for Chinese OTF fonts

2016-01-24 Thread 李延瑞
Hi,

After updated minimals to 2016.01.18 22:21, I found that the boundingbox
information on some chinese puncts is not right.

For example, the comma(uni: FF0C, decimaly: 65292) in
Adobesongstd-light.otf font, boundingbox should be "{ 171, -58, 370, 240
}". But in the .tma file which is generated by context cmd, the boundingbox
of the comma is "{ 152, -33, 833, 648 }".  The attachment describe these.

Maybe there is problem in the process of loading otf fonts.

-- 
Best regards,

Li Yanrui (李延瑞)
___
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
___