diff options
author | Reinhard Kotucha <reinhard.kotucha@web.de> | 2017-04-23 22:15:25 +0000 |
---|---|---|
committer | Reinhard Kotucha <reinhard.kotucha@web.de> | 2017-04-23 22:15:25 +0000 |
commit | 54448d6ab44d2033482fafa56ddc40d42a6815eb (patch) | |
tree | d4fdfff7b7f75c367a76f872e2986af75c5f81a3 /Master/tlpkg/tlgs/kanji/metrics2.ps | |
parent | f2a947f3017b82f1dfa1058d1d720fe11d298e92 (diff) |
Add files needed for CJK to tlgs, adapt runscript.tlu accordingly.
git-svn-id: svn://tug.org/texlive/trunk@43997 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/tlgs/kanji/metrics2.ps')
-rw-r--r-- | Master/tlpkg/tlgs/kanji/metrics2.ps | 97 |
1 files changed, 97 insertions, 0 deletions
diff --git a/Master/tlpkg/tlgs/kanji/metrics2.ps b/Master/tlpkg/tlgs/kanji/metrics2.ps new file mode 100644 index 00000000000..f1b7745604d --- /dev/null +++ b/Master/tlpkg/tlgs/kanji/metrics2.ps @@ -0,0 +1,97 @@ +% +% wmode.ps - define /setmetrics2 operator +% +% Aug.28,1991 Programmed by N.Katayama +% +% Akira Tanaka <akr@jaist.ac.jp> modified for gs4.03/VFlib support. 1996/10/17 + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% Metrics Utility Operator +% Execute this in the BuildChar procedure instead of setcachedevice2 +% + +%/SETMETRICS2 14 dict def % private dictionary + +% +% w0x w0y llx lly urx ury w1x w1y vx vy char setmetrics2 - +% + +/setmetrics2 +{ + currentdict + 14 dict begin + /font exch def + /char exch def + /vy exch def /vx exch def /w1y exch def /w1x exch def + /ury exch def /urx exch def /lly exch def /llx exch def + /w0y exch def /w0x exch def + + /old-llx llx def + /old-lly lly def + + % Metrics + + font /Metrics 2 copy known { + get char 2 copy known { + get dup type + dup /integertype eq { + /w0x 2 index def + } if + dup /realtype eq { + /w0x 2 index def + } if + dup /arraytype eq { + 1 index + dup length 2 eq { + /llx 1 index 0 get def + /urx llx old-llx sub urx add def + /w0x 1 index 1 get def + } if + dup length 4 eq { + /llx 1 index 0 get def + /lly 1 index 1 get def + /urx llx old-llx sub urx add def + /ury lly old-lly sub ury add def + /w0x 1 index 2 get def + /w0y 1 index 3 get def + } if + pop + } if + pop pop + }{ pop pop } ifelse + }{ pop pop } ifelse + + % Metrics2 + + font /Metrics2 2 copy known { + get char 2 copy known { + get + dup 0 get /w1x exch def + dup 1 get /w1y exch def + dup 2 get /vx exch def + dup 3 get /vy exch def + pop + }{ pop pop } ifelse + }{ pop pop } ifelse + + % CDevProc + + font /CDevProc 2 copy known { + get + w0x w0y llx lly urx ury w1x w1y vx vy char 12 -1 roll exec + /vy exch def /vx exch def /w1y exch def /w1x exch def + /ury exch def /urx exch def /lly exch def /llx exch def + /w0y exch def /w0x exch def + }{ pop pop } ifelse + + % setcachedevice2 + + w0x w0y llx lly urx ury w1x w1y vx vy setcachedevice2 + + % translate + + llx old-llx sub lly old-lly sub translate + + end +} bind def |