summaryrefslogtreecommitdiff
path: root/Build/source/texk/makejvf/write.c
diff options
context:
space:
mode:
Diffstat (limited to 'Build/source/texk/makejvf/write.c')
-rw-r--r--Build/source/texk/makejvf/write.c28
1 files changed, 24 insertions, 4 deletions
diff --git a/Build/source/texk/makejvf/write.c b/Build/source/texk/makejvf/write.c
index 34eeeaf0074..d2129137e5f 100644
--- a/Build/source/texk/makejvf/write.c
+++ b/Build/source/texk/makejvf/write.c
@@ -93,8 +93,6 @@ void writevf(int code, FILE *fp)
w = jfmread(code); /* rightamount is also obtained */
- fputc(242,fp); /* long_char */
-
skip2=baseshift;
switch (code) {
case 0x2146: /* ‘ */
@@ -127,6 +125,7 @@ void writevf(int code, FILE *fp)
skip2+=-(int)(zh*3/5.0); /* skip2+=-(int)((0.6)*zh); */
}
+ fputc(242,fp); /* long_char */
if (kanatfm)
cc=4;
else
@@ -195,6 +194,7 @@ void writevf(int code, FILE *fp)
skip2+=(int)(zh*3/5.0); /* skip2+=(int)((0.6)*zh); */
}
+ fputc(242,fp); /* long_char */
if (kanatfm)
cc=4;
else
@@ -305,9 +305,17 @@ void writevf(int code, FILE *fp)
skip = -(zw-w)/2;
}
}
+ else {
+ if (omitzw) { /* Omit entries in VF for characters with default ZW metric */
+ if (!kanatfm || code > 0x2576)
+ return;
+ }
+ }
break;
}
+ fputc(242,fp); /* long_char */
+
for (l = 0; l < usertable_replace_max; l++) {
if (code == usertable_replace[l].codepoint) {
outcode = usertable_replace[l].newcodepoint;
@@ -375,8 +383,6 @@ void writevfu(int code, FILE *fp)
w = jfmread(code); /* rightamount is also obtained */
- fputc(242,fp); /* long_char */
-
skip2=baseshift;
switch (code) {
case 0x2018: /* ‘ */
@@ -404,6 +410,7 @@ void writevfu(int code, FILE *fp)
skip = -(zw-w); /* changed */
/* no correction needed for skip2 */
+ fputc(242,fp); /* long_char */
if (kanatfm)
cc=4;
else
@@ -432,6 +439,7 @@ void writevfu(int code, FILE *fp)
return;
}
else if (ucsqtfm) { /* UniJIS-UCS2-H系へ変換 */
+ fputc(242,fp); /* long_char */
cc=4;
skip = -(zw-w);
if (skip)
@@ -456,6 +464,7 @@ void writevfu(int code, FILE *fp)
}
else if (jfm_id == 11 && jistfm) { /* 横書き時はJIS系へ変換 */
/* UCS U+2018 → JIS 0x2146, UCS U+201C → JIS 0x2148 */
+ fputc(242,fp); /* long_char */
cc=4;
skip = -(zw-w);
if (skip)
@@ -528,6 +537,7 @@ void writevfu(int code, FILE *fp)
skip = zw; /* changed */
/* no correction needed for skip2 */
+ fputc(242,fp); /* long_char */
if (kanatfm)
cc=4;
else
@@ -562,6 +572,7 @@ void writevfu(int code, FILE *fp)
return;
}
else if (ucsqtfm) { /* UniJIS-UCS2-H系へ変換 */
+ fputc(242,fp); /* long_char */
cc=4;
if (skip2)
cc+=numcount(skip2)+1;
@@ -579,6 +590,7 @@ void writevfu(int code, FILE *fp)
}
else if (jfm_id == 11 && jistfm) { /* 横書き時はJIS系へ変換 */
/* UCS U+2019 → JIS 0x2147, UCS U+201D → JIS 0x2149 */
+ fputc(242,fp); /* long_char */
cc=4;
if (skip2)
cc+=numcount(skip2)+1;
@@ -711,9 +723,17 @@ void writevfu(int code, FILE *fp)
skip = -(zw-w)/2;
}
}
+ else {
+ if (omitzw) { /* Omit entries in VF for characters with default ZW metric */
+ if (!kanatfm || uniblock_iskanji)
+ return;
+ }
+ }
break;
}
+ fputc(242,fp); /* long_char */
+
for (l = 0; l < usertable_replace_max; l++) {
if (code == usertable_replace[l].codepoint) {
outcode = usertable_replace[l].newcodepoint;