summaryrefslogtreecommitdiff
path: root/Build/source/texk/dvipsk/tfmload.c
diff options
context:
space:
mode:
authorTakuji Tanaka <ttk@t-lab.opal.ne.jp>2023-04-29 06:43:04 +0000
committerTakuji Tanaka <ttk@t-lab.opal.ne.jp>2023-04-29 06:43:04 +0000
commitf11e931741352726b6bb4ba3816ab1085ff43111 (patch)
treeab8d53460433e5496cb8a94e4c898ccefea4353d /Build/source/texk/dvipsk/tfmload.c
parente77ff4bcbdbcf7f9594fbc0231b2b3c1123f713b (diff)
dvips: VF fallback to OFM for (u)pTeX
The rule for virtual fonts (VF) fallback is extended: If a VF has no entry of a codepoint and the first MAPFONT designates an OFM for (u)pTeX, then we designate the glyph (usually with a fullwidth metric) of the same codepoint with the same metrics of the codepoint in the OFM. git-svn-id: svn://tug.org/texlive/trunk@66966 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/dvipsk/tfmload.c')
-rw-r--r--Build/source/texk/dvipsk/tfmload.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/Build/source/texk/dvipsk/tfmload.c b/Build/source/texk/dvipsk/tfmload.c
index 1b354834283..afc5d803dbf 100644
--- a/Build/source/texk/dvipsk/tfmload.c
+++ b/Build/source/texk/dvipsk/tfmload.c
@@ -127,10 +127,12 @@ tfmload(register fontdesctype *curfnt)
curfnt->dir = 0;
curfnt->iswide = 0;
curfnt->codewidth = 1;
+ curfnt->kind = TFM_TEX;
id = tfm16();
if (id!=0) {
font_level = -1;
if (id == 9 || id == 11) {
+ curfnt->kind = JFM_PTEX;
if (noptex) badtfm("length");
if (id == 9) curfnt->dir = id;
nt = tfm16(); li = tfm16();
@@ -153,6 +155,7 @@ tfmload(register fontdesctype *curfnt)
badtfm("header");
} else { /* In an .ofm file */
if (noomega) badtfm("length");
+ curfnt->kind = OFM_OMEGA;
font_level = tfm16();
li = tfm32(); hd = tfm32();
bc = tfm32(); ec = tfm32();
@@ -170,8 +173,9 @@ tfmload(register fontdesctype *curfnt)
#endif /* DEBUG */
}
}
- if (font_level>1 || hd<2 || bc<0 || ec<0 || nw<0
- || bc>ec+1 || ec>65535 || nw>65536)
+ if ((font_level>1 || hd<2 || bc<0 || ec<0 || nw<0
+ || bc>ec+1 || ec>0x10FFFF || nw>0x110000) ||
+ (font_level==0 && (ec>65535 || nw>65536)))
badtfm("header");
if (font_level==1) {
nco = tfm32();