[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#63797: dvips produces bad postcript



"AK"  == Atsuhito Kohda <kohda@pm.tokushima-u.ac.jp> writes:
"BAM" == Brian A. May <bam@snoopy.apana.org.au>

I've looked into this bug and I think I agree with Atsuhito --
it's not a bug, it's a question of proper usage.

The manual for seminar.sty, sem-user.tex (available as
/usr/share/doc/texmf/latex/seminar/sem-user.dvi.gz on Debian
systems), clearly states that the \overlay{n} command ``puts
whatever is in its scope (TeX group) on overlay n''.  That's
exactly the same as saying ``grouping is needed''.

As Atsuhito has pointed out, the \overlay command is similar to
commands such as \bfseries (what George Gratzer calls ``command
declarations'') -- these commands affect everything following
their appearance until their scope is closed.  That means that you
*must* create a scope for the command using either braces or
environment declarations (``special braces'').

When Atsuhito was quoting from the manual, he missed the footnote
that states that ``You can also write \begin{overlay}{n}
... \end{overlay}'', which clarifies the need for scoping and
confirms Brian's note 1 in his message from 19 May 2000 22:08:15
+1000 (<[🔎] 84ya56n3o0.fsf@snoopy.apana.org.au>).

The Seminar-FAQ, specifically the section titled ``How to generate
overlays''
(<file:///usr/share/doc/texmf/latex/seminar/Seminar-FAQ.html#SECTION000130000000000000000>)
gives an example of defining overlays using the overlay
environment:

   \begin{slide}
     \centerline{\psshadowbox{\shortstack[l]{%
       The winner is: \begin{overlay}{1}{\textcolor{red}{Caroline}}
         \end{overlay}\\[2cm] 
       The second is: \begin{overlay}{2}{Jane}\end{overlay}\\[2cm]
       The third  is: \begin{overlay}{3}{Mary}\end{overlay}}}}
   \end{slide}

The same set of slides can be generated using the \overlay command
if you provide braces to define scope:

   \begin{slide}
     \centerline{\psshadowbox{\shortstack[l]{%
       The winner is: {\overlay{1}{\textcolor{red}{Caroline}}}\\[2cm]
       The second is: {\overlay{2}{Jane}}\\[2cm]
       The third  is: {\overlay{3}{Mary}}}}}
   \end{slide}

You can get away without the braces so long as the scope of the
commands is clearly defined.  For example,

   \begin{slide}
     \overlay{0} What is Crashing?
     \begin{itemize}
       \overlay{1}\item Crashing is a bad thing.
       \overlay{2}\item Why is crashing important?
       \overlay{3}\item Working around crashes.
     \end{itemize}
   \end{slide}

produces four slides: a master slide with the title ``What is
Crashing?'' and three overlay slides, each containing a single
item.  

If you insert an additional \item command after the last \overlay
command, the last slide will have two items.  (If you insert text
between the \end{itemize} and \end{slide} commands, it will be
discarded because that text is outside the scope of the last
\overlay command (which was closed by \end{itemize}).)

I hope this message helps clarify the discussion.

   CMC

+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
 Behind the counter a boy with a shaven head stared vacantly into space, 
 a dozen spikes of microsoft protruding from the socket behind his ear.
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
   C.M. Connelly               c@eskimo.com                   SHC, DS
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ 



Reply to: