summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/support/pkfix-helper/README2
-rw-r--r--Master/texmf-dist/doc/support/pkfix-helper/encoding-samples.pdfbin565207 -> 564699 bytes
-rwxr-xr-xMaster/texmf-dist/scripts/pkfix-helper/pkfix-helper42
-rw-r--r--Master/texmf/doc/man/man1/pkfix-helper.125
-rw-r--r--Master/texmf/doc/man/man1/pkfix-helper.man1.pdfbin21536 -> 22136 bytes
5 files changed, 51 insertions, 18 deletions
diff --git a/Master/texmf-dist/doc/support/pkfix-helper/README b/Master/texmf-dist/doc/support/pkfix-helper/README
index f0a1c1ba738..76a3b58ae71 100644
--- a/Master/texmf-dist/doc/support/pkfix-helper/README
+++ b/Master/texmf-dist/doc/support/pkfix-helper/README
@@ -52,7 +52,7 @@ Sorry. Maybe try Cygwin (http://www.cygwin.com/)?
Copyright and license
=====================
-Copyright (C) 2009, Scott Pakin
+Copyright (C) 2010, Scott Pakin
This file may be distributed and/or modified under the conditions of
the LaTeX Project Public License, either version 1.3c of this license
diff --git a/Master/texmf-dist/doc/support/pkfix-helper/encoding-samples.pdf b/Master/texmf-dist/doc/support/pkfix-helper/encoding-samples.pdf
index c309d2ae310..088c4edc64f 100644
--- a/Master/texmf-dist/doc/support/pkfix-helper/encoding-samples.pdf
+++ b/Master/texmf-dist/doc/support/pkfix-helper/encoding-samples.pdf
Binary files differ
diff --git a/Master/texmf-dist/scripts/pkfix-helper/pkfix-helper b/Master/texmf-dist/scripts/pkfix-helper/pkfix-helper
index 11c4ae7c103..26d56ede05a 100755
--- a/Master/texmf-dist/scripts/pkfix-helper/pkfix-helper
+++ b/Master/texmf-dist/scripts/pkfix-helper/pkfix-helper
@@ -17,8 +17,8 @@ use strict;
# Define some global variables.
my $progname = basename $0; # Name of this program
-our $VERSION = "1.2"; # Version number of this program
-my %name2chars; # Map from a font name to a character list
+our $VERSION = "1.3"; # Version number of this program
+my %name2chars; # Map from a font name to a character list
my $GS = $ENV{"GS"} || "gs"; # Name of the Ghostscript interpreter
my $TFTOPL = $ENV{"TFTOPL"} || "tftopl"; # Name of the TFM to PL converter
my $dpi = 300; # Number of dots per inch used to generate bitmapped characters
@@ -40,6 +40,7 @@ my $verbose = 1; # 0=quiet; 1=verbose output; 2=more verbose o
my @forced_fonts; # Font mappings the user asserts are correct
my @exclude_res; # Regexps for fonts to exclude
my @extra_tfms; # Extra TFM files to use
+my %retained_t3s; # Type 3 fonts to retain as is
my $sample_file_ps; # Name of a PostScript file of font samples to write
my $sample_file_tex; # Name of a TeX file of font samples to write
my $single_font_use = 0; # 1=one use per font; 0=allow repetitions
@@ -73,7 +74,7 @@ sub read_tfm_cache_file
my %widths = @fields;
$tfmfontwidth{$tfm} = \%widths;
}
- $numlines++;
+ $numlines++;
}
close CACHEFILE;
print STDERR "done ($numlines entries).\n" if $verbose;
@@ -182,6 +183,7 @@ sub optimal_scale ($$)
$doc_dot_tfm += $docwidth * $tfmwidth;
$tfm_dot_tfm += $tfmwidth**2;
}
+ return 1.0 if $tfm_dot_tfm == 0.0; # TFM characters all have zero width.
return $doc_dot_tfm / $tfm_dot_tfm;
}
@@ -209,6 +211,7 @@ sub compare_maps ($$;$)
sub write_comments ($$)
{
my ($fontname, $fontdef) = @_;
+ return $fontdef if !defined $fontmatch{$fontname}; # Font should not be substituted
my $tfm = $fontmatch{$fontname}->{"tfm"};
my $scale = $fontmatch{$fontname}->{"scale"};
my $origsize = $tfm2size{$tfm};
@@ -316,10 +319,11 @@ Getopt::Long::Configure ("bundling");
GetOptions ("h|help" => \$wanthelp,
"v|verbose+" => \$verbose,
"V|version" => \$wantversion,
- "q|quiet" => sub {$verbose=0},
+ "q|quiet" => sub {$verbose = 0},
"f|force=s" => \@forced_fonts,
"i|include=s" => \@extra_tfms,
"x|exclude=s" => \@exclude_res,
+ "k|keep=s" => sub {$retained_t3s{$_[1]} = 1},
"t|tex=s" => \$sample_file_tex,
"p|ps=s" => \$sample_file_ps,
"s|spp=i" => \$samples_per_page,
@@ -618,6 +622,12 @@ foreach my $fontname (@sortedfontnames) {
my @besttfms; # Best matching TFM file(s), sizes, and scales
my $bestmatch = 10**9; # Best matching value
+ # Don't substitute the font if we were told not to.
+ if (defined $retained_t3s{$fontname}) {
+ print STDERR " Retaining $fontname as a bitmapped font.\n" if $verbose == 1;
+ next;
+ }
+
# Determine the list of eligible fonts to compare against.
my @eligible_tfms;
foreach my $tfminfo ($fontmatch{$fontname} || @tfmlist) {
@@ -945,6 +955,7 @@ pkfix-helper
[B<--cache>=I<filename>]
[B<--include>=I<fontspec>]
[B<--exclude>=I<regexp>]
+[B<--keep>=I<fontspec>]
[B<--quiet>]
[B<--no-repeats>]
[B<--spp>=I<number>]
@@ -1099,6 +1110,17 @@ Remove all font specifications matching regular expression I<regexp>
from B<pkfix-helper>'s list of known fonts. The B<--exclude> option
can be specified repeatedly on the command line.
+=item B<-k> I<fontspec>, B<--keep>=I<fontspec>
+
+Do not substitute a vector font for bitmapped font I<fontspec> (C<Fa>,
+C<Fb>, etc.). This is useful when converting documents that use
+obscure bitmapped fonts for which there is no vector equivalent. For
+example, it was somewhat common in the past to include graphics such
+as university or corporate logos into a document by converting the
+bitmapped image into a single-character font and using that font in
+LaTeX. B<--keep> prevents such fonts from being replaced. The
+B<--keep> option can be specified repeatedly on the command line.
+
=item B<-q>, B<--quiet>
Instruct B<pkfix-helper> to produce no output during its run except
@@ -1154,7 +1176,7 @@ In its simplest form, B<pkfix-helper> takes the name of an input file
file but serve as suitable input for B<pkfix>:
$ pkfix-helper oldfile.ps pkfix-oldfile.ps
- Reading netpipe.ps ... done.
+ Reading oldfile.ps ... done.
Number of Type 3 fonts encountered: 10
Bitmapped fonts are typeset at 600 DPI.
Finding character widths ... done.
@@ -1226,7 +1248,7 @@ program to automatically detect an optimal scaling factor, even if
doing so means choosing a highly nonstandard font size:
$ pkfix-helper oldfile.ps pkfix-oldfile.ps --force="Ff=cmb12 @ *"
- Reading netpipe.ps ... done.
+ Reading oldfile.ps ... done.
Number of Type 3 fonts encountered: 10
Bitmapped fonts are typeset at 600 DPI.
Finding character widths ... done.
@@ -1237,7 +1259,7 @@ Oops, it looks like we don't have a F<cmb12.tfm> file on our system.
Let's try scaling up F<cmb10.tfm> instead:
$ pkfix-helper oldfile.ps pkfix-oldfile.ps --force="Ff=cmb10 @ *"
- Reading netpipe.ps ... done.
+ Reading oldfile.ps ... done.
Number of Type 3 fonts encountered: 10
Bitmapped fonts are typeset at 600 DPI.
Finding character widths ... done.
@@ -1310,8 +1332,8 @@ generally needed to guide B<pkfix-helper>'s font-matching procedures.
=head1 NOTES
Files produced using the B<--tex> option are Plain TeX files and
-therefore must be compiled with F<tex> (or a variation such F<etex>,
-F<pdftex>, F<pdfetex>, etc.), I<not> with F<latex>.
+therefore must be compiled with F<tex> (or a variation such as
+F<pdftex>, F<luatex>, etc.), I<not> with F<latex>.
=head1 SEE ALSO
@@ -1330,7 +1352,7 @@ Scott Pakin, I<scott+pkfh@pakin.org>
=head1 COPYRIGHT AND LICENSE
-Copyright (C) 2009, Scott Pakin
+Copyright (C) 2010, Scott Pakin
This file may be distributed and/or modified under the conditions of
the LaTeX Project Public License, either version 1.3c of this license
diff --git a/Master/texmf/doc/man/man1/pkfix-helper.1 b/Master/texmf/doc/man/man1/pkfix-helper.1
index cd7f205f472..d88b9695aae 100644
--- a/Master/texmf/doc/man/man1/pkfix-helper.1
+++ b/Master/texmf/doc/man/man1/pkfix-helper.1
@@ -124,7 +124,7 @@
.\" ========================================================================
.\"
.IX Title "PKFIX-HELPER 1"
-.TH PKFIX-HELPER 1 "2009-08-03" "v1.2" " "
+.TH PKFIX-HELPER 1 "2010-10-15" "v1.3" " "
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
@@ -142,6 +142,7 @@ pkfix-helper
[\fB\-\-cache\fR=\fIfilename\fR]
[\fB\-\-include\fR=\fIfontspec\fR]
[\fB\-\-exclude\fR=\fIregexp\fR]
+[\fB\-\-keep\fR=\fIfontspec\fR]
[\fB\-\-quiet\fR]
[\fB\-\-no\-repeats\fR]
[\fB\-\-spp\fR=\fInumber\fR]
@@ -275,6 +276,16 @@ repeatedly on the command line.
Remove all font specifications matching regular expression \fIregexp\fR
from \fBpkfix-helper\fR's list of known fonts. The \fB\-\-exclude\fR option
can be specified repeatedly on the command line.
+.IP "\fB\-k\fR \fIfontspec\fR, \fB\-\-keep\fR=\fIfontspec\fR" 4
+.IX Item "-k fontspec, --keep=fontspec"
+Do not substitute a vector font for bitmapped font \fIfontspec\fR (\f(CW\*(C`Fa\*(C'\fR,
+\&\f(CW\*(C`Fb\*(C'\fR, etc.). This is useful when converting documents that use
+obscure bitmapped fonts for which there is no vector equivalent. For
+example, it was somewhat common in the past to include graphics such
+as university or corporate logos into a document by converting the
+bitmapped image into a single-character font and using that font in
+LaTeX. \fB\-\-keep\fR prevents such fonts from being replaced. The
+\&\fB\-\-keep\fR option can be specified repeatedly on the command line.
.IP "\fB\-q\fR, \fB\-\-quiet\fR" 4
.IX Item "-q, --quiet"
Instruct \fBpkfix-helper\fR to produce no output during its run except
@@ -322,7 +333,7 @@ file but serve as suitable input for \fBpkfix\fR:
.PP
.Vb 10
\& $ pkfix\-helper oldfile.ps pkfix\-oldfile.ps
-\& Reading netpipe.ps ... done.
+\& Reading oldfile.ps ... done.
\& Number of Type 3 fonts encountered: 10
\& Bitmapped fonts are typeset at 600 DPI.
\& Finding character widths ... done.
@@ -398,7 +409,7 @@ doing so means choosing a highly nonstandard font size:
.PP
.Vb 7
\& $ pkfix\-helper oldfile.ps pkfix\-oldfile.ps \-\-force="Ff=cmb12 @ *"
-\& Reading netpipe.ps ... done.
+\& Reading oldfile.ps ... done.
\& Number of Type 3 fonts encountered: 10
\& Bitmapped fonts are typeset at 600 DPI.
\& Finding character widths ... done.
@@ -411,7 +422,7 @@ Let's try scaling up \fIcmb10.tfm\fR instead:
.PP
.Vb 10
\& $ pkfix\-helper oldfile.ps pkfix\-oldfile.ps \-\-force="Ff=cmb10 @ *"
-\& Reading netpipe.ps ... done.
+\& Reading oldfile.ps ... done.
\& Number of Type 3 fonts encountered: 10
\& Bitmapped fonts are typeset at 600 DPI.
\& Finding character widths ... done.
@@ -471,8 +482,8 @@ generally needed to guide \fBpkfix-helper\fR's font-matching procedures.
.SH "NOTES"
.IX Header "NOTES"
Files produced using the \fB\-\-tex\fR option are Plain TeX files and
-therefore must be compiled with \fItex\fR (or a variation such \fIetex\fR,
-\&\fIpdftex\fR, \fIpdfetex\fR, etc.), \fInot\fR with \fIlatex\fR.
+therefore must be compiled with \fItex\fR (or a variation such as
+\&\fIpdftex\fR, \fIluatex\fR, etc.), \fInot\fR with \fIlatex\fR.
.SH "SEE ALSO"
.IX Header "SEE ALSO"
\&\fIpkfix\fR\|(1), \fIdvips\fR\|(1), \fItex\fR\|(1), \fIgs\fR\|(1)
@@ -485,7 +496,7 @@ Published by Addison-Wesley, \s-1ISBN\s0 0\-201\-37922\-8,
Scott Pakin, \fIscott+pkfh@pakin.org\fR
.SH "COPYRIGHT AND LICENSE"
.IX Header "COPYRIGHT AND LICENSE"
-Copyright (C) 2009, Scott Pakin
+Copyright (C) 2010, Scott Pakin
.PP
This file may be distributed and/or modified under the conditions of
the LaTeX Project Public License, either version 1.3c of this license
diff --git a/Master/texmf/doc/man/man1/pkfix-helper.man1.pdf b/Master/texmf/doc/man/man1/pkfix-helper.man1.pdf
index 4c1f54c3d45..5191b877398 100644
--- a/Master/texmf/doc/man/man1/pkfix-helper.man1.pdf
+++ b/Master/texmf/doc/man/man1/pkfix-helper.man1.pdf
Binary files differ