[Pkg-gs-devel] r21 - in gs-esp/trunk/debian: patches
Kenshi Muto
kmuto at costa.debian.org
Sun Jul 30 14:24:03 UTC 2006
Author: kmuto
Date: Sun Jul 30 14:24:02 2006
New Revision: 21
Added:
gs-esp/trunk/debian/patches/07_cmap_post_table.dpatch (contents, props changed)
Modified:
gs-esp/trunk/debian/changelog
gs-esp/trunk/debian/control
gs-esp/trunk/debian/patches/00list
Log:
add 07_cmap_post_table patch
Modified: gs-esp/trunk/debian/changelog
==============================================================================
--- gs-esp/trunk/debian/changelog (original)
+++ gs-esp/trunk/debian/changelog Sun Jul 30 14:24:02 2006
@@ -14,6 +14,8 @@
* Update policy-version and debhelper.
* cdbsize.
* Use configure command directly instead of using autogen.sh.
+ * 07_cmap_post_table.dpatch: Apply big post table patch for Kochi-font
+ and uming.ttf/ukai.ttf.
-- Kenshi Muto <kmuto at debian.org> Fri, 28 Jul 2006 18:51:45 +0900
Modified: gs-esp/trunk/debian/control
==============================================================================
--- gs-esp/trunk/debian/control (original)
+++ gs-esp/trunk/debian/control Sun Jul 30 14:24:02 2006
@@ -11,6 +11,7 @@
Replaces: gs-afpl (<< 8.14-3), gs-aladdin (<< 8.14-3), gs-gpl (<< 8.01-3), gs (<< 8.01-3), gs-pdfencrypt (<< 7.00), cupsys-pstoraster
Depends: ${shlibs:Depends}, gs-common (>= 0.3.9)
Recommends: gsfonts (>= 6.0-1), psfontmgr
+Suggests: cmap-adobe-japan1 | cmap-adobe-cns1 | cmap-adobe-gb1 | cmap-adobe-korea1 | cmap-adobe-japan2
Conflicts: gs-afpl (<< 8.14-3), gs-aladdin (<< 8.14-3), gs-gpl (<< 8.01-3), gs (<< 8.01-3), gs-pdfencrypt (<< 7.00), cupsys-pstoraster
Provides: gs, gs-pdfencrypt, postscript-viewer
Description: The Ghostscript PostScript interpreter - ESP version
Modified: gs-esp/trunk/debian/patches/00list
==============================================================================
--- gs-esp/trunk/debian/patches/00list (original)
+++ gs-esp/trunk/debian/patches/00list Sun Jul 30 14:24:02 2006
@@ -5,7 +5,4 @@
#04_enable_fapi
#05_krgb_1.2
06_kfreebsd_buildfix
-
-
-
-
+07_cmap_post_table
Added: gs-esp/trunk/debian/patches/07_cmap_post_table.dpatch
==============================================================================
--- (empty file)
+++ gs-esp/trunk/debian/patches/07_cmap_post_table.dpatch Sun Jul 30 14:24:02 2006
@@ -0,0 +1,212 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 07_cmap_post_table.dpatch by Kenshi Muto <kmuto at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad gs-esp-8.15.2.dfsg.1~/lib/gs_ttf.ps gs-esp-8.15.2.dfsg.1/lib/gs_ttf.ps
+--- gs-esp-8.15.2.dfsg.1~/lib/gs_ttf.ps 2006-07-30 23:20:05.000000000 +0900
++++ gs-esp-8.15.2.dfsg.1/lib/gs_ttf.ps 2006-07-30 23:20:26.000000000 +0900
+@@ -261,6 +261,54 @@
+ } for pop exch pop
+ } bind def
+
++/.biglength { % <str>|<array of str> .biglength <integer>
++ dup type /arraytype eq { 0 exch { length add } forall } { length } ifelse
++} bind def
++
++/concats { % [str ...] concats str
++ () exch dup length 1 sub -1 0 {
++ 1 index exch get dup type /stringtype ne { dup length string cvs } if
++ 3 -1 roll exch dup length 2 index length add string
++ dup dup 4 2 roll copy length 4 -1 roll putinterval exch
++ } for pop
++} bind def
++
++% <str>|<array of str> <index> <count> .biggetinterval <str>|<array of str>
++/.biggetinterval {
++ 3 dict begin
++ 2 index type /arraytype eq {
++ /c exch def
++ /i exch def
++ [ exch {
++ dup length /l exch def
++ i c add l gt {
++ i l lt {
++ i l i sub getinterval
++ /c i c add l sub def
++ /i 0 def
++ } {
++ pop
++ /i i l sub def
++ } ifelse
++ } {
++ i c getinterval exit
++ } ifelse
++ } forall
++ ] dup .biglength 65535 le { concats } if
++ } { getinterval } ifelse
++ end
++} bind def
++
++% <str>|<array of str> <index> getu16 <integer>
++/.biggetu16 {
++ 2 .biggetinterval 0 getu16
++} bind def
++
++% <str>|<array of str> <index> getu32 <integer>
++/.biggetu32 {
++ 4 .biggetinterval 0 getu32
++} bind def
++
+ % Each procedure in this dictionary is called as follows:
+ % <encodingtable> proc <glypharray>
+ /cmapformats mark
+@@ -351,14 +399,14 @@
+ } bind
+ 4 { % Microsoft/Adobe segmented mapping.
+ /etab exch def
+- /nseg2 etab 6 getu16 def
+- 14 /endc etab 2 index nseg2 getinterval def
++ /nseg2 etab 6 .biggetu16 def
++ 14 /endc etab 2 index nseg2 .biggetinterval def
+ % The Apple TrueType documentation omits the 2-byte
+ % 'reserved pad' that follows the endCount vector!
+ 2 add
+- nseg2 add /startc etab 2 index nseg2 getinterval def
+- nseg2 add /iddelta etab 2 index nseg2 getinterval def
+- nseg2 add /idroff etab 2 index nseg2 getinterval def
++ nseg2 add /startc etab 2 index nseg2 .biggetinterval def
++ nseg2 add /iddelta etab 2 index nseg2 .biggetinterval def
++ nseg2 add /idroff etab 2 index nseg2 .biggetinterval def
+ % The following hack allows us to properly handle
+ % idiosyncratic fonts that start at 0xf000:
+ pop
+@@ -370,8 +418,8 @@
+ /numcodes 0 def /glyphs 0 0 2 nseg2 3 sub {
+ % Stack: /glyphs numglyphs i2
+ /i2 exch def
+- /scode startc i2 getu16 def
+- /ecode endc i2 getu16 def
++ /scode startc i2 .biggetu16 def
++ /ecode endc i2 .biggetu16 def
+ numcodes scode firstcode sub
+ % Hack for fonts that have only 0x0000 and 0xf000 ranges
+ %dup 16#e000 ge { 255 and } if
+@@ -392,8 +440,8 @@
+ /numcodes 0 def /code 0 def
+ 0 2 nseg2 3 sub {
+ /i2 exch def
+- /scode startc i2 getu16 def
+- /ecode endc i2 getu16 def
++ /scode startc i2 .biggetu16 def
++ /ecode endc i2 .biggetu16 def
+ numcodes scode firstcode sub
+ % Hack for fonts that have only 0x0000 and 0xf000 ranges
+ %dup 16#e000 ge { 255 and } if
+@@ -405,15 +453,15 @@
+ (scode=) print scode =only
+ ( ecode=) print ecode =only
+ ( delta=) print delta =only
+- ( droff=) print idroff i2 getu16 =
++ ( droff=) print idroff i2 .biggetu16 =
+ } if
+- idroff i2 getu16 dup 0 eq {
++ idroff i2 .biggetu16 dup 0 eq {
+ pop scode delta add 65535 and 1 ecode delta add 65535 and
+ { putglyph } for
+ } { % The +2 is for the 'reserved pad'.
+ /gloff exch 14 nseg2 3 mul add 2 add i2 add add def
+ 0 1 ecode scode sub {
+- 2 mul gloff add etab exch getu16
++ 2 mul gloff add etab exch .biggetu16
+ dup 0 ne { delta add 65535 and } if putglyph
+ } for
+ } ifelse
+@@ -436,12 +484,12 @@
+
+ % <cmaptab> cmaparray <glypharray>
+ /cmaparray {
+- dup 0 getu16 cmapformats exch .knownget {
++ dup 0 .biggetu16 cmapformats exch .knownget {
+ TTFDEBUG {
+- (cmap: format ) print 1 index 0 getu16 = flush
++ (cmap: format ) print 1 index 0 .biggetu16 = flush
+ } if exec
+ } {
+- (Can't handle format ) print 0 getu16 = flush
++ (Can't handle format ) print 0 .biggetu16 = flush
+ 0 1 255 { } for 256 packedarray
+ } ifelse
+ TTFDEBUG {
+@@ -513,13 +561,13 @@
+ % Adobe requirement that each sfnts entry have even length.
+ /readtables mark
+ % Ordinary tables
+- (cmap) { .readtable }
++ (cmap) { .readbigtable }
+ (head) 1 index
+ (hhea) 1 index
+ (maxp) 1 index
+ (name) 1 index
+ (OS/2) 1 index
+- (post) 1 index
++ (post) { .readbigtable }
+ (vhea) 1 index
+ % Big tables
+ (glyf) { .readbigtable }
+@@ -860,10 +908,17 @@
+ } ifelse
+ % Stack: ... /FontInfo mark key1 value1 ...
+ post null ne {
+- /ItalicAngle post 4 gets32 65536.0 div
+- /isFixedPitch post 12 getu32 0 ne
+- /UnderlinePosition post 8 gets16 upem div
+- /UnderlineThickness post 10 gets16 upem div
++ post type /arraytype eq {
++ % this post table is a big table. /post should be [(...) ...]
++ % data we actually need here should be first one in array.
++ /posttable post 1 get def
++ } {
++ /posttable post def
++ } ifelse
++ /ItalicAngle posttable 4 gets32 65536.0 div
++ /isFixedPitch posttable 12 getu32 0 ne
++ /UnderlinePosition posttable 8 gets16 upem div
++ /UnderlineThickness posttable 10 gets16 upem div
+ } if
+ counttomark 0 ne { .dicttomark } { pop pop } ifelse
+ /XUID [orgXUID 42 curxuid]
+@@ -922,22 +977,22 @@
+ } if
+ tabdict /cmap get % bool [] i PlatID SpecID (cmap)
+ dup /cmaptab exch def % temporary
+- 0 1 2 index 2 getu16 1 sub { % bool [] i PlatID SpecID (cmap) j
+- 8 mul 4 add 1 index exch 8 getinterval % bool [] i PlatID SpecID (cmap) (cmapsub)
++ 0 1 2 index 2 .biggetu16 1 sub { % bool [] i PlatID SpecID (cmap) j
++ 8 mul 4 add 1 index exch 8 .biggetinterval % bool [] i PlatID SpecID (cmap) (cmapsub)
+ TTFDEBUG {
+- (cmap: platform ) print dup 0 getu16 =only
+- ( encoding ) print dup 2 getu16 = flush
++ (cmap: platform ) print dup 0 .biggetu16 =only
++ ( encoding ) print dup 2 .biggetu16 = flush
+ } if
+- dup 0 getu16 4 index eq {
+- dup 2 getu16 3 index eq { % bool [] i PlatID SpecID (cmap) (cmapsub)
++ dup 0 .biggetu16 4 index eq {
++ dup 2 .biggetu16 3 index eq { % bool [] i PlatID SpecID (cmap) (cmapsub)
+ TTFDEBUG {
+ (Choosen a cmap for platform=) print 3 index =only
+ ( encoding=) print 2 index =
+ } if
+ /cmapsub 1 index def
+- dup 4 getu32 % bool [] i PlatID SpecID (cmap) (cmapsub) p
+- cmaptab length 1 index sub % bool [] i PlatID SpecID (cmap) (cmapsub) p l
+- cmaptab 3 1 roll getinterval
++ dup 4 .biggetu32 % bool [] i PlatID SpecID (cmap) (cmapsub) p
++ cmaptab .biglength 1 index sub % bool [] i PlatID SpecID (cmap) (cmapsub) p l
++ cmaptab 3 1 roll .biggetinterval
+ /cmaptab exch def % bool [] i PlatID SpecID (cmap) (cmapsub)
+ 5 index 5 index 1 add get % bool [] i PlatID SpecID (cmap) (cmapsub) /Decoding
+ /Decoding exch def % bool [] i PlatID SpecID (cmap) (cmapsub)
More information about the Pkg-gs-devel
mailing list