diff options
author | Karl Berry <karl@freefriends.org> | 2018-01-02 00:17:17 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2018-01-02 00:17:17 +0000 |
commit | 35ff4f6a7d6f4f21e02bb3d494b182fd8b54bc7e (patch) | |
tree | 51486980b96c05a2f9de112e681d3c2f075d7b22 /Build/source/texk/web2c/pdftexdir/mapfile.c | |
parent | 3992bdafaa741b02f032e705d0aab10224c5c052 (diff) |
encoding vectors for bitmap font map lines (sync from pdftex r790)
git-svn-id: svn://tug.org/texlive/trunk@46189 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/pdftexdir/mapfile.c')
-rw-r--r-- | Build/source/texk/web2c/pdftexdir/mapfile.c | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/Build/source/texk/web2c/pdftexdir/mapfile.c b/Build/source/texk/web2c/pdftexdir/mapfile.c index 026dc68b95e..fa153bcb60a 100644 --- a/Build/source/texk/web2c/pdftexdir/mapfile.c +++ b/Build/source/texk/web2c/pdftexdir/mapfile.c @@ -1,5 +1,6 @@ /* mapfile.c: handling of map files/lines -Copyright 1996-2017 Han The Thanh, <thanh@pdftex.org> + +Copyright 1996-2018 Han The Thanh, <thanh@pdftex.org> This file is part of pdfTeX. @@ -346,6 +347,27 @@ static int check_fm_entry(fm_entry * fm, boolean warn) a += 32; } + /* font file for bitmap PK fonts is determinated by kpse and depends + on current font size; writet3.c ignores font file for bitmap PK fonts */ + if (is_fontfile(fm) && is_pk(fm)) { + if (warn) + pdftex_warn + ("invalid entry for `%s': " + "FontFile cannot be specified for bitmap PK font: %s", + fm->tfm_name, fm_fontfile(fm)); + a += 64; + } + + /* ps name cannot be stored into PDF file for PDF Type3 fonts */ + if (fm->ps_name != NULL && is_pk(fm)) { + if (warn) + pdftex_warn + ("invalid entry for `%s': " + "PsName cannot be specified for bitmap PK font: %s", + fm->tfm_name, fm->ps_name); + a += 128; + } + return a; } @@ -543,6 +565,9 @@ static void fm_scan_line(void) set_opentype(fm); else set_type1(fm); + } else if (fm->ps_name == NULL) { + set_pk(fm); /* font without ps_name and without fontfile, + it can be only bitmap PK font */ } else set_type1(fm); /* assume a builtin font is Type1 */ @@ -629,6 +654,11 @@ boolean hasfmentry(internalfontnumber f) return pdffontmap[f] != (fmentryptr) dummy_fm_entry(); } +boolean isscalable(internalfontnumber f) +{ + return hasfmentry(f) && (!is_pk((fm_entry *)pdffontmap[f])); +} + /* check whether a map entry is valid for font replacement */ static boolean fm_valid_for_font_replacement(fm_entry * fm) |