[R] pdf/ convert/ font problem
Paul Murrell
p.murrell at auckland.ac.nz
Tue Oct 24 00:38:00 CEST 2006
Hi
Sam McClatchie wrote:
> Background:
> OS: Linux Ubuntu Dapper
> R : Version 2.3.1 (2006-06-01)
> Emacs 21.4.1
> ESS
>
>
> Colleagues
>
> This is neither a bug report, nor a complaint, so I think this is the
> appropriate list.
>
> I am getting an odd font problem with a pdf generated using
> pdf(file =
> "../figures/PCNM.models.larvae.fluor.zoo.stability.2001.and.2002.pdf",
> title="", family="serif", pointsize=10, width=6.75, height=8.625)
>
> The figure produced from my code is here:
> <http://www.members.iinet.net.au/~s.mcclatchie/aslo/PCNM.models.larvae.fluor.zoo.stability.2001.and.2002.pdf>
> (I can't really send all of the code as there are several subroutines
> for the analysis that are not relevant here anyway).
>
> ------------------------------------------------
> The pdf loads into acroread or xpdf fine, so is not corrupted, but
> ghostscript gives an error:
Acroread (Windows) works for me, xpdf (Linux CentOS) thrashes my machine
for ever (or until I gave up), and ghostscript gives me ...
/undefinedresult in --currentpoint--
... but I can't see anything obvious in the raw PDF.
> ERROR: /invalidfont in --.type1execchar--ESP Ghostscript 815.02:
> Unrecoverable error, exit code 1
>
> Operand stack:
> --dict:4/4(L)-- --dict:16/17(ro)(G)-- 108 a71 -string-
> Execution stack:
> %interp_exit .runexec2 --nostringval-- --nostringval--
> --nostringval-- 2 %stopped_push --nostringval--
> --nostringval-- --nostringval-- false 1 %stopped_push 1 3
> %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop 1 3
> %oparray_pop .runexec2 --nostringval-- --nostringval--
> --nostringval-- 2 %stopped_push --nostringval--
> --nostringval-- --nostringval-- --nostringval-- --nostringval--
> %array_continue --nostringval-- false 1 %stopped_push
> --nostringval-- %loop_continue --nostringval-- --nostringval--
> %finish_show --nostringval-- --nostringval-- 7 9 1
> --nostringval-- (gs_show_enum) %op_show_continue
> Dictionary stack:
> --dict:1124/1686(ro)(G)-- --dict:0/20(G)-- --dict:85/200(L)--
> --dict:104/127(ro)(G)-- --dict:241/347(ro)(G)-- --dict:20/24(L)--
> --dict:4/6(L)-- --dict:20/20(L)-- --dict:12/13(L)--
> Current allocation mode is local
> ----------------------------------
> Also Imagemagick cannot display or convert the file to .png:
I think that's the same problem: ImageMagick is just calling ghostscript.
Sorry, no solution to suggest yet.
Paul
> smc at nakrasana:~/dynamic_data/projects2005/sardine_egg_distribution/journal$
> convert PCNM.models.larvae.fluor.zoo.stability.2001.and.2002.pdf
> PCNM.models.larvae.fluor.zoo.stability.2001.and.2002.png
> ERROR: /invalidfont in --.type1execchar--
> Operand stack:
> --dict:4/4(L)-- --dict:15/16(ro)(G)-- 108 a71 -string-
> Execution stack:
> %interp_exit .runexec2 --nostringval-- --nostringval--
> --nostringval-- 2 %stopped_push --nostringval--
> --nostringval-- --nostringval-- false 1 %stopped_push 1 3
> %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop
> --nostringval-- --nostringval-- 2 1 1 --nostringval--
> %for_pos_int_continue --nostringval-- --nostringval--
> --nostringval-- --nostringval-- %array_continue --nostringval--
> false 1 %stopped_push --nostringval-- %loop_continue
> --nostringval-- --nostringval-- %finish_show --nostringval--
> --nostringval-- 9 10 1 --nostringval-- (gs_show_enum)
> %op_show_continue
> Dictionary stack:
> --dict:1125/1686(ro)(G)-- --dict:0/20(G)-- --dict:85/200(L)--
> --dict:85/200(L)-- --dict:104/127(ro)(G)-- --dict:241/347(ro)(G)--
> --dict:20/24(L)-- --dict:4/6(L)-- --dict:20/20(L)-- --dict:12/13(L)--
> Current allocation mode is local
> ESP Ghostscript 815.02: Unrecoverable error, exit code 1
> convert: Postscript delegate failed
> `PCNM.models.larvae.fluor.zoo.stability.2001.and.2002.pdf'.
>
> --------------------------------
> I have all of the true type fonts installed.
>
> Probably the solution is just to use png() rather than pdf(), but I
> thought this problem was curious enough to report.
>
> Best fishes
>
> Sam
>
--
Dr Paul Murrell
Department of Statistics
The University of Auckland
Private Bag 92019
Auckland
New Zealand
64 9 3737599 x85392
paul at stat.auckland.ac.nz
http://www.stat.auckland.ac.nz/~paul/
More information about the R-help
mailing list