ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* luatex and javascript
@ 2008-12-07 11:59 Zhichu Chen
  2008-12-07 12:56 ` Taco Hoekwater
  0 siblings, 1 reply; 5+ messages in thread
From: Zhichu Chen @ 2008-12-07 11:59 UTC (permalink / raw)
  To: Mailing list for ConTeXt users

Hi,

I've searched the list and it seems that no one has been occurred
to my problem.

Has the javascript interface gone? 'cause I failed the following
simplest file:
================================================================
\setupinteraction[state=start]

\starttext

A few years back, \TEX\ could only produce \fillinfield [dvi]
{DVI} output, but nowadays, thanks to \fillinfield {Han The
Thanh}, we can also directly produce \fillinfield [pdf] {PDF}!
Nice eh? Actually, while the first field module was prototyped
in ACROBAT, the current implementation was debugged in
\fillinfield [pdfTeX] {\PDFTEX}. Field support in \fillinfield
[ConTeXt] {\CONTEXT} is rather advanced and complete and all
kind of fields are supported. One can hook in appearances, and
validation \fillinfield [JavaScripts] {JAVASCRIPT}'s. Fields
can be cloned and copied, where the latter saves some space. By
using \fillinfield {objects} when suited, this module saves
space anyway.

\stoptext
================================================================

It's copied from the mwidget-s.pdf

My luatex is 0.30.3, and I just run "luatools --generate" and
"ctxtools --update" today.

The error message is:
================================================================
! Undefined control sequence.
\:j::j:fields_1 ->
var
                       visible_field  = new Array() ; var visible_fields = 0...
\docommand ...code {\getvalue {\r!java \r!java #1}
                                                  }\ifoneJSpreamble \@EA \se...
\next2 #1,->\docommand {#1}
                           \doprocesscommaitem
<argument> \relax fields_1,
                           Do_Check_Answer
\doprocesscommalist ...aitem \gobbleoneargument #1
                                                  ,]\relax \global \advance ...
\presetJSpreamble ...[\allJSpreambles ]\docommand
                                                  \ifoneJSpreamble \gdef \al...
...
l.18 \stoptext

?
================================================================



-- 
Best Regards
Chen
----------------------------------------------------------------

          Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
         No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
             tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
                                               | www.sinap.ac.cn
----------------------------------------------------------------
___________________________________________________________________________________
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  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: luatex and javascript
  2008-12-07 11:59 luatex and javascript Zhichu Chen
@ 2008-12-07 12:56 ` Taco Hoekwater
  2008-12-07 13:10   ` Zhichu Chen
  2008-12-07 18:32   ` Hans Hagen
  0 siblings, 2 replies; 5+ messages in thread
From: Taco Hoekwater @ 2008-12-07 12:56 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Zhichu Chen wrote:
> Hi,
> 
> I've searched the list and it seems that no one has been occurred
> to my problem.
> 
> Has the javascript interface gone? 'cause I failed the following

No, just bugged. Hans ran into that himself yesterday, actually.
I cannot look up the actual fix from here, but it comes down to
a pretty simple catcode mixup. Hans will probably post it sometime
tomorrow.

Best wishes,
Taco

___________________________________________________________________________________
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  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: luatex and javascript
  2008-12-07 12:56 ` Taco Hoekwater
@ 2008-12-07 13:10   ` Zhichu Chen
  2008-12-07 18:32   ` Hans Hagen
  1 sibling, 0 replies; 5+ messages in thread
From: Zhichu Chen @ 2008-12-07 13:10 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Sun, Dec 7, 2008 at 8:56 PM, Taco Hoekwater <taco@elvenkind.com> wrote:
> Zhichu Chen wrote:
>> Hi,
>>
>> I've searched the list and it seems that no one has been occurred
>> to my problem.
>>
>> Has the javascript interface gone? 'cause I failed the following
>
> No, just bugged. Hans ran into that himself yesterday, actually.
> I cannot look up the actual fix from here, but it comes down to
> a pretty simple catcode mixup. Hans will probably post it sometime
> tomorrow.
OK, makes me feel a little released :) Thanks for the information.

>
> Best wishes,
> Taco
>
> ___________________________________________________________________________________
> 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  : https://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________
>



-- 
Best Regards
Chen
----------------------------------------------------------------

          Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
         No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
             tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
                                               | www.sinap.ac.cn
----------------------------------------------------------------
___________________________________________________________________________________
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  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: luatex and javascript
  2008-12-07 12:56 ` Taco Hoekwater
  2008-12-07 13:10   ` Zhichu Chen
@ 2008-12-07 18:32   ` Hans Hagen
  2008-12-08  1:07     ` Zhichu Chen
  1 sibling, 1 reply; 5+ messages in thread
From: Hans Hagen @ 2008-12-07 18:32 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Taco Hoekwater wrote:
> Zhichu Chen wrote:
>> Hi,
>>
>> I've searched the list and it seems that no one has been occurred
>> to my problem.
>>
>> Has the javascript interface gone? 'cause I failed the following
> 
> No, just bugged. Hans ran into that himself yesterday, actually.
> I cannot look up the actual fix from here, but it comes down to
> a pretty simple catcode mixup. Hans will probably post it sometime
> tomorrow.

\def\presetJSpreamble
   {\ifx\allJSpreambles\empty\else
      \bgroup
      \setverbosecscharacters
      \obeyspaces \let\obeyedspace\normalspace
      \def\par{\delcharacter}% was: { }
      \globallet\JSpreamble\empty
      \def\@@collectedJSpreamble{\r!java\r!java collected}%
      \letvalue{\@@collectedJSpreamble}=\empty
      \def\docommand##1%
        {\xdef\JScode{\getvalue{\r!java\r!java##1}}%
         \ifoneJSpreamble % \global\letcdcsname
           \@EA\setxvalue\@EA\@@collectedJSpreamble\@EA
             {\csname\@@collectedJSpreamble\endcsname\JScode}%
         \else
           \setxvalue{\r!java\r!java##1}{\JScode}%
         \fi}%
      \processcommacommand[\allJSpreambles]\docommand
      \ifoneJSpreamble
        \gdef\allJSpreambles{collected}%
      \fi
      \globallet\presetJSpreamble\relax
      \egroup
    \fi}



-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: luatex and javascript
  2008-12-07 18:32   ` Hans Hagen
@ 2008-12-08  1:07     ` Zhichu Chen
  0 siblings, 0 replies; 5+ messages in thread
From: Zhichu Chen @ 2008-12-08  1:07 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Mon, Dec 8, 2008 at 2:32 AM, Hans Hagen <pragma@wxs.nl> wrote:
> Taco Hoekwater wrote:
>> Zhichu Chen wrote:
>>> Hi,
>>>
>>> I've searched the list and it seems that no one has been occurred
>>> to my problem.
>>>
>>> Has the javascript interface gone? 'cause I failed the following
>>
>> No, just bugged. Hans ran into that himself yesterday, actually.
>> I cannot look up the actual fix from here, but it comes down to
>> a pretty simple catcode mixup. Hans will probably post it sometime
>> tomorrow.
>
> \def\presetJSpreamble
>   {\ifx\allJSpreambles\empty\else
>      \bgroup
>      \setverbosecscharacters
>      \obeyspaces \let\obeyedspace\normalspace
>      \def\par{\delcharacter}% was: { }
>      \globallet\JSpreamble\empty
>      \def\@@collectedJSpreamble{\r!java\r!java collected}%
>      \letvalue{\@@collectedJSpreamble}=\empty
>      \def\docommand##1%
>        {\xdef\JScode{\getvalue{\r!java\r!java##1}}%
>         \ifoneJSpreamble % \global\letcdcsname
>           \@EA\setxvalue\@EA\@@collectedJSpreamble\@EA
>             {\csname\@@collectedJSpreamble\endcsname\JScode}%
>         \else
>           \setxvalue{\r!java\r!java##1}{\JScode}%
>         \fi}%
>      \processcommacommand[\allJSpreambles]\docommand
>      \ifoneJSpreamble
>        \gdef\allJSpreambles{collected}%
>      \fi
>      \globallet\presetJSpreamble\relax
>      \egroup
>    \fi}
>

Thanks, it works now.
>
>
> -----------------------------------------------------------------
>                                           Hans Hagen | PRAGMA ADE
>               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
>      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
>                                              | www.pragma-pod.nl
> -----------------------------------------------------------------
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
>
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________
>



-- 
Best Regards
Chen
----------------------------------------------------------------

          Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
         No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
             tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
                                               | www.sinap.ac.cn
----------------------------------------------------------------
___________________________________________________________________________________
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  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-12-08  1:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-12-07 11:59 luatex and javascript Zhichu Chen
2008-12-07 12:56 ` Taco Hoekwater
2008-12-07 13:10   ` Zhichu Chen
2008-12-07 18:32   ` Hans Hagen
2008-12-08  1:07     ` Zhichu Chen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).