On 04-Sep-09 14:01:44, Simone Gabbriellini wrote: > Dear list, > I am trying to make eps file with embedded font. > I use: > > postscript("ranking-exp-all.eps", horizontal=TRUE, onefile=FALSE, > paper="special", height=8, width=12, family="Helvetica") ># plot stuff > dev.off() > > since R does not embed font, I then use: > > embedFonts(file="indegdistr.eps", outfile="indegdistrEMB.eps", > fontpaths="System/Library/Fonts") > > the problem is that the second file, with font embedded, is cutted > near the end, and the very last part of the plots and the border are > off the page... > > I use R 2.8.1 on a Mac OSX > any help more than welcome, > regards, > Simone
What may well have happened is that the BoundingBox computed for the second file is not right for the extent graphic for some reason connected with using the embedded fonr. Make a "test" copy of the second eps file, and then see what happens if you edit it as follows: **using a plain-text editing program, not a word-processor**!! Somewhere in the eps file (either near the beginning or at the end) you will find a line which looks like %%BoundingBox: 66 442 536 767 (taken from one of my own). These are the (x,y) coordinates, in units od points, of the lower left and upper right hand corners of the graphics **as planted by the program that made the EPS**. Since in most PostScript display applications, the BoundingBox is a "clipping path", normally you will not see anything that lies outside the BoundingBox (even though it is present in the file as PostScript commands). The general format of the above line is %%BoundingBox: llx lly urx ury so the lower left corner is at (llx,lly) and the upper right corner is at (urx,ury). So, if you graphic appears clipped at the bottom. try lowering the bottom edge. This means using the editor to reduce the value in llx (at least -- maybe other adjustments may be needed). So, for example, with the above %%BoundingBox: line, you might try dropping it by 0.25 inches (18 points): %%BoundingBox: 48 442 536 767 since 48 = 66-18. If that works, then your problem has been idenitified, and then someone wioll be able to give you specific help. Best wioshes, Ted. -------------------------------------------------------------------- E-Mail: (Ted Harding) <ted.hard...@manchester.ac.uk> Fax-to-email: +44 (0)870 094 0861 Date: 04-Sep-09 Time: 15:33:10 ------------------------------ XFMail ------------------------------ ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.