[R] \preformatted and $

Prof Brian Ripley ripley at stats.ox.ac.uk
Tue Nov 18 14:57:30 CET 2003


On 18 Nov 2003, Arend P. van der Veen wrote:

> I found my problem with the second item ('$').  As far as the first
> problem with \preformatted, I check the tex code that was generated and
> found that 
> 
> \end{verbatim}\end{Details}
> 
> However, if I add some text between the preformatted text and the end of
> the detail section it works.  I will use that as a work around.
> 
> \details{
> some text
> \preformatted{
> [my-section]
> user = apv
> host = 127.0.0.1
> }
> some more text
> }
> 
> If anybody knows if this bug is corrected in the patch please let me
> know.

Not yet, as this is not actually the bug: look what happens when there is 
text at the end of the \details section.

> 
> Thanks,
> Arend  
> 
> On Tue, 2003-11-18 at 04:40, Uwe Ligges wrote:
> > On 17 Nov 2003, Arend P. van der Veen wrote:
> > 
> > > Hi,
> > > 
> > > I have been developing a package in R and have been working on
> > > documentation.  I have a \details function that contains the following:
> > > 
> > > \details{
> > > 
> > > some text
> > > 
> > > \preformatted{
> > > [my-section]
> > > user = apv
> > > host = 127.0.0.1
> > > }
> > > 
> > > }
> > > 
> > >  When I run R CMD check I get an error while checking the manual.  If I
> > > remove:
> > > 
> > > \preformatted{
> > > [my-section]
> > > user = apv
> > > host = 127.0.0.1
> > > }
> > > 
> > > and replace it with 
> > > 
> > > [my-section]
> > > user = apv
> > > host = 127.0.0.1
> > > 
> > > the error goes away.
> > > 
> > > Has anybody had this problem?  
> > 
> > Confirmed. The problem is that there is no newline after
> > \end{verbatim}
> > in the produced TeX code, so we get, e.g.:
> > \end{verbatim}\end{Details}
> > .
> > 
> > Might be fixed in R-patched (I don't have access right now).
> > 
> > 
> > > 
> > > I have also have a problem including a '$' in my documentation.  I
> > > replace them with \$ which made latex happy but then \$ showed up in the
> > > HTML and R help.
> > 
> > Hmmm. All of the following works for me:
> > 
> > \$, \code{$}, and \deqn{\$}{$}
> > 
> > 
> > Uwe Ligges
> > 
> > 
> > 
> > > Any advice would be appreciated,
> > > Arend van der Veen
> > > 
> > > ______________________________________________
> > > R-help at stat.math.ethz.ch mailing list
> > > https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> > > 
> >
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> 
> 

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list