On 11/02/2020 12:33 p.m., neonira Arinoem wrote:
Hi R gurus

Got an issue risen by CRAN about using unknown characters from Latex.

Here is the error message, in the context of PDF generated form manual pages







*Check: PDF version of manual, Result: WARNING   LaTeX errors when creating
PDF version.   This typically indicates Rd problems.   LaTeX errors found:
   ! Undefined control sequence.   <recently read> \blacktriangleright * >



*   l.237 STRATUM $\blacktriangleright
$ LAYER\_3   ! Undefined control sequence.   <recently read>
\blacktriangleright *




*   l.239 PHASING $\blacktriangleright
$ RUN   ! Undefined control sequence.   <recently read> \blacktriangleright
*

*   l.241 INTENT  $\blacktriangleright
$ FEEDBACK*

I understand that the \blacktriangleright is an unknown control sequence
from latex ... and that sounds strange to me, as I uses it often in
vignettes without any issue so far.
I did some tests on my machine with  R CMD Rd2pdf --force --output=x.pdf
man/*.Rd and it reproduces the issue.

In the incriminated manual page, the code generating this sequence is the
following
*\ifelse{latex}{\out{$\blacktriangleright$}}{\ifelse{html}{\out{&#x25B6;}}{\u25b6}}*

Apparently I need to add the \usepackage{amssymb} to the manual page. Do
not know yet, how to achieve this.

As far as I know there's no way for you to do that. The fact you can do it in vignettes isn't relevant: Rd files are in Rd format, which is not LaTeX. Some LaTeX works when you put it in the \ifelse{latex} macro, but there's no guarantee that it all will.

There's one exception to this warning: if you are building a package for yourself, not for CRAN, you can put \usepackage{amssymb} into your Rd.cfg file (somewhere on the LaTeX search path). See the R Installation and Administration manual for details. I don't think there's anywhere in your package you could include such a file.

Duncan Murdoch

Yours ideas and hints welcome and this point or  any other solution to this
tricky issue.

I know that I can still change *\backtriangleright* with any available
control sequence and it will work. Indeed, not the way I prefer.
Really wish to get my *\blacktriangleright* display.

Best.
Neonira

        [[alternative HTML version deleted]]

______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel

Reply via email to