Re: Strange color problem with darkbackground

2001-11-10 Thread Stephan Lehmke

Martin Reed wrote on Fri, 9 Nov 2001 19:48:49 +:
>
> to stop the following error 
> ! Misplaced \noalign.
> \hline ->\noalign
>   {\ifnum 0=`}\fi \hrule \@height \arrayrulewidth 
> \futurelet...
> l.13 \hline
> 
[...]
> \begin{tabular}{|p{0.3\textwidth}|p{0.65\textwidth}|}
> \hline
> 1 & 2 \\
> \hline
> 3 & 4 \\
> \hline
> \end{tabular}

Argh, this is a well-known problem, I just didn't make the 
connection...

The line 

> \g@addto@macro\@arrayparboxrestore\raggedright

you deleted was meant to make all parboxes and minipages 
act `raggedright', because I felt the behaviour of seminar
to set everything in raggedright but switch back to justified
in parboxes inconsistent.

I accepted it as a welcome bonus that this extended to p
columns of tabulars, but forgot that \raggedright redefines
\\ so that \\ will end a line _in the p column_ instead of
ending a table row. This also happens when \raggedright
is added to an individual column by >{\raggedright}
(with the array package) and can be circumvented by ending
tabular rows with \tabularnewline.

I have modified the development version of powersem
to use seminar's raggedright mechanism (controlled by
\raggedslides) instead of \raggedright, which not only 
is more canonical, but also avoids this error message.

Please try again with 

http://lrb.cs.uni-dortmund.de/~lehmke/texpower/preview/powersem.cls

if you like.

regards
Stephan

-- 
  Stephan Lehmke [EMAIL PROTECTED]
  Fachbereich Informatik, LS I   Tel. +49 231 755 6434 
  Universitaet Dortmund  FAX  6555
  D-44221 Dortmund, Germany 




Strange color problem with darkbackground

2001-11-07 Thread Martin Reed

Stephan,

As before I am impressed for an alpha release, thanks for your help this 
solved my problem. Just in case you are interested I had to apply the 
following patch:
texpower> rcsdiff -u powersem.cls
===
RCS file: RCS/powersem.cls,v
retrieving revision 1.2
diff -u -r1.2 powersem.cls
--- powersem.cls2001/11/09 19:42:42 1.2
+++ powersem.cls2001/11/09 20:29:26
@@ -138,8 +138,6 @@
 \expandafter\def\expandafter\set@slidesize\expandafter
 {\set@slidesize\@colht\vsize}

-\g@addto@macro\@arrayparboxrestore\raggedright
-
 \ifthenelse{\boolean{truepn@PS}}{\truepagenumbers}{}

 %
-
 
to your new powersem.cls (v6.0)
to stop the following error 
! Misplaced \noalign.
\hline ->\noalign
  {\ifnum 0=`}\fi \hrule \@height \arrayrulewidth 
\futurelet...
l.13 \hline

on the example file:

\documentclass{powersem}
\usepackage{texpower}
\usepackage{hyperref}
\usepackage{fixseminar}
\usepackage{soul}

\begin{document}
\begin{slide}
\section{section}
\begin{tabular}{|p{0.3\textwidth}|p{0.65\textwidth}|}
\hline
1 & 2 \\
\hline
3 & 4 \\
\hline
\end{tabular}
\normalsize
\end{slide}
\end{document}

One day I will get around to learning latex/tex in more depth so that I could 
tell you why it caused the problem but for now
\g@addto@macro\@arrayparboxrestore\raggedright
might as well be in Greek for me!

Regards,

Martin Reed.

On Thursday 08 Nov 2001 11:20 am, Stephan Lehmke wrote:
> Martin Reed wrote on Wed, 7 Nov 2001 22:33:50 +:
> > I have a problem with texpower setting the color to black for all text
> > after the first page when using darkbackground (also light and
> > blackbackground). An example file is at the end.
>
> This is a special problem of seminar in connection
> with pdftex. seminar is a 2.09 dinosaur and doesn't
> have color-aware handling of headers and footers in
> its output routine.
>
> The current development version of powersem, to be
> found at
>
> http://lrb.cs.uni-dortmund.de/~lehmke/texpower/preview/powersem.cls
>
> has a modified output routine, eliminating this
> problem.
>
> If you don't feel safe with that one, loading the pdfcolmk
> package by Heiko Oberdiek provides a partial solution
> even with the `old' powersem.
>
> regards
> Stephan