Home > Archive > Tex > October 2006 > Proposal: add a --(no)embed flag to epstopdf
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Proposal: add a --(no)embed flag to epstopdf
|
|
|
| Hi,
I am writing this here because I do not know how to reach the
maintainer of "epstopdf" perl script...
Recently it is necessary to produce PDFs with all fonts embedded and
subset. I have applied that simple patch to the epstopdf in my distro
(ubuntu 6.06 up-to-date, TeX system is a TeTeX-3) to add a flag to
produce normally a PDF with all fonts embedded and subsetted, and
(optionally) following the default that gs has. I would like to submit
it for inclusion in official packages...
HTH,
Romano
PS: patch is whitespace damaged from here, it's posted just to permit
inspection... download from:
http://www.dea.icai.upcomillas.es/r...topdf.patch.txt
--- /usr/bin/epstopdf 2006-05-29 16:39:40.000000000 +0200
+++ /home/romano/bin/myepstopdf 2006-10-26 12:00:19.000000000 +0200
@@ -62,8 +62,8 @@
### program identification
my $program = "epstopdf";
my $filedate="2001/03/05";
-my $fileversion="2.7";
-my $copyright = "Copyright 1998-2001 by Sebastian Rahtz et al.";
+my $fileversion="2.7 hacked by RGtti";
+my $copyright = "Copyright 1998-2001 by Sebastian Rahtz et al., hackeb
by RGtti 2006";
my $title = "\U$program\E $fileversion, $filedate - $copyright\n";
### ghostscript command name
@@ -89,6 +89,7 @@
$::opt_hires=0;
$::opt_exact=0;
$::opt_filter=0;
+$::opt_embed=1;
$::opt_outfile="";
### usage
@@ -101,6 +102,7 @@
--(no)filter: read standard input (default:
$bool[$::opt_filter])
--(no)gs: run ghostscript (default: $bool[$::opt_gs])
--(no)compress: use compression (default:
$bool[$::opt_compress])
+ --(no)embed: embed all fonts (default:
$bool[$::opt_embed])
--(no)hires: scan HiResBoundingBox (default:
$bool[$::opt_hires])
--(no)exact: scan ExactBoundingBox (default:
$bool[$::opt_exact])
--(no)debug: debug informations (default:
$bool[$::opt_debug])
@@ -122,6 +124,7 @@
"gs!",
"hires!",
"exact!",
+ "embed!",
"outfile=s",
) or die $usage;
@@ -162,6 +165,10 @@
my $GSOPTS = "";
$GSOPTS = "-dUseFlateCompression=false " unless $::opt_compress;
+### option embed
+$GSOPTS = $GSOPTS . "-dCompatibilityLevel=1.3 -dPDFSETTING=/printer
-dMaxSubsetPct=100 -dSubsetFonts=true -dEmbedAllFonts=true " if
$::opt_embed;
+
+
### option BoundingBox types
my $BBName = "%%BoundingBox:";
!($::opt_hires and $::opt_exact) or
@@ -195,6 +202,7 @@
if ($::opt_gs) {
debug "Ghostscript command:", $GS;
debug "Compression:", ($::opt_compress) ? "on" : "off";
+ debug "Ghostscript options:", $GSOPTS;
}
| |
| Heiko Oberdiek 2006-10-30, 7:43 pm |
| "rmano" <romano.giannetti@gmail.com> wrote:
> Recently it is necessary to produce PDFs with all fonts embedded and
> subset. I have applied that simple patch to the epstopdf in my distro
Ghostscript interprets the environment variable GS_OPTIONS,
see Use.htm. Example (bash/linux):
GS_OPTIONS='-dEmbedAllFonts=true ...' epstopdf test.ps test.pdf
Otherwise you would have to add lots of new options.
(See the documentation of ghostscript.)
Yours sincerely
Heiko <oberdiek@uni-freiburg.de>
| |
|
|
Heiko Oberdiek wrote:
> "rmano" <romano.giannetti@gmail.com> wrote:
>
>
> Ghostscript interprets the environment variable GS_OPTIONS,
> see Use.htm. Example (bash/linux):
> GS_OPTIONS='-dEmbedAllFonts=true ...' epstopdf test.ps test.pdf
>
Oops. Obviously. Darn :-).
Pity for my first try at serial-line-noise programming (hey, perl it's
not as bad as they say...).
Thanks,
Romano
|
|
|
|
|