Re: [NTG-context] hanging in captions

2006-02-08 Thread Adam Lindsay
Taco Hoekwater wrote:
 Peter Münster wrote:
 \setupcaptions[align={hz,hanging}]
 
 I don't believe that is supposed to work, but I do not
 understand why the handling is reset inside the caption.
 
 This works (but is unwieldy if you have lots of floats):
 
 \placefigure%
{\setupalign[hz,hanging]
 \input tufte }
{\framed[width=\textwidth]{bla}}

With the original poster's code, the 'hz' part is superfluous (with 
'normal' handling). Still, I spent a couple minutes with it last night, 
and it remained a mystery to me, too.
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  Adam T. Lindsay, Computing Dept. [EMAIL PROTECTED]
  Lancaster University, InfoLab21+44(0)1524/510.514
  Lancaster, LA1 4WA, UK Fax:+44(0)1524/510.492
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Movies

2006-02-08 Thread Hans van der Meer
In my presentation sheets I want to put some movies (quicktime or  
mpeg4 and the like).
I did do what is in the manual but somehow it stopped working for me  
in Adobe Reader (7.0.5 Mac)(not sure why, might be newer final cut  
pro, might be something else). So I thought: perhaps somewhat more  
control exercised over the contents of the pdf objects might help.

The manual has not much more on movie inclusion therefore I searched  
through the source.
In cont-new.tex I found things like
% \useexternalrendering[example-5][video/quicktime] [p1000726.mov]
and maybe that is what I was looking for. I adapted the movie name  
and tried to test with the example given in cont-new.tex (starting at  
line 1581) and --lo and behold-- now got a playing movie.

But, with:
\definerenderingwindow
[movie]
[background=color,backgroundcolor=gray,
 openpageaction=StartCurrentRendering,
 closepageaction=NextPage]% StopCurrentRendering]
I now get the opening frame of the window on all pages of the sheets  
instead of only on the one containing the movie. How can I change  
that to an appearance on that specific page only?

In the menu only the Startbutton worked. The buttons were set with:
\def\renderingmenu[#1]%
{\hbox
   {\setupbuttons[width=2.5em]%
\button{\symbol[StartMovie]} [StartMovie{#1}]\enspace
\button{\symbol[StopMovie]}  [StopMovie{#1}]\enspace
\button{\symbol[PauseMovie]} [PauseMovie{#1}]\enspace
\button{\symbol[ResumeMovie]}[ResumeMovie{#1}]}}
I changed the part Rendering from the example to Movie as there  
are keys PauseMovie etc. in mult-con.tex.
As said, only StartMovie reacted as expected.

Is there some -- how rudimentary it may be -- documentation about  
this? Where do I look for it?

yours sincerely,
dr. H. van der Meer



___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Movies

2006-02-08 Thread Hans Hagen
Hans van der Meer wrote:
 The manual has not much more on movie inclusion therefore I searched  
 through the source.
 In cont-new.tex I found things like
   % \useexternalrendering[example-5][video/quicktime] [p1000726.mov]
 and maybe that is what I was looking for. I adapted the movie name  
 and tried to test with the example given in cont-new.tex (starting at  
 line 1581) and --lo and behold-- now got a playing movie.
   
the rendering stuff is a bit too complex for what you want

how about

\externalfigure[mymovie.mov][width=4cm,height=3cm,preview=yes]

Hans

 

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

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Movies

2006-02-08 Thread Hans van der Meer


On Feb 8, 2006, at 17:19, Hans Hagen wrote:

 Hans van der Meer wrote:
 The manual has not much more on movie inclusion therefore I searched
 through the source.
 In cont-new.tex I found things like
  % \useexternalrendering[example-5][video/quicktime] [p1000726.mov]
 and maybe that is what I was looking for. I adapted the movie name
 and tried to test with the example given in cont-new.tex (starting at
 line 1581) and --lo and behold-- now got a playing movie.

 the rendering stuff is a bit too complex for what you want

 how about

 \externalfigure[mymovie.mov][width=4cm,height=3cm,preview=yes]

That's what I had and somehow could not get working again.
I therefore did some experimenting and now I have something working:

\setupinteraction[menu=on,state=start]
\def\renderingmenu[#1]%
{\hbox
   {\setupbuttons[width=16mm,height=12mm]%
\button{\symbol[StartRendering]} [StartRendering{#1}]\enspace
\button{\symbol[StopRendering]}  [StopRendering{#1}]\enspace
\button{\symbol[PauseRendering]} [PauseRendering{#1}]\enspace
\button{\symbol[ResumeRendering]}[ResumeRendering{#1}]}}

In the above I first thought StartMovie etc would work but  
StartRendering etc did the trick. As of the special purpose of  
StartMovie and friends I am still in the dark.

\definerenderingwindow
[movie]
[width=1.33\makeupheight,height= 
\makeupheight,strut=no,offset=0pt,frame=off,
 background=color,backgroundcolor=BackgroundColor,
 closepageaction=StopCurrentRendering]

I had to remove the openpageaction from the example in the context  
fle and then it stopped putting the movie on each and every page once  
it had been opened.
Finally typesetting the movie with:

\useexternalrendering[purple][video/quicktime][purpleshort.mov]
\defineoverlay
[theimage]
[{\externalfigure[themovie][width=\overlaywidth,height= 
\overlayheight,type=jpg]}]
starttext
\hfill\framed[offset=0pt,strut=no,background={foreground,theimage}]
{\placerenderingwindow[movie][themovie]}\hfill\null

As you can seen I placed the movie in a framed. This because I wanted  
the still image showing over it (you mentioned a preview=yes I will  
later experiment with it. I guess it also will work here?
The PROBLEM I encountered was that I thought to change the  
renderingwindow's background with a local call to
\setuprenderingwindow[movie][parameters leading to the overlay as in  
framed]
but to no avail.
Maybe I did something wrong here? Could it be with the naming and/or  
the number of parameters in the setup?

Anyway, the stuff seems to work. From your answer I guess a sort of  
manual is still far way. Pity.
If you can spare some further hints, if necessary, I will be grateful  
as always.

yours sincerely,
dr. H. van der Meer


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Implementing xspace

2006-02-08 Thread Aditya Mahajan
Hi,

There was some discussion about this in the past (2002)

http://archive.contextgarden.net/message/20020117.124319.5d0f9b9e.en.html

which Hans concluded by saying

quote
it should hook into processsynonym but in such a way that it does 
not break other code because synonyms are used (here) for more purposes 
then you want to know.
/quote

Is there any update on this? I would really like something like xspace to 
be integrated with abbreviations and \cite.

-- 

Aditya
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Animations (with javascript)

2006-02-08 Thread Renaud AUBIN





Hi all,

Considering pdfclock.pdf and euro-anim.pdf, I would try to make a
similar animation, i.e. with a kind of time step but I can't find the
source (euro-anim isn't auto-incremented since it recquire clicks).

Is there someone who know how to do this ?

Cheers,

Renaud





___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Implementing xspace

2006-02-08 Thread Hans Hagen
Aditya Mahajan wrote:
 Hi,

 There was some discussion about this in the past (2002)

 http://archive.contextgarden.net/message/20020117.124319.5d0f9b9e.en.html

 which Hans concluded by saying

 quote
 it should hook into processsynonym but in such a way that it does 
 not break other code because synonyms are used (here) for more purposes 
 then you want to know.
 /quote
   
i've forgotten what thi sis supposed to do (what its' used for)

(that kind of parsing is rather fragile)

Hans

-- 

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

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Movies

2006-02-08 Thread Hans Hagen
Hans van der Meer wrote:
 That's what I had and somehow could not get working again.
   
you mean that you saw no movie?
 I therefore did some experimenting and now I have something working:


 In the above I first thought StartMovie etc would work but  
 StartRendering etc did the trick. As of the special purpose of  
 StartMovie and friends I am still in the dark.
   
\externalfigure[whatever.mov][,label=somelabel]

\goto{start}[StartMovie{somelabel}]

(i didn't test it; this is typically one of the areas where pdf specs 
and viewers evolve over time; what works in version 3 viewers may fail 
in version 5; normally i adapt that kind of stuff when i run into it / 
need it (with the danger of breaking oder stuff); one problem is that 
there is a relationship (now) betwene the page where the resource is and 
where it is activated [it's that kind of dependencies that has shown 
up]; the same for sounds: resources need to be on the same page as where 
they are clled (which over time made some examples fail when viewers 
changed their expectations).

 \definerenderingwindow
 [movie]
 [width=1.33\makeupheight,height= 
 \makeupheight,strut=no,offset=0pt,frame=off,
  background=color,backgroundcolor=BackgroundColor,
  closepageaction=StopCurrentRendering]

 I had to remove the openpageaction from the example in the context  
 fle and then it stopped putting the movie on each and every page once  
 it had been opened.
   
the rendering mechanism is using the pdf 1.5/6 features i.e. separation 
between resource and rendering view (buggy in acrobat 6, but may be 
better by now) ; there is some example code in x-res-50 etc

 Finally typesetting the movie with:

 \useexternalrendering[purple][video/quicktime][purpleshort.mov]
 \defineoverlay
   [theimage]
   [{\externalfigure[themovie][width=\overlaywidth,height= 
 \overlayheight,type=jpg]}]
 starttext
 \hfill\framed[offset=0pt,strut=no,background={foreground,theimage}]
   {\placerenderingwindow[movie][themovie]}\hfill\null

 As you can seen I placed the movie in a framed. This because I wanted  
 the still image showing over it (you mentioned a preview=yes I will  
 later experiment with it. I guess it also will work here?
   
not sure, but overlays are ok (since the undocumented behaviour of 
viewers is that the annots end up on top when activated, they have their 
own rendering layer (and as a side effect cannot be made invisible in 
pdf layers; a typical example of pdf feature creap without forseeing 
implicationswhich then needs to be repaired in later pdf specs/viewers)

 The PROBLEM I encountered was that I thought to change the  
 renderingwindow's background with a local call to
   \setuprenderingwindow[movie][parameters leading to the overlay as in  
 framed]
 but to no avail.
 Maybe I did something wrong here? Could it be with the naming and/or  
 the number of parameters in the setup?
   
dunno, if you send me a zip with all resources and a small test file i 
can have a look
 Anyway, the stuff seems to work. From your answer I guess a sort of  
 manual is still far way. Pity.
   
well, it should go in the widgets manual, but only when the pdf specs is 
stable for this; there is some example code in the x-res files (media 
libraires and so)
 If you can spare some further hints, if necessary, I will be grateful  
 as always.

   
Hans
 ___
 ntg-context mailing list
 ntg-context@ntg.nl
 http://www.ntg.nl/mailman/listinfo/ntg-context
   


-- 

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

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Implementing xspace

2006-02-08 Thread Aditya Mahajan
--- On Feb 9, Hans Hagen wrote ---

 Aditya Mahajan wrote:
 Hi,

 There was some discussion about this in the past (2002)

 http://archive.contextgarden.net/message/20020117.124319.5d0f9b9e.en.html

 which Hans concluded by saying

 quote
 it should hook into processsynonym but in such a way that it does
 not break other code because synonyms are used (here) for more purposes
 then you want to know.
 /quote

 i've forgotten what thi sis supposed to do (what its' used for)


It basically saves the pain of typing \ or {} after all commands. 
Suppose I have
\abbreviation {ABC} {Some abbreviation}

As we know \ABC is an abbreviation.

Notice that there is no \ or {} after \ABC. Normally tex will gobble 
this space. With xspace one can use something like

\def\ABC{Some abbreviation\xspace}

and it will intelligently decide whether to keep a space or not. 
Adding this feature will not effect existing documents.

More details and deinition from xspace.dtx

% |\xspace| should be used at the end of a macro designed to be used
% mainly in text. It adds a space unless the macro is followed by
% certain punctuation characters.

% After |\newcommand{\gb}{Great Britain\xspace}|\\
% \newcommand{\gb}{Great Britain\xspace}
% |\gb is a very nice place to live.|\\
% \gb is a very nice place to live.\\
% |\gb, a small island off the coast of France.|\\
% \gb, a small island off the coast of France.
%
% |\xspace| saves the user from having to type \verb*+\ + or |{}| after
% most occurrences of a macro name in text. However if either of these
% constructions follows |\xspace|, a space is not added by |\xspace|.
% This means that it is safe to add |\xspace| to the end of an existing
% macro without making too many changes in your document.
%
% Sometimes |\xspace| may make the wrong decision, and add a space when
% it is not required. In these cases follow the macro with |{}|, as this
% has the effect of suppressing the space.
%
% Note that this package must be loaded \emph{after} any language (or
% other) packages that make punctuation characters `active'.

[EMAIL PROTECTED]
   [EMAIL PROTECTED]@token\bgroup\else
   [EMAIL PROTECTED]@token\egroup\else
   [EMAIL PROTECTED]@token\/\else
   [EMAIL PROTECTED]@token\ \else
   [EMAIL PROTECTED]@token~\else
   [EMAIL PROTECTED]@token.\else
   [EMAIL PROTECTED]@token!\else
   [EMAIL PROTECTED]@token,\else
   [EMAIL PROTECTED]@token:\else
   [EMAIL PROTECTED]@token;\else
   [EMAIL PROTECTED]@token?\else
   [EMAIL PROTECTED]@token/\else
   [EMAIL PROTECTED]@token'\else
   [EMAIL PROTECTED]@token)\else
   [EMAIL PROTECTED]@token-\else
   [EMAIL PROTECTED]@[EMAIL PROTECTED]
   [EMAIL PROTECTED]@token\space\else
   [EMAIL PROTECTED]@[EMAIL PROTECTED]
\space
  \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi}


-- 
Aditya Mahajan, EECS Systems, University of Michigan
http://www.eecs.umich.edu/~adityam || Ph: 7342624008
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context