summaryrefslogtreecommitdiff
path: root/fonts/utilities
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-11-19 03:02:21 +0000
committerNorbert Preining <norbert@preining.info>2019-11-19 03:02:21 +0000
commit025f7bfee79d7817a876831bb19f34a2dfb1b2e2 (patch)
tree76efc8c89514583aae7ddb55b59bfb879500a09d /fonts/utilities
parent96f9362fc3e3bb70fa2411c62418c42d9acda4d7 (diff)
CTAN sync 201911190302
Diffstat (limited to 'fonts/utilities')
-rwxr-xr-xfonts/utilities/fontools/bin/afm2afm4
-rwxr-xr-xfonts/utilities/fontools/bin/autoinst51
-rwxr-xr-xfonts/utilities/fontools/bin/ot2kpx4
-rwxr-xr-xfonts/utilities/fontools/bin/splitttc4
-rw-r--r--fonts/utilities/fontools/doc/afm2afm.pdfbin26947 -> 27083 bytes
-rw-r--r--fonts/utilities/fontools/doc/autoinst.pdfbin69653 -> 69934 bytes
-rw-r--r--fonts/utilities/fontools/doc/ot2kpx.pdfbin27326 -> 27462 bytes
-rw-r--r--fonts/utilities/fontools/doc/splitttc.pdfbin20435 -> 20574 bytes
8 files changed, 38 insertions, 25 deletions
diff --git a/fonts/utilities/fontools/bin/afm2afm b/fonts/utilities/fontools/bin/afm2afm
index 5aba6725a4..c05b55fd36 100755
--- a/fonts/utilities/fontools/bin/afm2afm
+++ b/fonts/utilities/fontools/bin/afm2afm
@@ -37,7 +37,7 @@ use File::Basename;
use Getopt::Long;
use Pod::Usage;
-my $VERSION = "20191029";
+my $VERSION = "20191118";
parse_commandline();
@@ -421,7 +421,7 @@ See the GNU General Public License for more details.
=head1 VERSION
-This document describes B<afm2afm> version 20191029.
+This document describes B<afm2afm> version 20191118.
=head1 RECENT CHANGES
diff --git a/fonts/utilities/fontools/bin/autoinst b/fonts/utilities/fontools/bin/autoinst
index c8ce5a3c2e..30a6a0f0ed 100755
--- a/fonts/utilities/fontools/bin/autoinst
+++ b/fonts/utilities/fontools/bin/autoinst
@@ -40,7 +40,7 @@ use Getopt::Long ();
use Pod::Usage ();
use POSIX ();
-my $VERSION = '20191029';
+my $VERSION = '20191118';
my ($d, $m, $y) = (localtime time)[3 .. 5];
my $TODAY = sprintf "%04d/%02d/%02d", $y + 1900, $m + 1, $d;
@@ -150,16 +150,16 @@ for my $full (keys %ABBREV) {
=cut
my @NFSS_WEIGHT = (
- ul => [ qw( ultralight thin hairline eight four two ) ],
- el => [ qw( extralight ) ],
- l => [ qw( light ) ],
+ ul => [ qw( ultralight thin 100 hairline eight four two ) ],
+ el => [ qw( extralight 200 ) ],
+ l => [ qw( light 300 ) ],
sl => [ qw( semilight blond ) ],
- '' => [ qw( regular text book ) ],
- sb => [ qw( semibold demibold medium ) ],
- b => [ qw( bold ) ],
- eb => [ qw( extrabold ) ],
- ub => [ qw( ultrabold black heavy extrablack ultrablack
- ultraheavy poster super ) ],
+ '' => [ qw( regular text book 400 ) ],
+ sb => [ qw( semibold demibold 600 medium 500 ) ],
+ b => [ qw( bold 700 ) ],
+ eb => [ qw( extrabold 800 ) ],
+ ub => [ qw( ultrabold black heavy extrablack ultrablack 900
+ ultraheavy poster super 1000 ) ],
);
my %NFSS_WEIGHT = @NFSS_WEIGHT;
@NFSS_WEIGHT = grep { !ref } @NFSS_WEIGHT;
@@ -709,10 +709,13 @@ sub decide_nfss_mappings {
# Special case: if we don't have Regular but we *do* have Medium,
# move Medium from the "sb" list to the "m" (i.e., Regular) one.
- if ( !@{$NFSS_WEIGHT{''}} and $weight{medium} ) {
- $NFSS_WEIGHT{''} = [ 'medium' ];
- $NFSS_WEIGHT{sb}
- = [ grep { $_ ne 'medium' } @{$NFSS_WEIGHT{medium}} ];
+ if ( !@{$NFSS_WEIGHT{''}} ) {
+ my $alternate = ( grep { $weight{$_} } qw(medium 500) )[0];
+ if ($alternate) {
+ $NFSS_WEIGHT{''} = [ $alternate ];
+ $NFSS_WEIGHT{sb}
+ = [ grep { $_ ne $alternate } @{$NFSS_WEIGHT{sb}} ];
+ }
}
# Some more trickery to map the sl code to Book or Text (but of course
@@ -1292,9 +1295,11 @@ sub parse_options {
END_WARNING_TARGET_UPDMAP
}
elsif (!$ARGV{target}) {
- my $kpsepath = eval {
- qx( kpsewhich -expand-var='\$TEXMFLOCAL:\$TEXMFHOME' );
- };
+ my $is_windows_os = ( $^O =~ /^MSWin/i );
+ my $kpsepath = $is_windows_os
+ ? eval { qx( kpsewhich -expand-var=\$TEXMFLOCAL;\$TEXMFHOME ) }
+ : eval { qx( kpsewhich -expand-var='\$TEXMFLOCAL:\$TEXMFHOME' ) }
+ ;
if (!$kpsepath) {
warn <<"END_WARNING_KPSEWHICH";
[WARNING] Call to "kpsewhich" failed.
@@ -1305,7 +1310,8 @@ END_WARNING_TARGET_UPDMAP
END_WARNING_KPSEWHICH
}
else {
- for my $dir ( split m/[:;]/xms, substr $kpsepath, 0, -1 ) {
+ my $pathsep = $is_windows_os ? ';' : ':';
+ for my $dir ( split m/$pathsep/xms, substr $kpsepath, 0, -1 ) {
if (-w $dir) { $ARGV{target} = $dir; last }
if (-e $dir) { next }
my $par = File::Spec->catdir( $dir, File::Spec->updir() );
@@ -1787,6 +1793,7 @@ sub write_stylefile {
$fn = File::Spec->catfile($dir, $fn);
open my $STY, '>', $fn
or die "[ERROR] Can't create '$fn': $!";
+ binmode $STY;
print {$STY} <<"END_STY_HEADER";
%% Generated by autoinst on $TODAY
@@ -1995,6 +2002,7 @@ sub write_fdfile {
$fn = File::Spec->catfile($dir, $fn);
open my $FD, '>', $fn
or die "[ERROR] Can't create '$fn': $!";
+ binmode $FD;
print {$FD} <<"END_FD_HEADER";
%% Generated by autoinst on $TODAY
@@ -2825,7 +2833,7 @@ GNU General Public License for more details.
=head1 VERSION
-This document describes B<autoinst> version 20191029.
+This document describes B<autoinst> version 20191118.
=head1 RECENT CHANGES
@@ -2834,6 +2842,11 @@ This document describes B<autoinst> version 20191029.
=over 12
+=item I<2019-11-18>
+
+Fine-tuned calling of F<kpsewhich> on Windows (patch by Akira Kakuto).
+The font info parsing now also recognises numerical weights, e.g. in Museo.
+
=item I<2019-10-29>
The generated style files now use T1 as the default text encoding.
diff --git a/fonts/utilities/fontools/bin/ot2kpx b/fonts/utilities/fontools/bin/ot2kpx
index b81d227ee2..b26a9c7942 100755
--- a/fonts/utilities/fontools/bin/ot2kpx
+++ b/fonts/utilities/fontools/bin/ot2kpx
@@ -38,7 +38,7 @@ use Getopt::Long ();
use List::Util @List::Util::EXPORT_OK;
use Pod::Usage;
-my $VERSION = "20191029";
+my $VERSION = "20191118";
our ($NUM_GLYPHS, $UNITS_PER_EM, %kern);
@@ -858,7 +858,7 @@ See the GNU General Public License for more details.
=head1 VERSION
-This document describes B<ot2kpx> version 20191029.
+This document describes B<ot2kpx> version 20191118.
=head1 RECENT CHANGES
diff --git a/fonts/utilities/fontools/bin/splitttc b/fonts/utilities/fontools/bin/splitttc
index fcd36cba2d..bf1a34c8a6 100755
--- a/fonts/utilities/fontools/bin/splitttc
+++ b/fonts/utilities/fontools/bin/splitttc
@@ -37,7 +37,7 @@ use File::Basename;
use Getopt::Long;
use Pod::Usage;
-my $VERSION = "20191029";
+my $VERSION = "20191118";
parse_commandline();
@@ -245,7 +245,7 @@ See the GNU General Public License for more details.
=head1 VERSION
-This document describes B<splitttc> version 20191029.
+This document describes B<splitttc> version 20191118.
=head1 RECENT CHANGES
diff --git a/fonts/utilities/fontools/doc/afm2afm.pdf b/fonts/utilities/fontools/doc/afm2afm.pdf
index 5afefa2283..d0fae6082d 100644
--- a/fonts/utilities/fontools/doc/afm2afm.pdf
+++ b/fonts/utilities/fontools/doc/afm2afm.pdf
Binary files differ
diff --git a/fonts/utilities/fontools/doc/autoinst.pdf b/fonts/utilities/fontools/doc/autoinst.pdf
index e562bf95bb..5241c03ec7 100644
--- a/fonts/utilities/fontools/doc/autoinst.pdf
+++ b/fonts/utilities/fontools/doc/autoinst.pdf
Binary files differ
diff --git a/fonts/utilities/fontools/doc/ot2kpx.pdf b/fonts/utilities/fontools/doc/ot2kpx.pdf
index c409d7984c..101cab415a 100644
--- a/fonts/utilities/fontools/doc/ot2kpx.pdf
+++ b/fonts/utilities/fontools/doc/ot2kpx.pdf
Binary files differ
diff --git a/fonts/utilities/fontools/doc/splitttc.pdf b/fonts/utilities/fontools/doc/splitttc.pdf
index d7fd54a098..36ff334aab 100644
--- a/fonts/utilities/fontools/doc/splitttc.pdf
+++ b/fonts/utilities/fontools/doc/splitttc.pdf
Binary files differ